assign name to a loaded mesh?

Started by
0 comments, last by Bob Janova 17 years, 6 months ago
Ok, I know how to load a mesh in with DirectX, but I don't know how to assign a name to it in order to move it around. In Actionscript for Flash, when you loaded an object, you could also assign an instance name to it in the same command. Is this done through classes? If so, I would like to know how. I was also wondering if DirectX had some thing to put at the end of the name in order to move it on an axis. For instance, in Actionscript for Flash, you would go myObject._x = 5; and that would move it to that place on the x axis.
Advertisement
(Disclaimer: I'm not familiar with exactly how DX does this stuff.) I think a Mesh isn't the object itself; you'd typically have a displayable object:
class Object { Mesh mesh; Vector3 position; // or Matrix33 orientation; // ... etc}

... and when you pass the mesh to DirectX for rendering you tell it where to put it using the orientation matrix.

This topic is closed to new replies.

Advertisement