Changeset 3069 in orxonox.OLD for orxonox/trunk
- Timestamp:
- Dec 3, 2004, 6:34:18 PM (20 years ago)
- Location:
- orxonox/trunk/importer
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
orxonox/trunk/importer/framework.cc
r3068 r3069 1 1 #include "framework.h" 2 2 3 int verbose = 4;3 int verbose = 1; 4 4 5 5 void DrawGLScene() -
orxonox/trunk/importer/material.cc
r2850 r3069 44 44 { 45 45 if (verbose >= 2) 46 printf ("delete Material %s \n", name);46 printf ("delete Material %s.\n", name); 47 47 if (nextMat != NULL) 48 48 delete nextMat; … … 57 57 { 58 58 if (verbose >=2) 59 printf ("adding Material %s \n", mtlName);59 printf ("adding Material %s.\n", mtlName); 60 60 Material* newMat = new Material(mtlName); 61 61 Material* tmpMat = this; … … 64 64 tmpMat = tmpMat->nextMat; 65 65 } 66 67 66 tmpMat->nextMat = newMat; 67 return newMat; 68 68 69 69 } … … 75 75 { 76 76 if (verbose >= 3) 77 printf ("initializing new Material \n");77 printf ("initializing new Material.\n"); 78 78 nextMat = NULL; 79 79 … … 93 93 void Material::setName (char* mtlName) 94 94 { 95 if (verbose >= 3) 96 printf("setting Material Name to %s", mtlName); 95 // if (verbose >= 3) 96 printf("setting Material Name to %s.\n", mtlName); 97 name = new char [strlen(mtlName)]; 97 98 strcpy(name, mtlName); 98 99 // printf ("adding new Material: %s, %p\n", this->getName(), this); … … 135 136 { 136 137 if (verbose >= 3) 137 printf ("setting Diffuse Color of Material %s to r=%f g=%f b=%f \n", name, r, g, b);138 printf ("setting Diffuse Color of Material %s to r=%f g=%f b=%f.\n", name, r, g, b); 138 139 diffuse[0] = r; 139 140 diffuse[1] = g; … … 162 163 { 163 164 if (verbose >=3) 164 printf ("setting Ambient Color of Material %s to r=%f g=%f b=%f \n", name, r, g, b);165 printf ("setting Ambient Color of Material %s to r=%f g=%f b=%f.\n", name, r, g, b); 165 166 ambient[0] = r; 166 167 ambient[1] = g; … … 188 189 { 189 190 if (verbose >= 3) 190 printf ("setting Specular Color of Material %s to r=%f g=%f b=%f \n", name, r, g, b);191 printf ("setting Specular Color of Material %s to r=%f g=%f b=%f.\n", name, r, g, b); 191 192 specular[0] = r; 192 193 specular[1] = g; … … 229 230 { 230 231 if (verbose >= 3) 231 printf ("setting Transparency of Material %s to %f \n", name, trans);232 printf ("setting Transparency of Material %s to %f.\n", name, trans); 232 233 transparency = trans; 233 234 } … … 265 266 searcher = searcher->nextMat; 266 267 } 268 if (verbose >=3) 269 printf ("not found\n"); 267 270 return NULL; 268 271 } -
orxonox/trunk/importer/material.h
r2842 r3069 48 48 49 49 private: 50 char name [50];50 char* name; 51 51 int illumModel; 52 52 float diffuse [4]; -
orxonox/trunk/importer/object.cc
r3068 r3069 391 391 else if (!strncmp(Buffer, "s ", 2)) 392 392 { 393 if (verbose >= 1)393 if (verbose >= 2) 394 394 printf("smoothing groups not supportet yet. line: %s\n", Buffer); 395 395 } … … 644 644 if (verbose >= 2) 645 645 printf ("using material %s for coming Faces.\n", tmpFace->materialString); 646 material->search(tmpFace->materialString)->select(); 646 Material* tmpMat; 647 if ((tmpMat = material->search(tmpFace->materialString)) != NULL) 648 tmpMat->select(); 647 649 648 650 }
Note: See TracChangeset
for help on using the changeset viewer.