I'm using IrrXML example and this SIrrlichtCreationParameters code:
Code: Select all
param.DriverType = video::EDT_OPENGL; // Testing OPENGL driver
param.WindowSize = core::dimension2d<s32>(CGame::WindowSizeHeight,CGame::WindowSizeHeight);
param.Bits = CGame::Bits;
param.Fullscreen = CGame::FullScreen;
param.Stencilbuffer = CGame::StencilBuffer;
param.Vsync = CGame::VSync;
param.AntiAlias = CGame::AntiAlias;
Code: Select all
std::string FullScreen;
std::string StencilBuffer;
std::string VSync;
std::string AntiAlias;
std::string WindowSizeWidth;
std::string WindowSizeHeight;
std::string Bits;
Code: Select all
void CGame::GetXMLData()
{
while(xml && xml->read())
{
if (!strcmp("windowsizewidth", xml->getNodeName()))
CGame::WindowSizeWidth = xml->getAttributeValueAsFloat("value");
if (!strcmp("windowsizeheight", xml->getNodeName()))
CGame::WindowSizeHeight = xml->getAttributeValue("value");
if (!strcmp("bits", xml->getNodeName()))
CGame::Bits = xml->getAttributeValue("value");
if (!strcmp("fullscreen", xml->getNodeName()))
CGame::FullScreen = xml->getAttributeValue("on");
if (!strcmp("stencilbuffer", xml->getNodeName()))
CGame::StencilBuffer = xml->getAttributeValue("on");
if (!strcmp("vsync", xml->getNodeName()))
CGame::VSync = xml->getAttributeValue("on");
if (!strcmp("antialias", xml->getNodeName()))
CGame::AntiAlias = xml->getAttributeValue("on");
}
}
Code: Select all
D:\SteelHearts\src\CGame.cpp:26: error: no matching function for call to `irr::core::dimension2d<irr::s32>::dimension2d(std::string&, std::string&)'
../../include/Irrlicht/dimension2d.h:18: note: candidates are: irr::core::dimension2d<irr::s32>::dimension2d(const irr::core::dimension2d<irr::s32>&)
../../include/Irrlicht/dimension2d.h:24: note: irr::core::dimension2d<T>::dimension2d(const T&, const T&) [with T = irr::s32]
../../include/Irrlicht/dimension2d.h:21: note: irr::core::dimension2d<T>::dimension2d() [with T = irr::s32]
D:\SteelHearts\src\CGame.cpp:27: error: cannot convert `std::string' to `irr::u8' in assignment
D:\SteelHearts\src\CGame.cpp:28: error: cannot convert `std::string' to `bool' in assignment
D:\SteelHearts\src\CGame.cpp:29: error: cannot convert `std::string' to `bool' in assignment
D:\SteelHearts\src\CGame.cpp:30: error: cannot convert `std::string' to `bool' in assignment
D:\SteelHearts\src\CGame.cpp:31: error: cannot convert `std::string' to `bool' in assignment
=== MinGW Code::Blocks and Irrlicht 1.5