I am making a application in WPF. I am using a lot the 3DTools. I have a tetrahedron and, inside it, a cube. I want to move the cube in 3D directions.
My tetrahedron, centered in the (0,0,0) rotates using a Trackball (programmatically, I have a transparent border over my viewport to capture the events).
The users for the application think the more naturally way to move the cube inside it is to move it always in a 2D plane (parallel to the screen). So, if I want to move it deeper in the screen, I just rotate the tetrahedron and move it in Y axis, for example. I think this can be a good solution.
I have to problems, and I would like help to solve then: first, when I move my tetrahedron (inside the Trackball) the Trackball looks like moving all the system coordinates. I say this because I draw axis for debug purpose, and those axis are being rotate also. But this is not true - they are moving just because are objects inside the trackball (right?). EDIT Actually, I think the coordinate system inside the trackball are really changing. When I move the cube in Y-X axis, I behaves ok. But if I turn a little bit, and try to move in the Z axis, I see it getting bigger (closer to camera) and smaller (far from camera). =(
So my questions is how to define a plane which will not be rotate by trackball? For me the answer looks something like "ok, just define it outside the track ball" but, as I said (and 3DTools documentation say) I have a border over my viewport... So I do not know how to handle this.
My tetraedron in a set of ScreenSpaceLines3D. I will have to keep the cube inside it. My second question is how to I trace the positions of the vertex of the tetrahedron of it being rotated? I got really disappointed when the Position property gave me the original positions and nothing else. Should I keep the matrix transformations and apply then to my points when I need then?
Sorry for long text, but I really stuck in this not so much programming questions. I am knew in WPF, I still have some lacks of concepts.
Thanks in advance,
Pedro