MyGUI / mygui

Fast, flexible and simple GUI.
http://mygui.info/
Other
713 stars 205 forks source link

bad default vertex colour order #235

Closed paroj closed 2 years ago

paroj commented 2 years ago

toColourARGB packs colours as ARGB - however only the D3D9 backend supports that. On all other backends (including D3D9 on Ogre), it immediately needs to be re-packed as ABGR - which should be used in the first place.

Altren commented 2 years ago

Agree, that this should be changed, also should be refactored from

        uint32 colour = texture_utility::toColourARGB(_value);
        texture_utility::convertColour(colour, mVertexFormat);

to

uint32 colour = texture_utility::toPackedColour(_value, mVertexFormat)

because toColourARGB is never used without convertColour.

This is very minor issue, though since this function is called only when widget color is set explicitly, thus very rare.