Changeset 6989 in orxonox.OLD for trunk/src/world_entities
- Timestamp:
- Feb 2, 2006, 10:02:24 PM (19 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/world_entities/image_entity.cc
r6852 r6989 128 128 void ImageEntity::tick(float dt) 129 129 { 130 // let the crosshair rotate131 //this->shiftDir2D(dt * rotationSpeed);132 130 133 134 float z = 0.0f;135 glReadPixels ((int)this->getAbsCoor2D().x,136 GraphicsEngine::getInstance()->getResolutionY()-(int)this->getAbsCoor2D().y-1,137 1,138 1,139 GL_DEPTH_COMPONENT,140 GL_FLOAT,141 &z);142 143 144 GLdouble objX=.0, objY=.0, objZ=.0;145 gluUnProject(this->getAbsCoor2D().x,146 GraphicsEngine::getInstance()->getResolutionY()-this->getAbsCoor2D().y-1,147 .99, // z148 GraphicsEngine::modMat,149 GraphicsEngine::projMat,150 GraphicsEngine::viewPort,151 &objX,152 &objY,153 &objZ );154 155 //this->setAbsCoor(objX, objY, objZ);156 131 } 157 132
Note: See TracChangeset
for help on using the changeset viewer.