D3D Device won't create, OpenGL won't load textures

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
madoc
Posts: 32
Joined: Fri Feb 11, 2005 10:43 am

D3D Device won't create, OpenGL won't load textures

Post by madoc »

Software renderer works fine, but isn't beefy enough for the code I'm working on.

DirectX9.0c
Vanilla Irrlicht 1.2
Using the precompiled irrlicht.dll that comes with the distro.
MS Visual studio 2005

If I try to use Direct3D8:
Trident Video Accelerator CyberBlade-Ai1 trid3d.dll 5.0.2471.46
Was not able to create Direct3D8 device.
Was not able to create Direct3D8 device.
Could not create DIRECT3D8 Driver.


Exact same for DIRECT3D9 exept it says 9 where it says 8 in the previous example

If I try OpenGL, it works sort of, geometry displays but the textures don't:
Using renderer: OpenGL 1.1.0
GDI Generic: Microsoft Corporation
OpenGL driver version is not 1.2 or better.
Failed to load OpenGL's multitexture extension, proceeding without.
Loaded texture: MorningSky_1.jpg


I can play both direct3d and openGL games on this laptop no problem just irrlicht really dosnt like SOMETHING about my system. I tried updateing directX and my vid drivers to no avail.


I also tired just using the examples and the exact same problems occur.

Any suggestions?
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Your OpenGL driver is far too old. Irrlicht does not support OpenGL 1.1. There had been some problems with low-end cards which did not properly initialize the screens with DirectX, but that should be fixed in the next release. If you still get problems then you should report your directx caps here (if you need it really fast you might want to try Irrlicht SVN).
madoc
Posts: 32
Joined: Fri Feb 11, 2005 10:43 am

Post by madoc »

I figured the 1.1 was the problem with OpenGL, the directX I had no idea since most games work fine.

I'll try the SVN this evening, appreciate the suggestion, thankee.

I never had a problem from home, but traveling and trying to poke at things on my laptop (which isnt all that new)
madoc
Posts: 32
Joined: Fri Feb 11, 2005 10:43 am

Post by madoc »

Alright so I tried to use the SVN, I installed the Dec 2006 DX9 SDK compiled without OpenGL (since it wont work for me anyway) and without DX8 (it couldnt find the includes) and compiled the SVN, reset the targets for the directories in VStudio and recompiled my project against the SVN version of the library.

Irrlicht Engine version 1.2b
Microsoft Windows XP Professional Service Pack 2 (Build 2600)
Using renderer: Direct3D 9.0
Trident Video Accelerator CyberBlade-Ai1 trid3d.dll 5.0.2471.46
Could not create DIRECT3D9 Texture.
Loaded texture: MorningSky_1.jpg
Could not draw triangles, too many primitives(79800), maxium is 65535.

That last line repeats about 5000 times, the skybox (the only geometry in the scene dosnt display (i assume because of the texture error)
This same code worked fine before with the software renderer and worked fine with opengl (other then the complete and utter lack of textures)

Before it would crash trying to create the device, now it creates it, it just dosnt work right :)




The gist of my code:

Code: Select all


	device = 0;
	device=createDevice(driverType,dimension2d<s32>(defaultX,defaultY),colorDepth,true,false,true);
	
	// Failed device creation
	if(device == 0) {
		return 1;
	}
	device->setEventReceiver(this);
	device->setWindowCaption(L"YAE");
	driver = device->getVideoDriver();
	guienv = device->getGUIEnvironment();
	smgr = device->getSceneManager();
	ICameraSceneNode* camera = smgr->addCameraSceneNodeFPS(0,100.0f,1200.0f);
	camera->setPosition(core::vector3df(1900*2,255*2,3700*2));
	camera->setTarget(core::vector3df(2397*2,343*2,2700*2));
	camera->setFarValue(12000.0f);
	// disable mouse cursor
	device->getCursorControl()->setVisible(false);
	smgr->addSkyDomeSceneNode(driver->getTexture("MorningSky_1.jpg"),200,200,1,1);
	while(device->run() && driver) {
		if (device->isWindowActive()) {
			driver->beginScene(true, true, SColor(0,0,0,0));
			smgr->drawAll();
			guienv->drawAll();
			driver->endScene();
		}

	}
	SafeDrop(device);
	//device->drop();
I was asked to post my caps, so I found a tool for it and got this:
http://live.darkemud.com/www/caps.html
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Your skydome is far too huge. Decrease the horizontal and vertical resolution at least by a factor of 10!
And the caps did not include the supported screens, maybe you could post them as well. But with that gfx card you won't get too much fun anyway...
madoc
Posts: 32
Joined: Fri Feb 11, 2005 10:43 am

Post by madoc »

Doc's wernt very clear on what the horizontal and vert were for, I tried 100 to start and I got some wierd artifacts under opengl so I tried 200 and it look good under software it was just insanley slow hence the quest to get d3d or OpenGL working.

I went down to 20,20

Irrlicht Engine version 1.2b
Microsoft Windows XP Professional Service Pack 2 (Build 2600)
Using renderer: Direct3D 9.0
Trident Video Accelerator CyberBlade-Ai1 trid3d.dll 5.0.2471.46
Could not create DIRECT3D9 Texture.
Loaded texture: MorningSky_1.jpg

Is what I get now is what I was geting under OpenGL before, geometry but no texture.

Sorry, supported display modes didnt sound useful thought it would just be resolutions, uploaded that file too.

http://www.darkemud.com/www/caps.html
The display modes link works now.
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

What size is your texture? Your driver only supports 1024x1024 max. The problem with the driver not working before was missing support for 16bit depth (which was added in SVN).
Klasker
Posts: 230
Joined: Thu May 20, 2004 8:53 am
Contact:

Post by Klasker »

OpenGL stopped working for me too after I installed Windows Vista, saying that I have OpenGL 1.1 without the multitexture extension. Direct3D works for me, though.

I don't think Vista is officially supported by Irrlicht, but I don't know if it is Vista or Irrlicht's fault. I have various drivers and it works for none of them. I'm just sticking to Direct3D until Irrlicht or Vista magically solves the problem.
madoc
Posts: 32
Joined: Fri Feb 11, 2005 10:43 am

Post by madoc »

Still using XP, not a vista problem, I doubt this ole IBM R30 laptop could handle it ;)
Texture is 2050x1100, never thought that could be the problem since it worked in the software renderer.
Aha, your right thats all it is, i tried compileing one of the demos against the SVN and it worked fine, well choppy as all hell but that has nothing to do with the engine and everythig to do with the ancient vid card in this thing:)
Post Reply