mirror of
https://github.com/blawar/GLideN64.git
synced 2024-07-07 03:13:49 +00:00
Up shader storage version.
This commit is contained in:
parent
19b2ed6957
commit
f95d819a47
|
@ -64,7 +64,6 @@ char * - GL version string
|
||||||
uint32 - number of shaders
|
uint32 - number of shaders
|
||||||
shaders in binary form
|
shaders in binary form
|
||||||
*/
|
*/
|
||||||
static const u32 ShaderStorageFormatVersion = 0x11U;
|
|
||||||
bool ShaderStorage::saveShadersStorage(const graphics::Combiners & _combiners) const
|
bool ShaderStorage::saveShadersStorage(const graphics::Combiners & _combiners) const
|
||||||
{
|
{
|
||||||
wchar_t fileName[PLUGIN_PATH_SIZE];
|
wchar_t fileName[PLUGIN_PATH_SIZE];
|
||||||
|
@ -80,7 +79,7 @@ bool ShaderStorage::saveShadersStorage(const graphics::Combiners & _combiners) c
|
||||||
if (!fout)
|
if (!fout)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
fout.write((char*)&ShaderStorageFormatVersion, sizeof(ShaderStorageFormatVersion));
|
fout.write((char*)&m_formatVersion, sizeof(m_formatVersion));
|
||||||
|
|
||||||
const u32 configOptionsBitSet = _getConfigOptionsBitSet();
|
const u32 configOptionsBitSet = _getConfigOptionsBitSet();
|
||||||
fout.write((char*)&configOptionsBitSet, sizeof(configOptionsBitSet));
|
fout.write((char*)&configOptionsBitSet, sizeof(configOptionsBitSet));
|
||||||
|
@ -179,7 +178,7 @@ bool ShaderStorage::loadShadersStorage(graphics::Combiners & _combiners)
|
||||||
try {
|
try {
|
||||||
u32 version;
|
u32 version;
|
||||||
fin.read((char*)&version, sizeof(version));
|
fin.read((char*)&version, sizeof(version));
|
||||||
if (version != ShaderStorageFormatVersion)
|
if (version != m_formatVersion)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
u32 optionsSet;
|
u32 optionsSet;
|
||||||
|
|
|
@ -17,6 +17,7 @@ namespace glsl {
|
||||||
bool loadShadersStorage(graphics::Combiners & _combiners);
|
bool loadShadersStorage(graphics::Combiners & _combiners);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
const u32 m_formatVersion = 0x12U;
|
||||||
const opengl::GLInfo & m_glinfo;
|
const opengl::GLInfo & m_glinfo;
|
||||||
opengl::CachedUseProgram * m_useProgram;
|
opengl::CachedUseProgram * m_useProgram;
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue
Block a user