public LayerForBooleansToVirtualActivity(AnimatorGenerator animatorGenerator, AvatarMask logicalAvatarMask, bool writeDefaults, List <GestureComboStageMapper> comboLayers) { _animatorGenerator = animatorGenerator; _logicalAvatarMask = logicalAvatarMask; _writeDefaultsForLogicalStates = writeDefaults; _comboLayers = comboLayers; }
public Just1Int7TogglesCompilerInternal(RuntimeAnimatorController animatorController, AnimationClip customEmptyClip, TogglesManifest manifest) { _emptyClipProvider = new StatefulEmptyClipProvider(new ClipGenerator(customEmptyClip, EmptyClipPath, PluginFolderName)); _animatorGenerator = new AnimatorGenerator((AnimatorController)animatorController, _emptyClipProvider); _viewCreator = new ViewCreator(_animatorGenerator, manifest); }
public LayerForAnalogFistSmoothing(AnimatorGenerator animatorGenerator, AvatarMask weightCorrectionAvatarMask, bool writeDefaults, AnimatorController animatorController) { _animatorGenerator = animatorGenerator; _weightCorrectionAvatarMask = weightCorrectionAvatarMask; _animatorController = animatorController; _writeDefaultsForAnimatedAnimatorParameterStates = writeDefaults; }
public Animation(YAML.Animation deserialized, string base_dir) { _DeserializedYAMLDoc = deserialized; _Generator = new AnimatorGenerator(base_dir, _DeserializedYAMLDoc); _Collection = _Generator.Collection; _Clips = _Generator.ConstructClips(_Collection.CollectionData); }
public LayerForBlinkingOverrideView(string activityStageName, List <GestureComboStageMapper> comboLayers, float analogBlinkingUpperThreshold, AvatarMask logicalAvatarMask, AnimatorGenerator animatorGenerator, AnimationClip emptyClip, List <ManifestBinding> manifestBindings, bool writeDefaults) { _activityStageName = activityStageName; _comboLayers = comboLayers; _analogBlinkingUpperThreshold = analogBlinkingUpperThreshold; _logicalAvatarMask = logicalAvatarMask; _animatorGenerator = animatorGenerator; _emptyClip = emptyClip; _manifestBindings = manifestBindings; _writeDefaultsForLogicalStates = writeDefaults; }
public Animation(ModLoader.ModInfo info, YAML.Animation deserialized, string base_dir = null) { _ModInfo = info; _DeserializedYAMLDoc = deserialized; if (base_dir == null) { base_dir = info.Resources.BaseDir; } _Generator = new AnimatorGenerator(_ModInfo, base_dir, _DeserializedYAMLDoc); _Collection = _Generator.Collection; _Clips = _Generator.ConstructClips(_Collection.CollectionData); }
public void IntegrateWeightCorrection() { _animatorGenerator = new AnimatorGenerator(_animatorController, new StatefulEmptyClipProvider(new ClipGenerator(_customEmptyClip, EmptyClipPath, "ComboGesture"))); var avatarMaskPath = AssetDatabase.LoadAssetAtPath <AvatarMask>(GesturePlayableLayerAvatarMaskPath); CreateOrReplaceWeightCorrection( avatarMaskPath, _animatorGenerator, _animatorController, _conflictPrevention ); CreateOrReplaceSmoothing(avatarMaskPath, _animatorGenerator, _animatorController, _conflictPrevention); ReapAnimator(_animatorController); AssetDatabase.Refresh(); EditorUtility.ClearProgressBar(); }
public LayerForLipsyncOverrideView(float analogBlinkingUpperThreshold, AvatarMask logicalAvatarMask, AnimatorGenerator animatorGenerator, VRCAvatarDescriptor avatarDescriptor, ComboGestureLimitedLipsync limitedLipsync, AssetContainer assetContainer, AnimationClip emptyClip, List <ManifestBinding> manifestBindings, bool writeDefaults) { _analogBlinkingUpperThreshold = analogBlinkingUpperThreshold; _logicalAvatarMask = logicalAvatarMask; _animatorGenerator = animatorGenerator; _avatarDescriptor = avatarDescriptor; _limitedLipsync = limitedLipsync; _assetContainer = assetContainer; _emptyClip = emptyClip; _manifestBindings = manifestBindings; _writeDefaultsForLipsyncBlendshapes = writeDefaults; }
public void DoOverwriteAnimatorGesturePlayableLayer() { _animatorGenerator = new AnimatorGenerator(_gesturePlayableLayerController, new StatefulEmptyClipProvider(new ClipGenerator(_customEmptyClip, EmptyClipPath, "ComboGesture"))); var emptyClip = GetOrCreateEmptyClip(); if (_activityStageName != null) { SharedLayerUtils.CreateParamIfNotExists(_gesturePlayableLayerController, _activityStageName, AnimatorControllerParameterType.Int); } if (!Feature(FeatureToggles.DoNotGenerateWeightCorrectionLayer)) { if (_useGestureWeightCorrection) { CreateOrReplaceWeightCorrection(_gesturePlayableLayerTechnicalAvatarMask, _animatorGenerator, _gesturePlayableLayerController, _conflictPreventionTempGestureLayer); if (_useSmoothing) { CreateOrReplaceSmoothing(_weightCorrectionAvatarMask, _animatorGenerator, _gesturePlayableLayerController, _conflictPreventionTempGestureLayer); } else { DeleteSmoothing(); } } else { DeleteWeightCorrection(); DeleteSmoothing(); } } var manifestBindings = CreateManifestBindings(emptyClip); CreateOrReplaceGesturePlayableLayerExpressionsView(emptyClip, manifestBindings); ReapAnimator(_gesturePlayableLayerController); AssetDatabase.Refresh(); EditorUtility.ClearProgressBar(); }
public LayerForExpressionsView(FeatureToggles featuresToggles, AnimatorGenerator animatorGenerator, AvatarMask expressionsAvatarMask, AnimationClip emptyClip, string activityStageName, ConflictPrevention conflictPrevention, AssetContainer assetContainer, ConflictFxLayerMode compilerConflictFxLayerMode, AnimationClip compilerIgnoreParamList, AnimationClip compilerFallbackParamList, List <CurveKey> blinkBlendshapes, AnimatorController animatorController, List <GestureComboStageMapper> comboLayers, bool useGestureWeightCorrection, bool useSmoothing, List <ManifestBinding> manifestBindings, string animInfix) { _featuresToggles = featuresToggles; _animatorGenerator = animatorGenerator; _expressionsAvatarMask = expressionsAvatarMask; _emptyClip = emptyClip; _activityStageName = activityStageName; _conflictPrevention = conflictPrevention; _assetContainer = assetContainer; _compilerConflictFxLayerMode = compilerConflictFxLayerMode; _compilerIgnoreParamList = compilerIgnoreParamList; _compilerFallbackParamList = compilerFallbackParamList; _blinkBlendshapes = blinkBlendshapes; _animatorController = animatorController; _comboLayers = comboLayers; _useGestureWeightCorrection = useGestureWeightCorrection; _useSmoothing = useSmoothing; _manifestBindings = manifestBindings; _animInfix = animInfix; }
private static void CreateOrReplaceSmoothing(AvatarMask weightCorrectionAvatarMask, AnimatorGenerator animatorGenerator, AnimatorController animatorController, ConflictPrevention conflictPrevention) { SharedLayerUtils.CreateParamIfNotExists(animatorController, SharedLayerUtils.HaiGestureComboLeftWeightSmoothing, AnimatorControllerParameterType.Float); SharedLayerUtils.CreateParamIfNotExists(animatorController, SharedLayerUtils.HaiGestureComboRightWeightSmoothing, AnimatorControllerParameterType.Float); SharedLayerUtils.CreateParamIfNotExists(animatorController, SharedLayerUtils.HaiGestureComboSmoothingFactor, AnimatorControllerParameterType.Float); new LayerForAnalogFistSmoothing(animatorGenerator, weightCorrectionAvatarMask, conflictPrevention.ShouldWriteDefaults, animatorController).Create(); }
public void DoOverwriteAnimatorFxLayer() { _animatorGenerator = new AnimatorGenerator(_animatorController, new StatefulEmptyClipProvider(new ClipGenerator(_customEmptyClip, EmptyClipPath, "ComboGesture"))); var emptyClip = GetOrCreateEmptyClip(); if (_activityStageName != null) { SharedLayerUtils.CreateParamIfNotExists(_animatorController, _activityStageName, AnimatorControllerParameterType.Int); } DeleteDeprecatedControllerLayer(); if (_parameterGeneration == ParameterGeneration.VirtualActivity) { CreateOrReplaceBooleansToVirtualActivityMenu(); } else { DeleteBooleansToVirtualActivityMenu(); } if (!Feature(FeatureToggles.DoNotGenerateWeightCorrectionLayer)) { if (_useGestureWeightCorrection) { CreateOrReplaceWeightCorrection(_weightCorrectionAvatarMask, _animatorGenerator, _animatorController, _conflictPrevention); if (_useSmoothing) { CreateOrReplaceSmoothing(_weightCorrectionAvatarMask, _animatorGenerator, _animatorController, _conflictPrevention); } else { DeleteSmoothing(); } } else { DeleteWeightCorrection(); DeleteSmoothing(); } } var manifestBindings = CreateManifestBindings(emptyClip); CreateOrReplaceExpressionsView(emptyClip, manifestBindings); if (!Feature(FeatureToggles.DoNotGenerateBlinkingOverrideLayer)) { CreateOrReplaceBlinkingOverrideView(emptyClip, manifestBindings); } if (!Feature(FeatureToggles.DoNotGenerateLipsyncOverrideLayer)) { if (_integrateLimitedLipsync && _avatarDescriptor != null && _avatarDescriptor.VisemeSkinnedMesh != null) { CreateOrReplaceLipsyncOverrideView(emptyClip, manifestBindings); } else { DeleteLipsyncOverrideView(); } } ReapAnimator(_animatorController); AssetDatabase.Refresh(); EditorUtility.ClearProgressBar(); }
public static void Delete(AnimatorGenerator animatorGenerator) { animatorGenerator.RemoveLayerIfExists(ControllerLayerName); }
public static void Delete(AnimatorGenerator animatorGenerator) { animatorGenerator.RemoveLayerIfExists(VirtualActivityLayerName); }
public static void Delete(AnimatorGenerator animatorGenerator) { animatorGenerator.RemoveLayerIfExists(WeightCorrectionLeftLayerName); animatorGenerator.RemoveLayerIfExists(WeightCorrectionRightLayerName); }
public static void Delete(AnimatorGenerator animatorGenerator) { animatorGenerator.RemoveLayerIfExists(SmoothingLeftLayerName); animatorGenerator.RemoveLayerIfExists(SmoothingRightLayerName); }
private static void CreateOrReplaceWeightCorrection(AvatarMask weightCorrectionAvatarMask, AnimatorGenerator animatorGenerator, AnimatorController animatorController, ConflictPrevention conflictPrevention) { SharedLayerUtils.CreateParamIfNotExists(animatorController, "GestureLeft", AnimatorControllerParameterType.Int); SharedLayerUtils.CreateParamIfNotExists(animatorController, "GestureRight", AnimatorControllerParameterType.Int); SharedLayerUtils.CreateParamIfNotExists(animatorController, "GestureLeftWeight", AnimatorControllerParameterType.Float); SharedLayerUtils.CreateParamIfNotExists(animatorController, "GestureRightWeight", AnimatorControllerParameterType.Float); SharedLayerUtils.CreateParamIfNotExists(animatorController, SharedLayerUtils.HaiGestureComboLeftWeightProxy, AnimatorControllerParameterType.Float); SharedLayerUtils.CreateParamIfNotExists(animatorController, SharedLayerUtils.HaiGestureComboRightWeightProxy, AnimatorControllerParameterType.Float); new LayerForWeightCorrection(animatorGenerator, weightCorrectionAvatarMask, conflictPrevention.ShouldWriteDefaults).Create(); }
public static void Delete(AnimatorGenerator animatorGenerator) { animatorGenerator.RemoveLayerIfExists(LipsyncLayerName); }
public LayerForWeightCorrection(AnimatorGenerator animatorGenerator, AvatarMask weightCorrectionAvatarMask, bool writeDefaults) { _animatorGenerator = animatorGenerator; _weightCorrectionAvatarMask = weightCorrectionAvatarMask; _writeDefaultsForAnimatedAnimatorParameterStates = writeDefaults; }
internal ViewCreator(AnimatorGenerator animatorGenerator, TogglesManifest manifest) { _animatorGenerator = animatorGenerator; _manifest = manifest; }