Changeset 3756 in orxonox.OLD for orxonox/branches/convention
- Timestamp:
- Apr 8, 2005, 12:54:23 AM (20 years ago)
- Location:
- orxonox/branches/convention
- Files:
-
- 4 edited
- 3 copied
Legend:
- Unmodified
- Added
- Removed
-
orxonox/branches/convention/src/Makefile.am
r3750 r3756 71 71 lib/math/vector.cc \ 72 72 lib/math/curve.cc \ 73 glmenu/glmenu_imagescreen.cc 73 glmenu/glmenu_imagescreen.cc \ 74 world_entities/test_mat.cc 74 75 75 76 noinst_HEADERS = orxonox.h \ -
orxonox/branches/convention/src/Makefile.in
r3750 r3756 69 69 texture.$(OBJEXT) base_entity.$(OBJEXT) base_object.$(OBJEXT) \ 70 70 ini_parser.$(OBJEXT) list.$(OBJEXT) resource_manager.$(OBJEXT) \ 71 vector.$(OBJEXT) curve.$(OBJEXT) glmenu_imagescreen.$(OBJEXT) 71 vector.$(OBJEXT) curve.$(OBJEXT) glmenu_imagescreen.$(OBJEXT) \ 72 test_mat.$(OBJEXT) 72 73 orxonox_OBJECTS = $(am_orxonox_OBJECTS) 73 74 orxonox_LDADD = $(LDADD) … … 102 103 @AMDEP_TRUE@ ./$(DEPDIR)/story_entity.Po ./$(DEPDIR)/terrain.Po \ 103 104 @AMDEP_TRUE@ ./$(DEPDIR)/test_bullet.Po ./$(DEPDIR)/test_gun.Po \ 104 @AMDEP_TRUE@ ./$(DEPDIR)/te xture.Po \105 @AMDEP_TRUE@ ./$(DEPDIR)/test_mat.Po ./$(DEPDIR)/texture.Po \ 105 106 @AMDEP_TRUE@ ./$(DEPDIR)/track_manager.Po \ 106 107 @AMDEP_TRUE@ ./$(DEPDIR)/track_node.Po ./$(DEPDIR)/vector.Po \ … … 280 281 lib/math/vector.cc \ 281 282 lib/math/curve.cc \ 282 glmenu/glmenu_imagescreen.cc 283 glmenu/glmenu_imagescreen.cc \ 284 world_entities/test_mat.cc 283 285 284 286 noinst_HEADERS = orxonox.h \ … … 450 452 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_bullet.Po@am__quote@ 451 453 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_gun.Po@am__quote@ 454 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_mat.Po@am__quote@ 452 455 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/texture.Po@am__quote@ 453 456 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/track_manager.Po@am__quote@ … … 1049 1052 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 1050 1053 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o glmenu_imagescreen.obj `if test -f 'glmenu/glmenu_imagescreen.cc'; then $(CYGPATH_W) 'glmenu/glmenu_imagescreen.cc'; else $(CYGPATH_W) '$(srcdir)/glmenu/glmenu_imagescreen.cc'; fi` 1054 1055 test_mat.o: world_entities/test_mat.cc 1056 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_mat.o -MD -MP -MF "$(DEPDIR)/test_mat.Tpo" -c -o test_mat.o `test -f 'world_entities/test_mat.cc' || echo '$(srcdir)/'`world_entities/test_mat.cc; \ 1057 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/test_mat.Tpo" "$(DEPDIR)/test_mat.Po"; else rm -f "$(DEPDIR)/test_mat.Tpo"; exit 1; fi 1058 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='world_entities/test_mat.cc' object='test_mat.o' libtool=no @AMDEPBACKSLASH@ 1059 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/test_mat.Po' tmpdepfile='$(DEPDIR)/test_mat.TPo' @AMDEPBACKSLASH@ 1060 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 1061 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_mat.o `test -f 'world_entities/test_mat.cc' || echo '$(srcdir)/'`world_entities/test_mat.cc 1062 1063 test_mat.obj: world_entities/test_mat.cc 1064 @am__fastdepCXX_TRUE@ if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT test_mat.obj -MD -MP -MF "$(DEPDIR)/test_mat.Tpo" -c -o test_mat.obj `if test -f 'world_entities/test_mat.cc'; then $(CYGPATH_W) 'world_entities/test_mat.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/test_mat.cc'; fi`; \ 1065 @am__fastdepCXX_TRUE@ then mv -f "$(DEPDIR)/test_mat.Tpo" "$(DEPDIR)/test_mat.Po"; else rm -f "$(DEPDIR)/test_mat.Tpo"; exit 1; fi 1066 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ source='world_entities/test_mat.cc' object='test_mat.obj' libtool=no @AMDEPBACKSLASH@ 1067 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ depfile='$(DEPDIR)/test_mat.Po' tmpdepfile='$(DEPDIR)/test_mat.TPo' @AMDEPBACKSLASH@ 1068 @AMDEP_TRUE@@am__fastdepCXX_FALSE@ $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@ 1069 @am__fastdepCXX_FALSE@ $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o test_mat.obj `if test -f 'world_entities/test_mat.cc'; then $(CYGPATH_W) 'world_entities/test_mat.cc'; else $(CYGPATH_W) '$(srcdir)/world_entities/test_mat.cc'; fi` 1051 1070 uninstall-info-am: 1052 1071 -
orxonox/branches/convention/src/story_entities/world.cc
r3752 r3756 41 41 #include "glmenu_imagescreen.h" 42 42 #include "fontset.h" 43 #include "test_mat.h" 43 44 #include "list.h" 44 45 … … 179 180 this->debugWorldNr = worldID; 180 181 this->entities = new tList<WorldEntity>(); 182 183 this->testMat = NULL; 181 184 } 182 185 … … 367 370 case DEBUG_WORLD_1: 368 371 { 372 this->testMat = new TestMat(); 369 373 lightMan->setPosition(.0, .0, .0); 370 374 lightMan->setAttenuation(1.0, .01, 0.0); … … 406 410 this->nullParent = NullParent::getInstance (); 407 411 this->nullParent->setName ("NullParent"); 408 412 409 413 // !\todo old track-system has to be removed 410 414 … … 738 742 } 739 743 delete iterator; 740 744 745 if (this->testMat) 746 this->testMat->draw(); 747 741 748 glCallList (objectList); 742 749 //! \todo skysphere is a WorldEntity and should be inside of the world-entity-list. -
orxonox/branches/convention/src/story_entities/world.h
r3727 r3756 25 25 class GarbageCollector; 26 26 class SimpleAnimation; 27 class TestMat; 27 28 28 29 //! The game world Interface … … 97 98 98 99 FontSet* testFont; //!< A test Font. \todo fix this, so it is for real. 100 TestMat* testMat; //!< only for convention 99 101 GLMenuImageScreen* glmis; //!< The Level-Loader Display 100 102 -
orxonox/branches/convention/src/world_entities/test_mat.cc
r3752 r3756 18 18 #define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WORLD_ENTITY 19 19 20 #include "proto_class.h" 21 22 #include "stdincl.h" // maybe 23 20 #include "test_mat.h" 21 #include "resource_manager.h" 22 #include "material.h" 23 #include "model.h" 24 #include "primitive_model.h" 25 #include "light.h" 24 26 using namespace std; 25 27 … … 29 31 \todo this constructor is not jet implemented - do it 30 32 */ 31 ProtoClass::ProtoClass()33 TestMat::TestMat () 32 34 { 33 this->setClassName ("ProtoClass"); 35 this->setClassName ("TestMat"); 36 37 /* this->model1 = (Model*)ResourceManager::getInstance()->load("cube", PRIM, RP_LEVEL); 38 this->model2 = (Model*)ResourceManager::getInstance()->load("sphere", PRIM, RP_LEVEL); 39 this->model3 = (Model*)ResourceManager::getInstance()->load("cylinder", PRIM, RP_LEVEL); 40 this->model4 = (Model*)ResourceManager::getInstance()->load("cone", PRIM, RP_LEVEL); 41 */ 42 this->model1 = new PrimitiveModel(SPHERE); 43 this->model2 = new PrimitiveModel(CUBE); 44 this->model3 = new PrimitiveModel(CONE); 45 this->model4 = new PrimitiveModel(CYLINDER); 46 this->mat1 = new Material(); 47 this->mat2 = new Material(); 48 this->mat3 = new Material(); 49 this->mat4 = new Material(); 50 51 this->enabled = false; 34 52 } 35 53 54 void TestMat::enable() 55 { 56 this->enabled = true; 57 } 36 58 37 59 /** … … 39 61 40 62 */ 41 ProtoClass::~ProtoClass()63 TestMat::~TestMat () 42 64 { 43 65 // delete what has to be deleted here 44 66 } 45 67 46 /**47 \brief nonsense - delete this method48 \param realy nothing to give49 \returns true or false - probably nothing?50 68 51 this is just to show the doxygen abilities (this for example is an extension for a long comment) 52 */ 53 bool ProtoClass::doNonSense (int nothing) {} 69 void TestMat::draw() 70 { 71 if (this->enabled) 72 { 73 glPushMatrix(); 74 this->mat1->select(); 75 this->model1->draw(); 76 77 glTranslatef(0,0,2); 78 this->mat2->select(); 79 this->model2->draw(); 80 81 glTranslatef(0,2,-2); 82 this->mat3->select(); 83 this->model3->draw(); 84 85 glTranslatef(0,0,2); 86 this->mat4->select(); 87 this->model4->draw(); 88 glPopMatrix(); 89 } 90 } -
orxonox/branches/convention/src/world_entities/test_mat.h
r3752 r3756 1 1 /*! 2 \file proto_class.h2 \file test_mat.h 3 3 \brief Definition of the proto class template, used quickly start work 4 4 \todo Example: this shows how to use simply add a Marker that here has to be done something. … … 8 8 */ 9 9 10 #ifndef _ PROTO_CLASS_H11 #define _ PROTO_CLASS_H10 #ifndef _TEST_MAT_H 11 #define _TEST_MAT_H 12 12 13 #include "what realy has to be included" 14 #include "base_object.h" 13 #include "world_entity.h" 15 14 16 // FORWARD DEFINITION \\17 class someClassWeNeed;18 15 // FORWARD DEFINITION 16 class Model; 17 class Material; 19 18 20 19 /*class Test;*/ /* forward definition of class Test (without including it here!)*/ … … 24 23 here can be some longer description of this class 25 24 */ 26 class ProtoClass : public BaseObject { 25 class TestMat : public WorldEntity 26 { 27 27 28 28 public: 29 ProtoClass();30 virtual ~ ProtoClass();29 TestMat(); 30 virtual ~TestMat(); 31 31 32 bool doNonSense (int nothing); 32 void enable(); 33 34 virtual void draw(); 35 33 36 34 37 private: 35 int nonSense; //!< doxygen tag here like this for all the variables - delete this variable if you use this 38 Model* model1,* model2,* model3,* model4; 39 Material* mat1, *mat2, *mat3, *mat4; 40 41 bool enabled; 36 42 37 43 }; 38 44 39 #endif /* _ PROTO_CLASS_H */45 #endif /* _TEST_MAT_H */
Note: See TracChangeset
for help on using the changeset viewer.