Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3756 in orxonox.OLD


Ignore:
Timestamp:
Apr 8, 2005, 12:54:23 AM (19 years ago)
Author:
bensch
Message:

orxonox/branches: added new branche convention for some showing stuff at the convention

Location:
orxonox/branches/convention
Files:
4 edited
3 copied

Legend:

Unmodified
Added
Removed
  • orxonox/branches/convention/src/Makefile.am

    r3750 r3756  
    7171                 lib/math/vector.cc \
    7272                 lib/math/curve.cc \
    73                  glmenu/glmenu_imagescreen.cc
     73                 glmenu/glmenu_imagescreen.cc \
     74                 world_entities/test_mat.cc
    7475
    7576noinst_HEADERS = orxonox.h \
  • orxonox/branches/convention/src/Makefile.in

    r3750 r3756  
    6969        texture.$(OBJEXT) base_entity.$(OBJEXT) base_object.$(OBJEXT) \
    7070        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)
    7273orxonox_OBJECTS = $(am_orxonox_OBJECTS)
    7374orxonox_LDADD = $(LDADD)
     
    102103@AMDEP_TRUE@    ./$(DEPDIR)/story_entity.Po ./$(DEPDIR)/terrain.Po \
    103104@AMDEP_TRUE@    ./$(DEPDIR)/test_bullet.Po ./$(DEPDIR)/test_gun.Po \
    104 @AMDEP_TRUE@    ./$(DEPDIR)/texture.Po \
     105@AMDEP_TRUE@    ./$(DEPDIR)/test_mat.Po ./$(DEPDIR)/texture.Po \
    105106@AMDEP_TRUE@    ./$(DEPDIR)/track_manager.Po \
    106107@AMDEP_TRUE@    ./$(DEPDIR)/track_node.Po ./$(DEPDIR)/vector.Po \
     
    280281                 lib/math/vector.cc \
    281282                 lib/math/curve.cc \
    282                  glmenu/glmenu_imagescreen.cc
     283                 glmenu/glmenu_imagescreen.cc \
     284                 world_entities/test_mat.cc
    283285
    284286noinst_HEADERS = orxonox.h \
     
    450452@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/test_bullet.Po@am__quote@
    451453@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@
    452455@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/texture.Po@am__quote@
    453456@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/track_manager.Po@am__quote@
     
    10491052@AMDEP_TRUE@@am__fastdepCXX_FALSE@      $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
    10501053@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
     1055test_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
     1063test_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`
    10511070uninstall-info-am:
    10521071
  • orxonox/branches/convention/src/story_entities/world.cc

    r3752 r3756  
    4141#include "glmenu_imagescreen.h"
    4242#include "fontset.h"
     43#include "test_mat.h"
    4344#include "list.h"
    4445
     
    179180  this->debugWorldNr = worldID;
    180181  this->entities = new tList<WorldEntity>();
     182
     183  this->testMat = NULL;
    181184}
    182185
     
    367370        case DEBUG_WORLD_1:
    368371          {
     372            this->testMat = new TestMat();
    369373            lightMan->setPosition(.0, .0, .0);
    370374            lightMan->setAttenuation(1.0, .01, 0.0);
     
    406410            this->nullParent = NullParent::getInstance ();
    407411            this->nullParent->setName ("NullParent");
    408 
     412           
    409413            // !\todo old track-system has to be removed
    410414
     
    738742    }
    739743  delete iterator;
    740  
     744
     745  if (this->testMat)
     746    this->testMat->draw();
     747
    741748  glCallList (objectList);
    742749  //! \todo skysphere is a WorldEntity and should be inside of the world-entity-list.
  • orxonox/branches/convention/src/story_entities/world.h

    r3727 r3756  
    2525class GarbageCollector;
    2626class SimpleAnimation;
     27class TestMat;
    2728
    2829//! The game world Interface
     
    9798
    9899  FontSet* testFont;                  //!< A test Font. \todo fix this, so it is for real.
     100  TestMat* testMat;                   //!< only for convention
    99101  GLMenuImageScreen* glmis;           //!< The Level-Loader Display
    100102
  • orxonox/branches/convention/src/world_entities/test_mat.cc

    r3752 r3756  
    1818#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_WORLD_ENTITY
    1919
    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"
    2426using namespace std;
    2527
     
    2931   \todo this constructor is not jet implemented - do it
    3032*/
    31 ProtoClass::ProtoClass ()
     33TestMat::TestMat ()
    3234{
    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;
    3452}
    3553
     54void TestMat::enable()
     55{
     56  this->enabled = true;
     57}
    3658
    3759/**
     
    3961
    4062*/
    41 ProtoClass::~ProtoClass ()
     63TestMat::~TestMat ()
    4264{
    4365  // delete what has to be deleted here
    4466}
    4567
    46 /**
    47    \brief nonsense - delete this method
    48    \param realy nothing to give
    49    \returns true or false - probably nothing?
    5068
    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) {}
     69void 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  
    11/*!
    2     \file proto_class.h
     2    \file test_mat.h
    33    \brief Definition of the proto class template, used quickly start work
    44    \todo Example: this shows how to use simply add a Marker that here has to be done something.
     
    88*/
    99
    10 #ifndef _PROTO_CLASS_H
    11 #define _PROTO_CLASS_H
     10#ifndef _TEST_MAT_H
     11#define _TEST_MAT_H
    1212
    13 #include "what realy has to be included"
    14 #include "base_object.h"
     13#include "world_entity.h"
    1514
    16 // FORWARD DEFINITION \\
    17 class someClassWeNeed;
    18 
     15// FORWARD DEFINITION
     16class Model;
     17class Material;
    1918
    2019/*class Test;*/ /* forward definition of class Test (without including it here!)*/
     
    2423   here can be some longer description of this class
    2524*/
    26 class ProtoClass : public BaseObject {
     25class TestMat : public WorldEntity
     26{
    2727
    2828 public:
    29   ProtoClass();
    30   virtual ~ProtoClass();
     29  TestMat();
     30  virtual ~TestMat();
    3131
    32   bool doNonSense (int nothing);
     32  void enable();
     33
     34  virtual void draw();
     35
    3336
    3437 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;
    3642
    3743};
    3844
    39 #endif /* _PROTO_CLASS_H */
     45#endif /* _TEST_MAT_H */
Note: See TracChangeset for help on using the changeset viewer.