Changeset 860


Ignore:
Timestamp:
Aug 25, 2011, 2:07:38 AM (8 years ago)
Author:
sam
Message:

render: add a Gradient class that will be used for dithering later.

Location:
trunk
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/monsterz/title.cpp

    r792 r860  
    7676    float timer, length;
    7777    int nframes, animid;
     78
     79    /* Sky shader test */
     80    Gradient *gradient;
    7881};
    7982
     
    165168
    166169    data->eagle.y = 140 + rand() % 40;
     170
     171    data->gradient = new Gradient(vec3(0.0f, 0.0f, 0.0f),
     172                                  vec3(640.0f, 480.0f, 0.0f));
     173    Ticker::Ref(data->gradient);
    167174
    168175    Input::TrackMouse(this);
     
    391398    for (int n = 0; n < 7; n++)
    392399        Tiler::Deregister(data->event[n]);
     400    Ticker::Unref(data->gradient);
    393401    delete data;
    394402}
  • trunk/src/Makefile.am

    r839 r860  
    1010    world.cpp world.h sample.cpp sample.h sampler.cpp sampler.h \
    1111    text.cpp text.h emitter.cpp emitter.h numeric.h hash.cpp hash.h \
    12     worldentity.cpp worldentity.h image.cpp image.h \
     12    worldentity.cpp worldentity.h image.cpp image.h gradient.cpp gradient.h \
    1313    platform.cpp platform.h \
    1414    \
  • trunk/src/core.h

    r783 r860  
    3333// Entities
    3434#include "entity.h"
     35#include "worldentity.h"
     36
    3537#include "emitter.h"
    3638#include "font.h"
     39#include "gradient.h"
    3740#include "sample.h"
    3841#include "text.h"
    3942#include "tileset.h"
    40 #include "worldentity.h"
    4143#include "world.h"
    4244
Note: See TracChangeset for help on using the changeset viewer.