(i think this is a major bug)
Code: Select all
//standard things
#include <irrlicht.h>
using namespace irr;
using namespace core;
using namespace scene;
using namespace video;
using namespace io;
using namespace gui;
#ifdef _IRR_WINDOWS_
#pragma comment(lib, "Irrlicht.lib")
#pragma comment(linker, "/subsystem:windows /ENTRY:mainCRTStartup")
#endif
int main()
{
IrrlichtDevice *device =
createDevice( video::EDT_DIRECT3D8, dimension2d<u32>(640, 480), 16,
true, false, false, 0);
if (!device)
return 1;
device->setWindowCaption(L"Hello World!");
IVideoDriver* driver = device->getVideoDriver();
ISceneManager* smgr = device->getSceneManager();
IGUIEnvironment* guienv = device->getGUIEnvironment();
guienv->addStaticText(L"Hello World!",
rect<s32>(10,10,260,22), true);
smgr->addCameraSceneNode(0, vector3df(0,30,-40), vector3df(0,5,0));
WAY 1)
Code: Select all
while(device->run())
{
if(device->isWindowActive())
{
driver->beginScene(true, true, SColor(255,100,101,140));
smgr->drawAll();
guienv->drawAll();
driver->endScene();
}
else
device->yield();
}
device->drop();
return 0;
Resizing window (640 480)
Resetting D3D8 device.
'01.HelloWorld.exe': loaded 'C:\Windows\System32\atipdlxx.dll'
'01.HelloWorld.exe': unloaded 'C:\Windows\System32\atipdlxx.dll'
Resizing window (160 25)
Resetting D3D8 device.
Resetting failed due to device lost.
WAY 2)
Code: Select all
while(device->run())
{
driver->beginScene(true, true, SColor(255,100,101,140));
smgr->drawAll();
guienv->drawAll();
driver->endScene();
}
device->drop();
return 0;
with that code (a little simpler) i get a different(maybe the same) bug:
the debug output is:
DIRECT3D8 end scene failed.
DIRECT3D8 end scene failed.
DIRECT3D8 end scene failed.
DIRECT3D8 end scene failed.
DIRECT3D8 end scene failed.
DIRECT3D8 end scene failed.
(and continue to infinite..)
I get the bug only when running the window in fullscreen mode using D3D8 or D3D9 drivers. Nothing strange appens under OpenGL,Software or BurningsVideo drivers.
How to get the bug:
Continue changin the window using ALT+TAB and then restore the irrlicht application window clicking on its icon in the applications bar.
I have a ATI mobility radeon HD4570 and windows vista .
Any one get the same bug?