Changeset 4824 in orxonox.OLD for orxonox/trunk/src/world_entities/weapons
- Timestamp:
- Jul 8, 2005, 1:24:12 PM (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/src/world_entities/weapons/crosshair.cc
r4823 r4824 115 115 GraphicsEngine::storeMatrices(); 116 116 117 GLdouble z; 117 GLfloat z; 118 glReadPixels ((int)position2D[0], GraphicsEngine::getInstance()->getResolutionY()-(int)position2D[1], 1, 1, GL_DEPTH_COMPONENT, GL_DOUBLE, &z); 119 120 printf("%p:: %d %d %f\n",this, (int)position2D[0], (int)position2D[1], z); 121 118 122 GLdouble objX, objY, objZ; 119 123 if (gluUnProject(position2D[0], 120 124 GraphicsEngine::getInstance()->getResolutionY()-position2D[1], 121 .8,125 z, 122 126 GraphicsEngine::modMat, 123 127 GraphicsEngine::projMat, … … 126 130 &objY, 127 131 &objZ )); 128 132 /* 129 133 glBegin(GL_TRIANGLES); 130 134 glColor3f(1,0,0); … … 133 137 glVertex3f(objX, objY, objZ+1); 134 138 glEnd(); 139 */ 135 140 }
Note: See TracChangeset
for help on using the changeset viewer.