예제 #1
0
        public PostEffectGaussianBlur()
        {
            var g          = Engine.Graphics;
            var baseShader = SwigObject.GetGaussianBlurShader((swig.GraphicsDeviceType)g.GraphicsDeviceType);
            var codeX      = "#define BLUR_X 1\n" + baseShader;
            var codeY      = "#define BLUR_Y 1\n" + baseShader;

            var shaderX = g.CreateShader2D(codeX);

            material2dX = g.CreateMaterial2D(shaderX);

            var shaderY = g.CreateShader2D(codeY);

            material2dY = g.CreateMaterial2D(shaderY);
        }