Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7741 in orxonox.OLD for branches/water/src/world_entities


Ignore:
Timestamp:
May 20, 2006, 11:56:55 AM (18 years ago)
Author:
patrick
Message:

water: i think i eliminated some more bugs. the texture now displayed is strange… it's a simple texture. perhaps bensch knows what happened here :D

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/water/src/world_entities/environments/mapped_water.cc

    r7740 r7741  
    111111{
    112112  glPushAttrib(GL_VIEWPORT_BIT);
    113   glPushMatrix();
     113//   glPushMatrix();
    114114
     115  //glLoadIdentity();
    115116  glViewport(0,0, textureSize, textureSize);
    116117
     118
    117119  // Clear the color and depth bits, reset the matrix and position our camera.
    118   glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
    119   glLoadIdentity();
     120
    120121  //g_Camera.Look();
    121122
     
    159160      glDisable(GL_CLIP_PLANE0);
    160161  }*/
     162}
    161163
    162   // Restore the previous matrix
    163   //glPopMatrix();
    164 
    165     // Bind the current scene to our reflection texture
    166   //glBindTexture(GL_TEXTURE_2D, g_Texture[REFLECTION_ID]);
    167 
    168 
    169 
    170 
    171 }
    172164
    173165void MappedWater::deactivateReflection()
    174166{
    175   glBindTexture(GL_TEXTURE_2D, texture.getTexture());
     167  //glBindTexture(GL_TEXTURE_2D, texture.getTexture());
    176168
    177   mat.setDiffuseMap(&texture, 0);
     169  //mat.setDiffuseMap(&texture, 0);
     170  mat.select();
    178171  glCopyTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, 0, 0, textureSize, textureSize);
    179172
     173
    180174  glPopAttrib();
    181   glPopMatrix();
     175//   glPopMatrix();
    182176}
    183177
Note: See TracChangeset for help on using the changeset viewer.