Performs a pixellate effect on the screen - effectively reducing the resolution without recreating render targets.
This effect was used frequently on the Super Nintendo, such as during transitions.
Inheritance: PostProcessingEffectBase
示例#1
0
        public void InitializeEffects()
        {
            // Create the render target set
            //mRenderTargets = new Dictionary<SurfaceFormat, RenderTargetPair>();

            // Load all effects
            mBloom           = new Bloom();
            mBlur            = new Blur();
            mDirectionalBlur = new DirectionalBlur();
            mRadialBlur      = new RadialBlur();
            mPixellate       = new Pixellate();

            // Create the combine order list
            mEffectCombineOrder = new List <PostProcessingEffectBase>();

            // Add effects to combine order list in default order
            mEffectCombineOrder.Add(mBlur);
            mEffectCombineOrder.Add(mDirectionalBlur);
            mEffectCombineOrder.Add(mRadialBlur);
            mEffectCombineOrder.Add(mBloom);
            mEffectCombineOrder.Add(mPixellate);

            // Initialize all effects
            mBloom.InitializeEffect();
            mBlur.InitializeEffect();
            mDirectionalBlur.InitializeEffect();
            mRadialBlur.InitializeEffect();
            mPixellate.InitializeEffect();
        }
        public void InitializeEffects()
        {
            // Create the render target set
            //mRenderTargets = new Dictionary<SurfaceFormat, RenderTargetPair>();

            // Load all effects
            mBloom = new Bloom();
            mBlur = new Blur();
            mDirectionalBlur = new DirectionalBlur();
            mRadialBlur = new RadialBlur();
            mPixellate = new Pixellate();

            // Create the combine order list
            mEffectCombineOrder = new List<PostProcessingEffectBase>();

            // Add effects to combine order list in default order
            mEffectCombineOrder.Add(mBlur);
            mEffectCombineOrder.Add(mDirectionalBlur);
            mEffectCombineOrder.Add(mRadialBlur);
            mEffectCombineOrder.Add(mBloom);
            mEffectCombineOrder.Add(mPixellate);

            // Initialize all effects
            mBloom.InitializeEffect();
            mBlur.InitializeEffect();
            mDirectionalBlur.InitializeEffect();
            mRadialBlur.InitializeEffect();
            mPixellate.InitializeEffect();
        }