why can't get pixel depth from proE model window with openGL
I am using pro/Toolkit to develope some code to read pixel depth of proE model from proE view window with openGL function glReadPixels(), but all I got was 1. Actually it should be different value for different pixel of the model displaying. The codes are as following, const int width=1024; const int height=768; float z[width*height]; glReadPixels(0,0,width,height,GL_DEPTH_COMPONENT,GL_FLOAT,z); Any comment is welcome and appreciated. This thread is inactive and closed by the PTC Community Management Team. If you would like to provide a reply and re-open this thread, please notify the moderator and reference the thread. You may also use "Start a topic" button to ask a new question. Please be sure to include what version of the PTC product you are using so another community member knowledgeable about your version may be able to assist.
I'm not sure of it, but I think that Pro/E display is in 3 dimensions only when moving a part (I observed it when playing with "stereo display" option of my graphic card driver). When a part or assembly isn't moved or just dragged, it seems to be a 2D display. I don't know if it could help you...
Thanks for the information. But what does moving mean? rotating? I still think it should have Z information for each pixel even when a part not moving, otherwise it will be no way for proE to perform pick action on the screen.
Yes, rotating. The only thing I know is that, five years ago with WF1 on an HP workstation, the stereoscopic display (NVIDIA Quadro) was effective only when rotating. When I was releasing the middle mouse button, the display became "standard", even if I drag the model... That's why I think display is in 3d only when rotating.