Ignore:
Timestamp:
Jan 18, 2011, 2:04:03 AM (11 years ago)
Author:
sam
Message:

Add support for rotated views and stretched tiles.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/scene.cpp

    r221 r222  
    5454    Tile *tiles;
    5555    int ntiles;
     56    float angle;
    5657};
    5758
     
    6061 */
    6162
    62 Scene::Scene()
     63Scene::Scene(float angle)
    6364{
    6465    data = new SceneData();
    6566    data->tiles = 0;
    6667    data->ntiles = 0;
     68    data->angle = angle;
    6769}
    6870
     
    105107    f += 0.05f;
    106108    glTranslatef(320.0f, 240.0f, 0.0f);
    107     glRotatef(-45.0f, 1.0f, 0.0f, 0.0f);
     109    glRotatef(-data->angle, 1.0f, 0.0f, 0.0f);
    108110#if 0
    109111    glRotatef(3.0f * sinf(f), 1.0f, 0.0f, 0.0f);
Note: See TracChangeset for help on using the changeset viewer.