-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[librptexture] KhronosKTX2.cpp: New inline helper function read_le32().
On i386/amd64, this is essentially the same code, since reading unaligned data is allowed and is usually fast. On other CPUs, reading unaligned data is either not allowed or is slow. Use byte reads and shifting instead. Effectively no change on i386/amd64, but this may help fix potential crashes on other CPUs. On ARMv5 and earlier, unaligned accesses crash. On ARMv6 and later, it probably won't crash, but it might be slow.
- Loading branch information
1 parent
021d20c
commit 03aef28
Showing
1 changed file
with
76 additions
and
58 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters