Exemplo n.º 1
0
        public virtual void Dispose()
        {
            UnregisterRenderRequest();

            if (FrontFbo != null)
            {
                FrontFbo.Dispose();
            }
            if (BackFbo != null)
            {
                BackFbo.Dispose();
            }
            if (FboMs != null)
            {
                FboMs.Dispose();
            }

            Quad.Dispose();

            GameObjectPainter.Dispose();
            EffectPainter.Dispose();
            PostprocessPainter.Dispose();
            OverlayPainter.Dispose();
            ImagePainter.Dispose();
        }
Exemplo n.º 2
0
        public override void Dispose()
        {
            if (_matHblur != null)
            {
                _matHblur.Dispose();
            }
            if (_matVblur != null)
            {
                _matVblur.Dispose();
            }
            if (_sprites != null)
            {
                _sprites.Dispose();
            }
            if (_fb != null)
            {
                _fb.Dispose();
            }
            if (_quad != null)
            {
                _quad.Dispose();
            }

            base.Dispose();
        }
Exemplo n.º 3
0
        public override void Dispose()
        {
            if (_quad != null)
            {
                _quad.Dispose();
            }

            base.Dispose();
        }
Exemplo n.º 4
0
 void IHandler <Resize> .Handle(FrameArgs frame, Resize e)
 {
     _cam = new Camera2D(e.Size, 2);
     if (_quad != null)
     {
         _quad.Dispose();
     }
     _quad = new Quad(new Vector4(0, 0, e.Size.X, e.Size.Y), Vector4.One);
 }
Exemplo n.º 5
0
        /// <inheritdoc />
        protected override void UnloadContent()
        {
            base.UnloadContent();
            Quad.Dispose();
            ShaderReloader.Dispose();
            Effect.Dispose();

            // Restore window width
            Game.Graphics.PreferredBackBufferWidth = GraphicsAdapter.DefaultAdapter.CurrentDisplayMode.Width - 100;
            Game.Graphics.ApplyChanges();
        }
Exemplo n.º 6
0
        public override void Dispose()
        {
            if (_quad1 != null)
            {
                _quad1.Dispose();
            }
            if (_quad2 != null)
            {
                _quad2.Dispose();
            }

            base.Dispose();
        }
Exemplo n.º 7
0
        public virtual void Dispose()
        {
            if (m_overlayEffect != null)
            {
                m_overlayEffect.Dispose();
            }
            if (m_overlayTexture != null)
            {
                m_overlayTexture.Dispose();
            }

            QuadOffset.Dispose();
        }
Exemplo n.º 8
0
 void Release()
 {
     if (_ctx != null)
     {
         _ctx.Dispose();
     }
     if (_surface != null)
     {
         _surface.Dispose();
     }
     if (_mat != null)
     {
         _mat.Dispose();
     }
     if (_quad != null)
     {
         _quad.Dispose();
     }
 }
        public void Dispose()
        {
            ShaderLibrary.Dispose();

            foreach (var pass in Passes)
            {
                pass.Dispose();
            }

            Quad.Dispose();

            CameraUniformBuffer.Dispose();
            SceneUniformBuffer.Dispose();
            MaterialUniformBuffer.Dispose();
            ToneMapUniformBuffer.Dispose();

            ShadowMapFramebuffer.Dispose();
            ShadowMapTexture.Dispose();

            ShadowMapFilteredFramebuffer.Dispose();
            ShadowMapFilteredTexture.Dispose();

            SSSDepthTexture.Dispose();
            SSSHighFramebuffer.Dispose();
            SSSHighTexture.Dispose();
            SSSMiddleFramebuffer.Dispose();
            SSSMiddleTexture.Dispose();
            SSSLowFramebuffer.Dispose();
            SSSLowTexture.Dispose();
            SSSLowFilteredFramebuffer.Dispose();
            SSSLowFilteredTexture.Dispose();

            SceneFramebuffer.Dispose();
            SceneColorTexture.Dispose();
            SceneDepthTexture.Dispose();

            ToneMapFramebuffer.Dispose();
            ToneMapColorTexture.Dispose();
        }
Exemplo n.º 10
0
 protected override void OnDispose()
 {
     fade.Dispose();
 }