I have create a depth map of a human model using Render To Texture.
First I bulit a bounding box of the model ,then I placed a camera at the centre of the front face of the model’s BB.
The camera far clipping plane is set to the back face of BB, and the near clipping plane is set to the front face.
At last I used the orthographic projection to create the depth map.
the orthographic projection code is :
glortho(fLeft , fRight , fBottom , fTop ,0,m_fModelDepth);
1.I want to read the depth value from the map,but the value is clamped into [0,1].How does it be calculated ?
2.How does the depth value be saved in texture? Does it be saved into each component of texel or only into R component?
the answer is very important to me , thank you very much!!!
[This message has been edited by autumn (edited 09-17-2003).]