X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fbackends%2Fopengl%2Fpipelinestate_backend.h;h=a8f2d306109109f440661b066410bb947973940f;hb=a6d84d93ce8c0adde41679a6c6852335e19ada17;hp=0b1c4a877d056d16cfde9946de07dc9fdc0fde1b;hpb=f82ef715f0d7e1e7d0b93be4b7b89c8ce6bba40b;p=libs%2Fgl.git diff --git a/source/backends/opengl/pipelinestate_backend.h b/source/backends/opengl/pipelinestate_backend.h index 0b1c4a87..a8f2d306 100644 --- a/source/backends/opengl/pipelinestate_backend.h +++ b/source/backends/opengl/pipelinestate_backend.h @@ -7,24 +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(); };