X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;ds=sidebyside;f=source%2Fcore%2Fpipelinestate.h;h=42543e4dc2596f5de2e2c0a7c71e85f9b64fa4c8;hb=3bc34893905a2df622894aadcb6669f27f186772;hp=9573f9fede7eecc28a61bd7651728bb828c740cf;hpb=8366f8951984aa436938b1bb18a57067ff2260c1;p=libs%2Fgl.git diff --git a/source/core/pipelinestate.h b/source/core/pipelinestate.h index 9573f9fe..42543e4d 100644 --- a/source/core/pipelinestate.h +++ b/source/core/pipelinestate.h @@ -4,13 +4,12 @@ #include #include #include "cullface.h" +#include "pipelinestate_backend.h" namespace Msp { namespace GL { class Blend; -class BufferBackedUniformBlock; -class DefaultUniformBlock; class DepthTest; class Framebuffer; class Program; @@ -21,8 +20,10 @@ class Texture; class UniformBlock; class VertexSetup; -class PipelineState: public NonCopyable +class PipelineState: public PipelineStateBackend { + friend PipelineStateBackend; + private: struct BoundTexture { @@ -74,14 +75,8 @@ private: const Blend *blend; mutable unsigned changes; - static const PipelineState *last_applied; - static std::vector bound_tex_targets; - static std::vector bound_uniform_blocks; - static unsigned restart_index; - public: PipelineState(); - ~PipelineState(); private: template @@ -106,12 +101,6 @@ public: const VertexSetup *get_vertex_setup() const { return vertex_setup; } FaceWinding get_front_face() const { return front_face; } CullMode get_face_cull() const { return face_cull; } - - void apply() const; -private: - void apply(unsigned) const; -public: - static void clear(); }; } // namespace GL