Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7115 in orxonox.OLD for trunk/src/world_entities


Ignore:
Timestamp:
Feb 8, 2006, 2:42:08 AM (19 years ago)
Author:
bensch
Message:

movie-work

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/world_entities/movie_entity.cc

    r7049 r7115  
    6363  LoadParam(root, "name", this, MovieEntity, loadMovie);
    6464  LoadParam(root, "axis", this, MovieEntity, setAxis);
    65   //LoadParam(root, "rotation", this, MovieEntity, setRotation);
     65  LoadParam(root, "rotation", this, MovieEntity, setRotation);
    6666  LoadParam(root, "size", this, MovieEntity, setSize);
    6767  LoadParam(root, "fps", this, MovieEntity, setFPS);
     
    127127  }
    128128
    129   if(rotation != 0)
    130     axis = (int)(axis + (time * 360/rotation))%360;
     129  axis += (time * rotation/360.0);
    131130}
    132131
     
    142141    false;
    143142
     143  glPushAttrib(GL_ENABLE_BIT);
     144  glDisable(GL_LIGHTING);
     145  glDisable(GL_BLEND);
     146
     147  glEnable(GL_TEXTURE_2D);
     148  glBindTexture(GL_TEXTURE_2D, media_container->getFrameTexture(counter));
     149
    144150  glPushMatrix();
    145151  glTranslatef (this->getAbsCoor ().x,
     
    148154  glRotatef(axis, 0.0f, 1.0f, 0.0f);
    149155//PRINTF(0)("axis: %f\n", axis);
    150 
    151   glPushAttrib(GL_ENABLE_BIT);
    152   glDisable(GL_LIGHTING);
    153   glDisable(GL_BLEND);
    154 
    155   glEnable(GL_TEXTURE_2D);
    156   glBindTexture(GL_TEXTURE_2D, media_container->getFrameTexture(counter));
    157156
    158157  glColor3f(1.0, 1.0, 1.0);
     
    165164  glEnd();
    166165
     166  glPopMatrix();
    167167  glPopAttrib();
    168 
    169   glPopMatrix();
    170 
    171168}
Note: See TracChangeset for help on using the changeset viewer.