Exemplo n.º 1
0
        private void RenderSFM()
        {
            Texture2D.Disable2DTextures();
            WrippleShaderProgram.Activate();

            GL.PushMatrix();
            GL.PushAttrib(AttribMask.PointBit);
            //GL.PointSize((float)GLElement1.ActualWidth / 500);
            GL.PointSize(2);

            WrippleShaderProgram.ColorX = Colors.Red;
            WrippleShaderProgram.ColorY = Colors.Lime; // Why did MS call it lime?
            WrippleShaderProgram.ColorZ = Colors.Blue;
            WrippleShaderProgram.UpdateProperties();
            sphereList.Draw();

            //WrippleShaderProgram.ColorX = Colors.Magenta;
            //WrippleShaderProgram.ColorY = Colors.Yellow;
            //WrippleShaderProgram.ColorZ = Colors.Cyan;
            //WrippleShaderProgram.UpdateProperties();
            //cylinderList.Draw();
            //boxList.Draw();

            GL.PopAttrib();
            GL.PopMatrix();
            ShaderProgram.DisableShaders();
        }
Exemplo n.º 2
0
 /// <summary>Load the shaders from disk and set them up</summary>
 private void InitializeShaders()
 {
     WrippleShaderProgram  = new WrippleShaderProgram();
     LightingShaderProgram = new LightingShaderProgram();
     PatternShaderProgram  = new PatternShaderProgram();
 }