Klein bottle model.
Inheritance: IBufferable
Ejemplo n.º 1
0
        public static KleinBottleRenderer Create(KleinBottleModel model)
        {
            var shaderCodes = new ShaderCode[2];
            shaderCodes[0] = new ShaderCode(File.ReadAllText(@"shaders\KleinBottleRenderer\KleinBottle.vert"), ShaderType.VertexShader);
            shaderCodes[1] = new ShaderCode(File.ReadAllText(@"shaders\KleinBottleRenderer\KleinBottle.frag"), ShaderType.FragmentShader);
            var map = new AttributeMap();
            map.Add("in_Position", KleinBottleModel.strPosition);
            map.Add("in_TexCoord", KleinBottleModel.strTexCoord);
            var renderer = new KleinBottleRenderer(model, shaderCodes, map, KleinBottleModel.strPosition);
            renderer.ModelSize = model.Lengths;

            return renderer;
        }
Ejemplo n.º 2
0
        public static KleinBottleRenderer Create(KleinBottleModel model)
        {
            var shaderCodes = new ShaderCode[2];

            shaderCodes[0] = new ShaderCode(File.ReadAllText(@"shaders\KleinBottleRenderer\KleinBottle.vert"), ShaderType.VertexShader);
            shaderCodes[1] = new ShaderCode(File.ReadAllText(@"shaders\KleinBottleRenderer\KleinBottle.frag"), ShaderType.FragmentShader);
            var map = new AttributeMap();

            map.Add("in_Position", KleinBottleModel.strPosition);
            map.Add("in_TexCoord", KleinBottleModel.strTexCoord);
            var renderer = new KleinBottleRenderer(model, shaderCodes, map, KleinBottleModel.strPosition);

            renderer.ModelSize = model.Lengths;

            return(renderer);
        }