Changeset 10643 in orxonox.OLD for trunk/src/lib
- Timestamp:
- Apr 29, 2007, 6:51:28 PM (18 years ago)
- Location:
- trunk/src/lib/graphics
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/lib/graphics/graphics_engine.cc
r10618 r10643 480 480 void GraphicsEngine::wireframe() 481 481 { 482 glPolygonMode(GL_FRONT, GL_LINE); 482 State::showWireframe(!State::showWireframe()); 483 /* 484 if (State::showWireframe()){} 485 glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); 486 else 487 glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); 488 */ 483 489 } 484 490 -
trunk/src/lib/graphics/importer/bsp/bsp_manager.cc
r10618 r10643 504 504 // glDisable(GL_BLEND); 505 505 } 506 507 if (State::showWireframe()) 508 { 509 glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); 510 glBindTexture(GL_TEXTURE_2D, this->bspFile->whiteLightMap ); 511 glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_DECAL); 512 } 506 513 507 514 glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); 508 515 509 // glColor4f(3.0,3.0,3.0,1.0);510 516 glEnableClientState(GL_VERTEX_ARRAY ); 511 517 glEnableClientState(GL_TEXTURE_COORD_ARRAY ); … … 536 542 glDisableClientState(GL_NORMAL_ARRAY ); 537 543 // glDisableClientState(GL_COLOR_ARRAY); 538 544 545 if (State::showWireframe()) 546 { 547 glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); 548 glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE); 549 } 539 550 } 540 551 … … 592 603 if (Face->effect != -1) return; 593 604 594 595 605 if(Face->lm_index < 0) { 596 606 glActiveTextureARB(GL_TEXTURE1_ARB); … … 602 612 glEnable(GL_TEXTURE_2D); 603 613 } 604 //glColor4f(3.0,3.0,3.0,1.0); 614 615 if (State::showWireframe()) 616 { 617 glPolygonMode(GL_FRONT_AND_BACK, GL_LINE); 618 glBindTexture(GL_TEXTURE_2D, this->bspFile->whiteLightMap ); 619 glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_DECAL); 620 } 621 605 622 606 623 glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA); … … 646 663 glDisableClientState(GL_VERTEX_ARRAY ); 647 664 glDisableClientState(GL_TEXTURE_COORD_ARRAY ); 648 649 665 666 if (State::showWireframe()) 667 { 668 glPolygonMode(GL_FRONT_AND_BACK, GL_FILL); 669 glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE); 670 } 650 671 } 651 672
Note: See TracChangeset
for help on using the changeset viewer.