parent
5da5a1972f
commit
5e798ad6d4
@ -740,6 +740,13 @@ void IrrDriver::setMaxTextureSize()
|
|||||||
att.setAttribute("MAX_TEXTURE_SIZE", core::dimension2du(max, max));
|
att.setAttribute("MAX_TEXTURE_SIZE", core::dimension2du(max, max));
|
||||||
} // setMaxTextureSize
|
} // setMaxTextureSize
|
||||||
|
|
||||||
|
// ----------------------------------------------------------------------------
|
||||||
|
void IrrDriver::unsetMaxTextureSize()
|
||||||
|
{
|
||||||
|
io::IAttributes &att = m_video_driver->getNonConstDriverAttributes();
|
||||||
|
att.setAttribute("MAX_TEXTURE_SIZE", core::dimension2du(2048, 2048));
|
||||||
|
} // unsetMaxTextureSize
|
||||||
|
|
||||||
// ----------------------------------------------------------------------------
|
// ----------------------------------------------------------------------------
|
||||||
void IrrDriver::cleanSunInterposer()
|
void IrrDriver::cleanSunInterposer()
|
||||||
{
|
{
|
||||||
|
@ -197,6 +197,7 @@ public:
|
|||||||
void initDevice();
|
void initDevice();
|
||||||
void reset();
|
void reset();
|
||||||
void setMaxTextureSize();
|
void setMaxTextureSize();
|
||||||
|
void unsetMaxTextureSize();
|
||||||
void getOpenGLData(std::string *vendor, std::string *renderer,
|
void getOpenGLData(std::string *vendor, std::string *renderer,
|
||||||
std::string *version);
|
std::string *version);
|
||||||
|
|
||||||
|
@ -26,6 +26,7 @@
|
|||||||
#include "font/bold_face.hpp"
|
#include "font/bold_face.hpp"
|
||||||
#include "font/font_manager.hpp"
|
#include "font/font_manager.hpp"
|
||||||
#include "font/regular_face.hpp"
|
#include "font/regular_face.hpp"
|
||||||
|
#include "graphics/irr_driver.hpp"
|
||||||
#include "guiengine/scalable_font.hpp"
|
#include "guiengine/scalable_font.hpp"
|
||||||
#include "guiengine/screen.hpp"
|
#include "guiengine/screen.hpp"
|
||||||
#include "guiengine/widgets/button_widget.hpp"
|
#include "guiengine/widgets/button_widget.hpp"
|
||||||
@ -190,7 +191,9 @@ void OptionsScreenUI::init()
|
|||||||
Log::warn("OptionsScreenUI",
|
Log::warn("OptionsScreenUI",
|
||||||
"Couldn't find current skin in the list of skins!");
|
"Couldn't find current skin in the list of skins!");
|
||||||
skinSelector->setValue(0);
|
skinSelector->setValue(0);
|
||||||
|
irr_driver->unsetMaxTextureSize();
|
||||||
GUIEngine::reloadSkin();
|
GUIEngine::reloadSkin();
|
||||||
|
irr_driver->setMaxTextureSize();
|
||||||
}
|
}
|
||||||
|
|
||||||
// --- language
|
// --- language
|
||||||
@ -265,7 +268,9 @@ void OptionsScreenUI::eventCallback(Widget* widget, const std::string& name, con
|
|||||||
|
|
||||||
const core::stringw selectedSkin = skinSelector->getStringValue();
|
const core::stringw selectedSkin = skinSelector->getStringValue();
|
||||||
UserConfigParams::m_skin_file = core::stringc(selectedSkin.c_str()).c_str() + std::string(".stkskin");
|
UserConfigParams::m_skin_file = core::stringc(selectedSkin.c_str()).c_str() + std::string(".stkskin");
|
||||||
|
irr_driver->unsetMaxTextureSize();
|
||||||
GUIEngine::reloadSkin();
|
GUIEngine::reloadSkin();
|
||||||
|
irr_driver->setMaxTextureSize();
|
||||||
}
|
}
|
||||||
else if (name == "split_screen_horizontally")
|
else if (name == "split_screen_horizontally")
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user