mirror of
https://github.com/zeldaret/oot.git
synced 2025-07-06 16:04:35 +00:00
Use intptr in most remaining code files (#1438)
* Use intptr in most remaining code files * Fix missing uintptr_t in actor * Use u8* casts for texture pointer arithmetic * Use bg + 1 instead of casting in Room_DrawBackground2D
This commit is contained in:
parent
d307a37233
commit
232fdb75d8
15 changed files with 74 additions and 67 deletions
|
@ -102,7 +102,7 @@ void Jpeg_CopyToZbuffer(u16* src, u16* zbuffer, s32 x, s32 y) {
|
|||
* unaligned values in JPEG header files.
|
||||
*/
|
||||
u16 Jpeg_GetUnalignedU16(u8* ptr) {
|
||||
if (((u32)ptr & 1) == 0) {
|
||||
if (((uintptr_t)ptr & 1) == 0) {
|
||||
// Read the value normally if it's aligned to a 16-bit address.
|
||||
return *(u16*)ptr;
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue