Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 2932 in orxonox.OLD for orxonox/trunk/importer/object.cc


Ignore:
Timestamp:
Nov 20, 2004, 3:00:24 PM (20 years ago)
Author:
bensch
Message:

orxonox/trunk/importer: added vectors from src. better caseCheck-in object.cc::addGLElement

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/importer/object.cc

    r2931 r2932  
    442442
    443443  char* texture;
    444   texture = strstr (vertex, "/");
    445   texture[0] = '\0';
    446   texture ++;
    447   if (verbose>=3)
    448     printf ("includeing texture #%i, and mapping it to group texture #%i, textureArray has %i entries.\n", atoi(texture), (atoi(texture)-1 - currentGroup->firstVertexTexture)*3, currentGroup->vTexture->getCount());
    449   glTexCoord2fv(currentGroup->vTexture->getArray()+(atoi(texture)-1 - currentGroup->firstVertexTexture)*2);
    450 
    451   char* normal;
    452   if ((normal = strstr (texture, "/")) !=NULL)
    453     {
    454       normal[0] = '\0';
    455       normal ++;
    456       //glArrayElement(atoi(vertex)-1);
    457       glNormal3fv(currentGroup->normals->getArray() +(atoi(normal)-1 - currentGroup->firstNormal)*3);
     444  if ((texture = strstr (vertex, "/")) != NULL)
     445    {
     446      texture[0] = '\0';
     447      texture ++;
     448      if (verbose>=3)
     449        printf ("includeing texture #%i, and mapping it to group texture #%i, textureArray has %i entries.\n", atoi(texture), (atoi(texture)-1 - currentGroup->firstVertexTexture)*3, currentGroup->vTexture->getCount());
     450      glTexCoord2fv(currentGroup->vTexture->getArray()+(atoi(texture)-1 - currentGroup->firstVertexTexture)*2);
     451
     452      char* normal;
     453      if ((normal = strstr (texture, "/")) !=NULL)
     454        {
     455          normal[0] = '\0';
     456          normal ++;
     457          //glArrayElement(atoi(vertex)-1);
     458          glNormal3fv(currentGroup->normals->getArray() +(atoi(normal)-1 - currentGroup->firstNormal)*3);
     459        }
    458460    }
    459461  if (verbose>=3)
Note: See TracChangeset for help on using the changeset viewer.