private void RenderMain(EePreviewAvatar dummy)
        {
            EnsureActivePreviewInitialized();
            var clipBeingGenerated = _state.CurrentClip;

            _renderingCommands.GenerateSpecificFastMode(
                new List <EeRenderingSample> {
                new EeRenderingSample(AnimationUtility.GetCurveBindings(clipBeingGenerated).Length == 0 ? NothingClip() : clipBeingGenerated, _bufferActive, preview =>
                {
                    _state.ActivePreview.SetPixels(preview.RenderTexture.GetPixels());
                    _state.ActivePreview.Apply();
                    EeAnimationEditorWindow.Obtain().Repaint();

                    Ee.Get().Hooks.PushOnMainRendered(new EeHookOnMainRendered
                    {
                        Clip          = clipBeingGenerated,
                        OutputTexture = preview.RenderTexture
                    });
                })
            },
                dummy,
                _state.CameraIndex,
                EeRenderingCommands.EeDummyAutoHide.Default,
                EeRenderingCommands.EePriority.High
                );
        }
예제 #2
0
        public static Ee Get()
        {
            if (_ee != null)
            {
                return(_ee);
            }

            _ee = new Ee();
            return(_ee);
        }