Is BURNINGVIDEO bigendian aware?

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.

Re: Is BURNINGVIDEO bigendian aware?

Postby CuteAlien » Mon Feb 12, 2018 9:25 pm

The fix for big endian is removing the #ifdef __BIG_ENDIAN__ parts? That's somewhat unexpected :-)
But thanks @Hendu! I'm just not sure right now if I should add that to 1.8 (always slight risk) or to trunk. Which version are you working with kas1e? Thought I suppose there probably was really no-one else using it with big endian maybe.
IRC: #irrlicht on irc.freenode.net
Code snippets, patches&stuff: http://www.michaelzeilfelder.de/irrlicht.htm
Free racer created with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
User avatar
CuteAlien
Admin
 
Posts: 8440
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany

Re: Is BURNINGVIDEO bigendian aware?

Postby devsh » Tue Feb 13, 2018 11:16 am

My 2 cents.

Endian conversion is only needed when you input or output data from a asystem of other endianness (hence why you need to check for it and swap bytes when reading files).
I guess that Burnings video does not care about endianness and Alpha is always in the logically higher 24bits for ARGB, now whether thats in the lower byte or higher after casting to uint8_t depends only on endianness.
Now if the driver only operates on 32bit values and uses bitmasks to extract components then no endian flags are needed, which is why I guess the fix of removing the BIG_ENDIAN ifdefs worked.

But now beware, OpenGL, GL ES, will not work with big-endian systems without byteswapping uploaded data such as vertex buffers.
User avatar
devsh
Competition winner
 
Posts: 1824
Joined: Tue Dec 09, 2008 6:00 pm
Location: UK

Re: Is BURNINGVIDEO bigendian aware?

Postby kas1e » Tue Feb 13, 2018 1:35 pm

@CuteAlien
I do tests over 1.8.4 version, but probably will works with ogles one as well, as its all the same in that terms. That part from Software_helper.h as hendu says was only about colors, so its all fine then.

Through i dunno where to see now about that other error with the floor in the example "special fx", it seems like "almost" right, but still not fully.

On win32_x86:

http://kas1e.mikendezign.com/aos4/irrli ... 32_x86.jpg

On amigaos_ppc:

http://kas1e.mikendezign.com/aos4/irrli ... os_PPC.jpg
http://kas1e.mikendezign.com/aos4/irrli ... _PPC_2.jpg

Like somethig simple .. just where to look at...
kas1e
 
Posts: 28
Joined: Sun Jan 21, 2018 8:39 am

Re: Is BURNINGVIDEO bigendian aware?

Postby CuteAlien » Tue Feb 13, 2018 2:40 pm

@devsh: The changed functions should only be used by burnings renderer. The endian define is still used in many other places which are not affected by this patch.

@kas1e: Links in your last post don't work, but I suppose the same as earlier? Not sure what's going on, but doesn't seem to be wrong colors, so that patch still looks fine. I'll apply the patch to Irrlicht trunk (and ogl-es when I merge). Won't add it to 1.8 for now in case it breaks some platform I don't know about (released branches shouldn't really change behavior except for bugfixing... so this one is slightly tricky as it changes behavior but probably only fixes bugs...).
IRC: #irrlicht on irc.freenode.net
Code snippets, patches&stuff: http://www.michaelzeilfelder.de/irrlicht.htm
Free racer created with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
User avatar
CuteAlien
Admin
 
Posts: 8440
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany

Previous

Return to Bug reports

Who is online

Users browsing this forum: No registered users and 1 guest