moe
09-24-2005, 01:33 PM
Hi
I have a plane given from a normal and the distance to the origin.
A ground plane would look like this:
normal = (0,1,0)
distance = 0
How would I find a transformation matrix witch would transform the plane or points from the ground plane on to a plane with arbitrary values?
I am not sure that was clear.
If I would actually want to render a ground plane I could use an identity matrix but for other planes I would need a transformation matrix so I can transform the ground plane into the plane represented trough an arbitrary normal and an arbitrary distance.
Side info: Nope this is not homework. I try to find a way so I can sync the results from the physics lib with the gfx output. I can construct point on the searched plane and build a vertex buffer. Then I just render the vertex buffer using an identity matrix. But I would like to know how to use it with meshes. Then I would have a mesh representing a ground plane and use a matrix to put it in place.
Thx for any input.
I have a plane given from a normal and the distance to the origin.
A ground plane would look like this:
normal = (0,1,0)
distance = 0
How would I find a transformation matrix witch would transform the plane or points from the ground plane on to a plane with arbitrary values?
I am not sure that was clear.
If I would actually want to render a ground plane I could use an identity matrix but for other planes I would need a transformation matrix so I can transform the ground plane into the plane represented trough an arbitrary normal and an arbitrary distance.
Side info: Nope this is not homework. I try to find a way so I can sync the results from the physics lib with the gfx output. I can construct point on the searched plane and build a vertex buffer. Then I just render the vertex buffer using an identity matrix. But I would like to know how to use it with meshes. Then I would have a mesh representing a ground plane and use a matrix to put it in place.
Thx for any input.