X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fbackends%2Fopengl%2Fpipelinestate_backend.h;h=a8f2d306109109f440661b066410bb947973940f;hb=a6d84d93ce8c0adde41679a6c6852335e19ada17;hp=566b819c086cbadf120ef232dddd662cabd61a26;hpb=e70662d7812464159f2e47f4bebb69d88f89ae93;p=libs%2Fgl.git diff --git a/source/backends/opengl/pipelinestate_backend.h b/source/backends/opengl/pipelinestate_backend.h index 566b819c..a8f2d306 100644 --- a/source/backends/opengl/pipelinestate_backend.h +++ b/source/backends/opengl/pipelinestate_backend.h @@ -7,25 +7,22 @@ namespace Msp { namespace GL { +class Device; + class OpenGLPipelineState: public NonCopyable { friend class OpenGLCommands; protected: - static const OpenGLPipelineState *last_applied; - static std::vector bound_tex_targets; - static std::vector bound_uniform_blocks; - static unsigned restart_index; - static unsigned n_clip_distances; + mutable Device *applied_to = 0; + mutable unsigned changes = 0; - OpenGLPipelineState(); + OpenGLPipelineState() = default; OpenGLPipelineState(OpenGLPipelineState &&) { } ~OpenGLPipelineState(); void apply() const; -private: - void apply(unsigned) const; -protected: + static void clear(); };