public override void Draw(TextureArray2D texture) { // this will draw the checkers background base.Draw(texture); GL.Enable(EnableCap.Blend); GL.BlendFunc(BlendingFactorSrc.SrcAlpha, BlendingFactorDest.OneMinusSrcAlpha); // bind shader shader.Bind(); shader.SetTransform(GetTransform()); shader.SetMipmap((float)models.Display.ActiveMipmap); shader.SetLayer((float)models.Display.ActiveLayer); shader.SetFarplane(CalcFarplane()); shader.SetGrayscale(models.Display.Grayscale); shader.SetCrop(models.Export, models.Display.ActiveLayer); models.GlData.BindSampler(shader.GetTextureLocation(), true, models.Display.LinearInterpolation); texture.Bind(shader.GetTextureLocation()); models.GlData.Vao.DrawQuad(); GL.Disable(EnableCap.Blend); Program.Unbind(); }