Aeluned

09-27-2007, 07:22 AM

I hope this will make sense:

Anyone that is familiar with 3DSMax will notice that when a light is placed in the scene as well as a camera and the camera is moved about the light icon stays a fixed size.

In other words, suppose I want to render a unit cube and regardless of where I move the camera I want the cube to remain unit size (even if the camera moves far from the cube or I move the cube far back along the Z-axis).

Currently, I'm using gluProject to project the vertices of the cube and find the size of it after camera transforms. I then determine a scale value based on the projected size of the cube and scale the cube up or down as needed. This sort of works but seems a bit quirky.

Sorry about the long post. If anyone has any idea what I'm talking about and knows how to implement this I would be greatful.

Cheers.

Anyone that is familiar with 3DSMax will notice that when a light is placed in the scene as well as a camera and the camera is moved about the light icon stays a fixed size.

In other words, suppose I want to render a unit cube and regardless of where I move the camera I want the cube to remain unit size (even if the camera moves far from the cube or I move the cube far back along the Z-axis).

Currently, I'm using gluProject to project the vertices of the cube and find the size of it after camera transforms. I then determine a scale value based on the projected size of the cube and scale the cube up or down as needed. This sort of works but seems a bit quirky.

Sorry about the long post. If anyone has any idea what I'm talking about and knows how to implement this I would be greatful.

Cheers.