예제 #1
0
        private static void ObsManager_SceneChanged(object sender, string sceneName)
        {
            DateTime startTime = DateTime.Now;

            StopExistingAnimation();

            List <VideoAnimationBinding> bindings = AllVideoBindings.GetAll(sceneName);

            if (bindings != null)
            {
                StartLiveAnimation(sceneName, bindings, startTime);
            }

            if (sceneName == STR_AnimationEditor)
            {
                animationEditorTimer.Start();
            }
            else
            {
                HubtasticBaseStation.PreloadImageBack(null, 0, 0, 0);
                HubtasticBaseStation.PreloadImageFront(null, 0, 0, 0);
                HubtasticBaseStation.ShowImageFront(null);
                HubtasticBaseStation.ShowImageBack(null);
            }

            ChangeLightsBasedOnScene(sceneName);
        }
예제 #2
0
        void DrawActiveFrame()
        {
            if (backFiles == null)
            {
                return;
            }
            if (frameIndex < 0 || frameIndex >= backFiles.Length)
            {
                HubtasticBaseStation.ShowImageBack(null);
                HubtasticBaseStation.ShowImageFront(null);
                return;
            }

            HubtasticBaseStation.ShowImageBack(GetRelativePath(backFiles[frameIndex]));
            HubtasticBaseStation.ShowImageFront(GetRelativePath(frontFiles[frameIndex]));

            foreach (AnimatorWithTransforms animatorWithTransform in liveFeedAnimators)
            {
                DrawFrameSource(animatorWithTransform);
            }
        }