-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix rtext default font alpha on Big Endian #4624
base: master
Are you sure you want to change the base?
Conversation
@Fancy2209 It seems this patch addresses a specific use case for a specific hardware arquitecture... won't endianness affect other parts of raylib library? 🤔 |
Big endian is uncommon, but worth supporting. This will break all big endian systems, like powerpc linux, and sparc linux. Not that they are common, but it still matters to some users. |
You mean this issue affects them too or that this PR breaks them? |
I mean the issue affects them. I think sparc and powerpc are the most relevant BE systems |
@Fancy2209 @Peter0x44 what is the cost of supporting big endian in raylib? It can require many changes and additional code complexity for a very specific set of platforms... if it implies only a couple of checks, it can be considered... |
I have to test all examples and find issues so it might take a bit |
@Fancy2209 ok, nice! 👍😄 |
It implies no extra complexity, just a few minor edge cases need some extra care and attention ((unsigned char *)imFont.data)[(i + j)*sizeof(short)] = 0xFF
((unsigned char *)imFont.data)[(i + j)*sizeof(short) + 1] = 0x00; |
Done, I still have to test loading Data from files though |
Alpha was broken for rtext's default font on Big Endian
Before
After