示例#1
0
 public FatVertexDesc()
 {
     Decl = new VertexLayoutD3d11(new[]
     {
         new InputElement("POSITION", 0, Format.R32G32B32A32_Float, 0, 0),
         new InputElement("NORMAL", 0, Format.R32G32B32A32_Float, Vector4.SizeInBytes, 0),
         new InputElement("TEXCOORD", 0, Format.R32G32B32A32_Float, Vector4.SizeInBytes * 2, 0),
         new InputElement("TEXCOORD", 1, Format.R32G32B32A32_Float, Vector4.SizeInBytes * 3, 0),
     });
 }
            static public VertexLayoutD3d11 GetVertexDesc()
            {
                if (Decl == null)
                {
                    Decl = new VertexLayoutD3d11(new[]
                    {
                        new InputElement("POSITION", 0, Format.R32G32B32A32_Float, 0, 0),
                        new InputElement("SIZE", 0, Format.R32_Float, Vector4.SizeInBytes, 0),
                    });
                }

                return(Decl);
            }