Catch broken configurations inside of the Post Processing shaders.

This catches most instances of configuration failures that can happen in a post processing shader.
Gives a user a helpful error message that lets them know what they have failed to set up correctly
This commit is contained in:
Ryan Houdek
2014-08-17 22:57:39 -05:00
parent 9e2fbaf405
commit 2d624780c0
2 changed files with 132 additions and 0 deletions

View File

@ -21,6 +21,7 @@ public:
OPTION_BOOL = 0,
OPTION_FLOAT,
OPTION_INTEGER,
OPTION_INVALID,
};
bool m_bool_value;
@ -75,6 +76,9 @@ private:
std::string m_current_shader;
ConfigMap m_options;
// Verifies if a configurationOption is valid or not
// Returns an error string on error
std::string VerifyOptions(const ConfigMap& config_map);
void LoadOptions(const std::string& code);
void LoadOptionsConfiguration();
};