X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fpipeline.h;h=1e5b6aa4c9894529e44cb0094c5b9a08837b01e6;hb=0ab875bdc9fbf84ecfce883b188410bb45882447;hp=9272f5875add3d1605fc6cd33657997552d95fd9;hpb=7791ca3eac17e355d1de508b1730dc854ed7712d;p=libs%2Fgl.git diff --git a/source/pipeline.h b/source/pipeline.h index 9272f587..1e5b6aa4 100644 --- a/source/pipeline.h +++ b/source/pipeline.h @@ -43,10 +43,10 @@ public: const DepthTest *depth_test; const Blend *blend; const Clipping *clipping; - const Renderable *renderable; + Renderable *renderable; public: - Pass(const Tag &, const Renderable *); + Pass(const Tag &, Renderable *); const Tag &get_tag() const { return tag; } @@ -58,16 +58,16 @@ public: const DepthTest *get_depth_test() const { return depth_test; } const Blend *get_blend() const { return blend; } const Clipping *get_clipping() const { return clipping; } - const Renderable *get_renderable() const { return renderable; } + Renderable *get_renderable() const { return renderable; } }; private: struct Slot { - const Renderable *renderable; + Renderable *renderable; std::set passes; - Slot(const Renderable *); + Slot(Renderable *); }; typedef std::list PassList; @@ -93,21 +93,21 @@ public: // Deprecated void set_camera(const Camera *); Pass &add_pass(const Tag &tag); - void add_renderable(const Renderable &); - void add_renderable_for_pass(const Renderable &, const Tag &); - void remove_renderable(const Renderable &); + void add_renderable(Renderable &); + void add_renderable_for_pass(Renderable &, const Tag &); + void remove_renderable(Renderable &); /** Adds a pass to the pipeline. It's permissible to add the same Renderable multiple times. */ - Pass &add_pass(const Tag &, const Renderable &); + Pass &add_pass(const Tag &, Renderable &); /** Adds a postprocessor to the pipeline. */ void add_postprocessor(PostProcessor &); - virtual void setup_frame() const; - virtual void finish_frame() const; + virtual void setup_frame(Renderer &); + virtual void finish_frame(); - virtual void render(const Tag &tag = Tag()) const; + void render(); virtual void render(Renderer &, const Tag &tag = Tag()) const; private: