|
|
|
|
@ -1021,18 +1021,10 @@ template<UnsignedInt dimensions> class MAGNUM_SHADERS_EXPORT FlatGL: public GL::
|
|
|
|
|
} |
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
protected: |
|
|
|
|
/**
|
|
|
|
|
* @brief Construct without running shader compilation and linking |
|
|
|
|
* |
|
|
|
|
*/ |
|
|
|
|
FlatGL(NoInitT, Flags flags |
|
|
|
|
#ifndef MAGNUM_TARGET_GLES2 |
|
|
|
|
, UnsignedInt materialCount, UnsignedInt drawCount |
|
|
|
|
#endif |
|
|
|
|
); |
|
|
|
|
|
|
|
|
|
private: |
|
|
|
|
/* Creates the GL shader program object but nothing else. Internal, used by compile(). */ |
|
|
|
|
explicit FlatGL(NoInitT) {} |
|
|
|
|
|
|
|
|
|
/* Prevent accidentally calling irrelevant functions */ |
|
|
|
|
#ifndef MAGNUM_TARGET_GLES |
|
|
|
|
using GL::AbstractShaderProgram::drawTransformFeedback; |
|
|
|
|
@ -1063,19 +1055,12 @@ template<UnsignedInt dimensions> class MAGNUM_SHADERS_EXPORT FlatGL: public GL::
|
|
|
|
|
template<UnsignedInt dimensions> class FlatGL<dimensions>::CompileState : public FlatGL<dimensions> { |
|
|
|
|
private: |
|
|
|
|
friend class FlatGL; |
|
|
|
|
using FlatGL::FlatGL; |
|
|
|
|
using FlatGL::isLinkFinished; |
|
|
|
|
|
|
|
|
|
CompileState(NoCreateT) : FlatGL(NoCreate), _vert{NoCreate}, _frag{NoCreate} {} |
|
|
|
|
|
|
|
|
|
CompileState(GL::Shader&& vert, GL::Shader&& frag, GL::Version version, Flags flags |
|
|
|
|
#ifndef MAGNUM_TARGET_GLES2 |
|
|
|
|
, UnsignedInt materialCount, UnsignedInt drawCount |
|
|
|
|
#endif |
|
|
|
|
) : FlatGL(NoInit, flags |
|
|
|
|
#ifndef MAGNUM_TARGET_GLES2 |
|
|
|
|
, materialCount, drawCount |
|
|
|
|
#endif |
|
|
|
|
), _vert(std::move(vert)), _frag(std::move(frag)), _version(version) {} |
|
|
|
|
CompileState(FlatGL<dimensions>&& shader, GL:Shader&& vert, GL::Shader&& frag, GL::Version version) : |
|
|
|
|
FlatGL<dimensions>{std::move(shader)}, _vert{std::move(vert)}, _frag{std::move(frag)}, _version{version} {} |
|
|
|
|
|
|
|
|
|
GL::Shader _vert, _frag; |
|
|
|
|
GL::Version _version; |
|
|
|
|
|