#pragma once #include "GLExtensions.h" #include "../../runtime/RuntimeShaderArtifact.h" #include #include struct RuntimePreparedShaderProgram { std::string layerId; std::string shaderId; std::string passId; std::string sourceFingerprint; RuntimeShaderArtifact artifact; RuntimeShaderPassArtifact passArtifact; std::vector inputNames; std::string outputName; GLuint program = 0; GLuint vertexShader = 0; GLuint fragmentShader = 0; bool succeeded = false; std::string error; void ReleaseGl() { if (program != 0) glDeleteProgram(program); if (vertexShader != 0) glDeleteShader(vertexShader); if (fragmentShader != 0) glDeleteShader(fragmentShader); program = 0; vertexShader = 0; fragmentShader = 0; } };