Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 4612 in orxonox.OLD for orxonox


Ignore:
Timestamp:
Jun 13, 2005, 12:05:24 AM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: partition the vertices into two different lists

Location:
orxonox/trunk/src
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/lib/collision_detection/obb_tree.cc

    r4611 r4612  
    9696
    9797  /* generate some test vertices */
    98   int const length = 3;
     98  int const length = 6;
    9999  sVec3D* vertList = new sVec3D[length];
    100   sVec3D data[length]  = {{5.0, 0.0, 0.0},{2.0, 0.0, 5.0},{14.0, 0.0, 0.0}};//, {5.0, 0.0, 1.0}, {12.0, 0.0, 8.0}, {3.0, 5.0, 4.9}};
     100  sVec3D data[length]  = {{5.0, 0.0, 0.0},{2.0, 0.0, 5.0},{14.0, 0.0, 0.0}, {5.0, 0.0, 1.0}, {12.0, 0.0, 8.0}, {3.0, 5.0, 4.9}};
    101101
    102102  for(int i = 0; i < length; ++i)
  • orxonox/trunk/src/lib/collision_detection/obb_tree_node.cc

    r4611 r4612  
    304304  tList<sVec3D>      partition2;                           //!< the vertex partition 2
    305305
     306  for(int i = 0; i < box->numOfVertices; ++i)
     307  {
     308    if( separationPlane.distancePoint(box->vertices[i]) > 0.0f)
     309      partition1.add(&box->vertices[i]);
     310    else
     311      partition2.add(&box->vertices[i]);
     312  }
     313  partition2.add(&box->vertices[vertexIndex]);
     314
     315  printf("\npartition1: got %i vertices/ partition 2: got %i vertices\n", partition1.getSize(), partition2.getSize());
    306316
    307317}
  • orxonox/trunk/src/subprojects/collision_detection/Makefile.am

    r4583 r4612  
    2121                   collision_detection.cc \
    2222                   $(MAINSRCDIR)/util/loading/load_param.cc \
     23                   $(MAINSRCDIR)/lib/util/substring.cc \                   
    2324                   $(MAINSRCDIR)/lib/util/ini_parser.cc \
    2425                   $(MAINSRCDIR)/lib/graphics/light.cc \
  • orxonox/trunk/src/subprojects/collision_detection/Makefile.in

    r4583 r4612  
    5353am_collision_OBJECTS = collision-framework.$(OBJEXT) \
    5454        collision-collision_detection.$(OBJEXT) \
    55         collision-load_param.$(OBJEXT) collision-ini_parser.$(OBJEXT) \
    56         collision-light.$(OBJEXT) collision-state.$(OBJEXT) \
    57         collision-camera.$(OBJEXT) collision-graphics_engine.$(OBJEXT) \
     55        collision-load_param.$(OBJEXT) collision-substring.$(OBJEXT) \
     56        collision-ini_parser.$(OBJEXT) collision-light.$(OBJEXT) \
     57        collision-state.$(OBJEXT) collision-camera.$(OBJEXT) \
     58        collision-graphics_engine.$(OBJEXT) \
    5859        collision-base_object.$(OBJEXT) collision-vector.$(OBJEXT) \
    5960        collision-resource_manager.$(OBJEXT) \
     
    8687@AMDEP_TRUE@    ./$(DEPDIR)/collision-resource_manager.Po \
    8788@AMDEP_TRUE@    ./$(DEPDIR)/collision-state.Po \
     89@AMDEP_TRUE@    ./$(DEPDIR)/collision-substring.Po \
    8890@AMDEP_TRUE@    ./$(DEPDIR)/collision-text_engine.Po \
    8991@AMDEP_TRUE@    ./$(DEPDIR)/collision-vector.Po
     
    227229                   collision_detection.cc \
    228230                   $(MAINSRCDIR)/util/loading/load_param.cc \
     231                   $(MAINSRCDIR)/lib/util/substring.cc \
    229232                   $(MAINSRCDIR)/lib/util/ini_parser.cc \
    230233                   $(MAINSRCDIR)/lib/graphics/light.cc \
     
    323326@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/collision-resource_manager.Po@am__quote@
    324327@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/collision-state.Po@am__quote@
     328@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/collision-substring.Po@am__quote@
    325329@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/collision-text_engine.Po@am__quote@
    326330@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/collision-vector.Po@am__quote@
     
    389393@AMDEP_TRUE@@am__fastdepCXX_FALSE@      $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
    390394@am__fastdepCXX_FALSE@  $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(collision_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o collision-load_param.obj `if test -f '$(MAINSRCDIR)/util/loading/load_param.cc'; then $(CYGPATH_W) '$(MAINSRCDIR)/util/loading/load_param.cc'; else $(CYGPATH_W) '$(srcdir)/$(MAINSRCDIR)/util/loading/load_param.cc'; fi`
     395
     396collision-substring.o: $(MAINSRCDIR)/lib/util/substring.cc
     397@am__fastdepCXX_TRUE@   if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(collision_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT collision-substring.o -MD -MP -MF "$(DEPDIR)/collision-substring.Tpo" -c -o collision-substring.o `test -f '$(MAINSRCDIR)/lib/util/substring.cc' || echo '$(srcdir)/'`$(MAINSRCDIR)/lib/util/substring.cc; \
     398@am__fastdepCXX_TRUE@   then mv -f "$(DEPDIR)/collision-substring.Tpo" "$(DEPDIR)/collision-substring.Po"; else rm -f "$(DEPDIR)/collision-substring.Tpo"; exit 1; fi
     399@AMDEP_TRUE@@am__fastdepCXX_FALSE@      source='$(MAINSRCDIR)/lib/util/substring.cc' object='collision-substring.o' libtool=no @AMDEPBACKSLASH@
     400@AMDEP_TRUE@@am__fastdepCXX_FALSE@      depfile='$(DEPDIR)/collision-substring.Po' tmpdepfile='$(DEPDIR)/collision-substring.TPo' @AMDEPBACKSLASH@
     401@AMDEP_TRUE@@am__fastdepCXX_FALSE@      $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
     402@am__fastdepCXX_FALSE@  $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(collision_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o collision-substring.o `test -f '$(MAINSRCDIR)/lib/util/substring.cc' || echo '$(srcdir)/'`$(MAINSRCDIR)/lib/util/substring.cc
     403
     404collision-substring.obj: $(MAINSRCDIR)/lib/util/substring.cc
     405@am__fastdepCXX_TRUE@   if $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(collision_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -MT collision-substring.obj -MD -MP -MF "$(DEPDIR)/collision-substring.Tpo" -c -o collision-substring.obj `if test -f '$(MAINSRCDIR)/lib/util/substring.cc'; then $(CYGPATH_W) '$(MAINSRCDIR)/lib/util/substring.cc'; else $(CYGPATH_W) '$(srcdir)/$(MAINSRCDIR)/lib/util/substring.cc'; fi`; \
     406@am__fastdepCXX_TRUE@   then mv -f "$(DEPDIR)/collision-substring.Tpo" "$(DEPDIR)/collision-substring.Po"; else rm -f "$(DEPDIR)/collision-substring.Tpo"; exit 1; fi
     407@AMDEP_TRUE@@am__fastdepCXX_FALSE@      source='$(MAINSRCDIR)/lib/util/substring.cc' object='collision-substring.obj' libtool=no @AMDEPBACKSLASH@
     408@AMDEP_TRUE@@am__fastdepCXX_FALSE@      depfile='$(DEPDIR)/collision-substring.Po' tmpdepfile='$(DEPDIR)/collision-substring.TPo' @AMDEPBACKSLASH@
     409@AMDEP_TRUE@@am__fastdepCXX_FALSE@      $(CXXDEPMODE) $(depcomp) @AMDEPBACKSLASH@
     410@am__fastdepCXX_FALSE@  $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(collision_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS) -c -o collision-substring.obj `if test -f '$(MAINSRCDIR)/lib/util/substring.cc'; then $(CYGPATH_W) '$(MAINSRCDIR)/lib/util/substring.cc'; else $(CYGPATH_W) '$(srcdir)/$(MAINSRCDIR)/lib/util/substring.cc'; fi`
    391411
    392412collision-ini_parser.o: $(MAINSRCDIR)/lib/util/ini_parser.cc
Note: See TracChangeset for help on using the changeset viewer.