Difference between revisions of "SYS MoveImage"
Jump to navigation
Jump to search
m |
m |
||
(One intermediate revision by the same user not shown) | |||
Line 1: | Line 1: | ||
# ROUTINE: ? 0x249c4 | # ROUTINE: ? 0x249c4 | ||
# Parameters: | # Parameters: | ||
− | # r4 = | + | # r4 = RECT recp* source image rectangle |
− | # r5 = | + | # r5 = int x destination top left x |
− | # r6 = | + | # r6 = int y destination top left y |
800249c4: 27bdffe0 addiu r29,r29,-0x0020 | 800249c4: 27bdffe0 addiu r29,r29,-0x0020 | ||
Line 31: | Line 31: | ||
# } else { | # } else { | ||
80024a1c: 3243ffff andi r3,r18,0xffff # p2 | 80024a1c: 3243ffff andi r3,r18,0xffff # p2 | ||
− | 80024a20: 00431025 or r2,r2,r3 # ( | + | 80024a20: 00431025 or r2,r2,r3 # (y << 0x10) | (x) |
80024a24: 3c058003 lui r5,0x8003 | 80024a24: 3c058003 lui r5,0x8003 | ||
80024a28: 24a52944 addiu r5,r5,0x2944 # 0x80032944 | 80024a28: 24a52944 addiu r5,r5,0x2944 # 0x80032944 | ||
Line 39: | Line 39: | ||
80024a38: 34060014 ori r6,r0,0x0014 # 20 | 80024a38: 34060014 ori r6,r0,0x0014 # 20 | ||
80024a3c: 3c018003 lui r1,0x8003 | 80024a3c: 3c018003 lui r1,0x8003 | ||
− | 80024a40: ac222948 sw r2,0x2948(r1) # *0x80032948 = ( | + | 80024a40: ac222948 sw r2,0x2948(r1) # *0x80032948 = (y << 0x10) | (x) |
− | 80024a44: aca40000 sw r4,0x0000(r5) # *0x80032944 = | + | 80024a44: aca40000 sw r4,0x0000(r5) # *0x80032944 = TpageID |
80024a48: 8e020004 lw r2,0x0004(r16) # *(p1 + 4) //(0x40 & 0x20 flags) | 80024a48: 8e020004 lw r2,0x0004(r16) # *(p1 + 4) //(0x40 & 0x20 flags) | ||
80024a4c: 00003821 addu r7,r0,r0 # 0 | 80024a4c: 00003821 addu r7,r0,r0 # 0 |
Latest revision as of 05:49, 8 August 2023
# ROUTINE: ? 0x249c4 # Parameters: # r4 = RECT recp* source image rectangle # r5 = int x destination top left x # r6 = int y destination top left y 800249c4: 27bdffe0 addiu r29,r29,-0x0020 800249c8: afb00010 sw r16,0x0010(r29) 800249cc: 00808021 addu r16,r4,r0 # sp1 800249d0: afb20018 sw r18,0x0018(r29) 800249d4: 00a09021 addu r18,r5,r0 # p2 800249d8: afb10014 sw r17,0x0014(r29) 800249dc: 00c08821 addu r17,r6,r0 # p3 800249e0: 3c048001 lui r4,0x8001 800249e4: 24840810 addiu r4,r4,0x0810 # 0x80010810 800249e8: afbf001c sw r31,0x001c(r29) 800249ec: 0c0091d0 jal 0x80024740 # ? 0x24740 (0x80010810, sp1); 800249f0: 02002821 addu r5,r16,r0 # 800249f4: 86020004 lh r2,0x0004(r16) # *sp1 + 4 //(0x40 flag) 800249f8: 00000000 nop 800249fc: 1040001b beq r2,r0,0x80024a6c 80024a00: 2402ffff addiu r2,r0,-0x0001 # -1 # if (*(sp1 + 4) != 0) { 80024a04: 86020006 lh r2,0x0006(r16) # *(sp1 + 6) //(0x20 flag) 80024a08: 00000000 nop 80024a0c: 14400003 bne r2,r0,0x80024a1c 80024a10: 00111400 sll r2,r17,0x10 # p3 << 16 # if (*(sp1 + 6) == 0) { 80024a14: 0800929b j 0x80024a6c 80024a18: 2402ffff addiu r2,r0,-0x0001 # return -1; # } else { 80024a1c: 3243ffff andi r3,r18,0xffff # p2 80024a20: 00431025 or r2,r2,r3 # (y << 0x10) | (x) 80024a24: 3c058003 lui r5,0x8003 80024a28: 24a52944 addiu r5,r5,0x2944 # 0x80032944 80024a2c: 8e040000 lw r4,0x0000(r16) # *sp1 (manipulated VRAM slot IDs) 80024a30: 3c038003 lui r3,0x8003 80024a34: 8c63288c lw r3,0x288c(r3) # *0x8003288c 80024a38: 34060014 ori r6,r0,0x0014 # 20 80024a3c: 3c018003 lui r1,0x8003 80024a40: ac222948 sw r2,0x2948(r1) # *0x80032948 = (y << 0x10) | (x) 80024a44: aca40000 sw r4,0x0000(r5) # *0x80032944 = TpageID 80024a48: 8e020004 lw r2,0x0004(r16) # *(p1 + 4) //(0x40 & 0x20 flags) 80024a4c: 00003821 addu r7,r0,r0 # 0 80024a50: 3c018003 lui r1,0x8003 80024a54: ac22294c sw r2,0x294c(r1) # *0x8003294c = *(p1 + 4) 80024a58: 8c640018 lw r4,0x0018(r3) # *(*0x8003288c + 24) 80024a5c: 8c620008 lw r2,0x0008(r3) # funcPtr = *(*0x8003288c + 8) 80024a60: 00000000 nop 80024a64: 0040f809 jalr r2,r31 # result = funcPtr (*(*0x8003288c + 24), 0x8003293c, 20, 0); // Invoke function with these parameters 80024a68: 24a5fff8 addiu r5,r5,-0x0008 # 0x8003293c # } # } 80024a6c: 8fbf001c lw r31,0x001c(r29) # return result; 80024a70: 8fb20018 lw r18,0x0018(r29) 80024a74: 8fb10014 lw r17,0x0014(r29) 80024a78: 8fb00010 lw r16,0x0010(r29) 80024a7c: 27bd0020 addiu r29,r29,0x0020 80024a80: 03e00008 jr r31 80024a84: 00000000 nop