private PoseConfigViewModel UpdatePoseViewModel() { PoseConfigViewModel poseConfigVMdl = new PoseConfigViewModel(); try { poseConfigVMdl.BrowDropDownIndex = _browDropDownIndex; poseConfigVMdl.PrimaryExpressionDropDownIndex = _primaryExpressionDropDownIndex; poseConfigVMdl.MusclesDropDownIndex = _musclesDropDownIndex; poseConfigVMdl.BrowSliderPosition = _browSliderPosition; poseConfigVMdl.PrimaryExpressionSliderPosition = _primaryExpressionSliderPosition; poseConfigVMdl.EyeDirectionHorizontalSliderPosition = _eyeHorizontalSliderPosition; poseConfigVMdl.EyeDirectionVerticalSliderPosition = _eyeVerticalSliderPosition; poseConfigVMdl.LipNarrowWide = _lipNarrow; poseConfigVMdl.JawOpenClose = _jawClose; poseConfigVMdl.MusclesSliderPosition = _musclesSliderPosition; } catch (UnityException exp) { Debug.LogError(exp.Message); } return(poseConfigVMdl); }
private void ResetAllAudioValues() { _currentKeyFrame = -1; _audioKeyFrames = new List <int>(); _keyFrameSelected = false; _currentPoseViewModel = null; }
private void OnRemember() { try { PoseConfigViewModel poseViewModel = UpdatePoseViewModel(); Controller.Instance.RememberPose(poseViewModel); } catch (UnityException exp) { Debug.LogError(exp.Message); } }
private void UpdateAnimation() { try { PoseConfigViewModel poseViewModel = UpdatePoseViewModel(); Controller.Instance.UpdateAnimation(poseViewModel); } catch (UnityException exp) { Debug.LogError(exp.Message); } }
internal void UpdateAnimation(PoseConfigViewModel poseViewModel) { try { _currentPoseViewModel = poseViewModel; PluginManager.Instance.ChangePose(_currentPoseViewModel, _currentCtrlLever); } catch (UnityException exp) { Debug.LogError(exp.Message); } }
public void ChangePose(PoseConfigViewModel poseViewModel, ControlLever ctrlLever) { try { if (_plugin != null) { animationRunning = true; _plugin.Pose(poseViewModel, ctrlLever); } } catch (UnityException exp) { UnityEngine.Debug.LogError(exp.Message); } }
internal void RememberPose(PoseConfigViewModel poseViewModel) { try { _currentPoseViewModel = poseViewModel; if (0 < _currentKeyFrame) { _currentPoseViewModel.FrameNo = (ulong)_currentKeyFrame; } MassAnimation.Resources.Entities.Pose pose = Convertor.ConvertPoseConfigVMdlToPose(_currentPoseViewModel); UIController.AddPose(_currentCtrlLever, pose); } catch (UnityException exp) { Debug.LogError(exp.Message); } }