public void LoadTestShader_ShouldDrawAllRed() { testRenderImage.BeginDrawing(); GLSLShader currshader = resources.GetShader("RedShader"); currshader.SetUniform("TextureUnit0", testsprite.Texture); currshader.setAsCurrentShader(); testsprite.Draw(); testRenderImage.EndDrawing(); currshader.ResetCurrentShader(); testRenderImage.Blit(0, 0, 1280, 720, Color.White, BlitterSizeMode.Crop); resources.GetSprite("flashlight_mask").Draw(); }
public override void ProcessImage(RenderImage image) { var OstafLikesTheCock = new RenderImage("CockLoverOstaf", image.Height, image.Height); OstafLikesTheCock.BeginDrawing(); image.Blit(0, 0, image.Height, image.Height, Color.White, BlitterSizeMode.Crop); OstafLikesTheCock.EndDrawing(); image.BeginDrawing(); _shader.setAsCurrentShader(); _shader.SetUniform("SceneTexture", OstafLikesTheCock); _shader.setDuration((Math.Abs(_duration))); OstafLikesTheCock.Blit(0, 0, image.Height, image.Height, Color.White, BlitterSizeMode.Crop); image.EndDrawing(); _shader.ResetCurrentShader(); OstafLikesTheCock.Dispose(); }