X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Frenderer.h;h=1be1a4549211828d8b3dedfeea7898a4c0a526b3;hb=db2fd517dcd215e9d16345287d413f2a64f5ba03;hp=a45b2943004d0beb96c654ad0f6796de4b673e3a;hpb=8aea0f65f9ab7d603e47cf4479388af246cc8400;p=libs%2Fgl.git diff --git a/source/renderer.h b/source/renderer.h index a45b2943..1be1a454 100644 --- a/source/renderer.h +++ b/source/renderer.h @@ -4,6 +4,7 @@ #include #include #include "matrix.h" +#include "programdata.h" #include "tag.h" namespace Msp { @@ -13,9 +14,9 @@ class Batch; class Buffer; class Camera; class Material; +class Mesh; class Lighting; class Program; -class ProgramData; class Renderable; class Texture; class Texturing; @@ -64,11 +65,13 @@ private: { const Texture *texture; const Texturing *texturing; + unsigned lowest_effect_texunit; const Material *material; const Lighting *lighting; Matrix lighting_matrix; const Program *shprog; unsigned shdata_count; + const Mesh *mesh; const WindingTest *winding_test; bool reverse_winding; @@ -92,6 +95,7 @@ private: std::vector state_stack; State *state; bool lighting_changed; + ProgramData standard_shdata; std::vector shdata_stack; bool shdata_changed; const Buffer *element_buffer; @@ -107,6 +111,7 @@ public: void set_texture(const Texture *); void set_texturing(const Texturing *); + unsigned allocate_effect_texunit(); void set_material(const Material *); void set_lighting(const Lighting *); @@ -120,6 +125,7 @@ public: Renderer state is popped. */ void add_shader_data(const ProgramData &data); + void set_mesh(const Mesh *); void set_element_buffer(const Buffer *); void set_winding_test(const WindingTest *); void set_reverse_winding(bool);