public static NodePointNode Create(NodePointModel model) { var vs = new VertexShader(vertexCode); var fs = new FragmentShader(fragmentCode); var array = new ShaderArray(vs, fs); var map = new AttributeMap(); map.Add("inPosition", NodePointModel.strPosition); var builder = new RenderMethodBuilder(array, map); var node = new NodePointNode(model, builder); node.Initialize(); return(node); }
private void CreateBonePointNode(string filename) { EZMFile ezmFile = EZMFile.Load(filename); ezmFile.LoadTextures(); var rootElement = this.scene.RootNode; for (int i = 0; i < ezmFile.MeshSystem.Meshes.Length; i++) { EZMMesh mesh = ezmFile.MeshSystem.Meshes[i]; var model = new NodePointModel(mesh.Skeleton.Bones); var node = NodePointNode.Create(model); node.DiffuseColor = Color.Red; rootElement.Children.Add(node); } }