[fixed] SDL device patch

You discovered a bug in the engine, and you are sure that it is not a problem of your code? Just post it in here. Please read the bug posting guidelines first.
Post Reply
REDDemon
Developer
Posts: 1044
Joined: Tue Aug 31, 2010 8:06 pm
Location: Genova (Italy)

[fixed] SDL device patch

Post by REDDemon »

in the file IrrCompileConfig.h at the line 53

Code: Select all

#define _IRR_COMPILE_WITH_WINDOWS_DEVICE_
i think must be changed in :

Code: Select all

#ifndef _IRR_COMPILE_WITH_SDL_DEVICE_
	#define _IRR_COMPILE_WITH_WINDOWS_DEVICE_	
#endif

because in the COpenGLDriver.h file at line 466:

Code: Select all

		#ifdef _IRR_COMPILE_WITH_WINDOWS_DEVICE_
			CIrrDeviceWin32 *Device;
		#endif
		#endif
		#ifdef _IRR_COMPILE_WITH_X11_DEVICE_
			GLXDrawable Drawable;
			Display* X11Display;
			CIrrDeviceLinux *Device;
		#endif
		#ifdef _IRR_COMPILE_WITH_OSX_DEVICE_
			CIrrDeviceMacOSX *Device;
		#endif
		#ifdef _IRR_COMPILE_WITH_SDL_DEVICE_
			CIrrDeviceSDL *Device;
		#endif
"Device" will be defined twice.

so what it said in the IrrCompileConfig.h at line 27:

Code: Select all

//! DEVICE is the windowing system used, several PLATFORMs support more than one DEVICE
//! Irrlicht can be compiled with more than one device
is not true at all. Maybe there are similiar issues, I don't know. I just tried with SDL device. All platforms with multiple devices must be tested.


I applied this patch already in the last release of IrrSolid and worked well.

Another place in wich both SDL and window device can be defined is

in the file IrrCompileConfig.h at the line 73.
the fix is the same of above. just preventing defining both windows and SDL device is enough.

That issue i think belongs to all releases of irrlicht (i checked only 1.8 and 1.7 but probably is also in 1.6 and below.)
Junior Irrlicht Developer.
Real value in social networks is not about "increasing" number of followers, but about getting in touch with Amazing people.
- by Me
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Should be fixed in SVN/trunk now, supporting multiple devices with OpenGL.
Post Reply