- Timestamp:
- 09/03/08 01:57:45 (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
GTP/trunk/App/Demos/Vis/FriendlyCulling/src/SceneQuery.cpp
r2892 r2897 137 137 138 138 orthoCam->SetNear(0.0f); 139 orthoCam->Yaw(.5 * M_PI); 139 140 orthoCam->SetDirection(Vector3(0, 0, -1)); 140 141 … … 155 156 glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT); 156 157 157 glFrontFace(GL_CCW); 158 glCullFace(GL_BACK); 159 160 glEnable(GL_CULL_FACE); 158 glDisable(GL_CULL_FACE); 161 159 162 160 glShadeModel(GL_FLAT); 163 161 glEnable(GL_DEPTH_TEST); 164 162 163 glMatrixMode(GL_MODELVIEW); 164 glPushMatrix(); 165 glLoadIdentity(); 166 165 167 glMatrixMode(GL_PROJECTION); 166 168 glPushMatrix(); 169 glLoadIdentity(); 167 170 168 171 glOrtho(+xlen, -xlen, ylen, -ylen, 0.0f, mSceneBox.Size().z); 169 172 170 173 glMatrixMode(GL_MODELVIEW); 171 glPushMatrix();172 174 173 175 orthoCam->SetupCameraView(); … … 175 177 mDepth = new float[texHeight * texWidth]; 176 178 179 Camera *oldCam = renderer->GetCamera(); 180 renderer->SetCamera(orthoCam); 181 177 182 renderer->RenderScene(); 178 183 184 renderer->SetCamera(oldCam); 185 186 187 glEnable(GL_CULL_FACE); 188 189 glMatrixMode(GL_MODELVIEW); 179 190 glPopMatrix(); 191 180 192 glMatrixMode(GL_PROJECTION); 181 182 193 glPopMatrix(); 183 194
Note: See TracChangeset
for help on using the changeset viewer.