1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2025-10-11 00:41:12 +00:00

Moved most uses of glGetTexImage() into a single function with better error checking.

Also small config addition to optionally increase memory allocation size
for temporary texture pixel data; the nouveau drivers seem notoriously
awkward and keep writing over the buffer.
This commit is contained in:
fgenesis 2012-06-15 04:12:20 +02:00
commit 063b1c0dfc
6 changed files with 123 additions and 72 deletions

View file

@ -274,6 +274,12 @@ void UserSettings::save()
}
doc.InsertEndChild(xml_net);
TiXmlElement xml_debug("Debug");
{
xml_debug.SetAttribute("textureMemoryMultiplier", debug.textureMemoryMultiplier);
}
doc.InsertEndChild(xml_debug);
}
#if defined(BBGE_BUILD_UNIX)
@ -555,7 +561,15 @@ void UserSettings::load(bool doApply, const std::string &overrideFile)
TiXmlElement *xml_net = doc.FirstChildElement("Network");
if (xml_net)
{
network.masterServer = xml_net->Attribute("masterServer");
const char *serv = xml_net->Attribute("masterServer");
if (serv)
network.masterServer = serv;
}
TiXmlElement *xml_debug = doc.FirstChildElement("Debug");
if (xml_debug)
{
xml_debug->Attribute("textureMemoryMultiplier", &debug.textureMemoryMultiplier);
}
if (system.locale.empty())
@ -603,6 +617,10 @@ void UserSettings::apply()
dsq->bindInput();
core->settings.prebufferSounds = audio.prebuffer;
if (debug.textureMemoryMultiplier >= 1)
Texture::textureMemoryMultiplier = debug.textureMemoryMultiplier;
#endif
}