Should hopefully fix PSP
[picodrive.git] / pico / draw_amips.s
index 29aa7db..0fa729e 100644 (file)
@@ -1,8 +1,12 @@
-# vim:filetype=mips
-
-# several drawing related functions for Allegrex MIPS
-# (c) Copyright 2007, Grazvydas "notaz" Ignotas
-# All Rights Reserved
+#*
+#* several drawing related functions for Allegrex MIPS
+#* (C) notaz, 2007-2008
+#*
+#* This work is licensed under the terms of MAME license.
+#* See COPYING file in the top-level directory.
+#*
+#* this is highly specialized, be careful if changing related C code!
+#*
 
 .set noreorder # don't reorder any instructions
 .set noat      # don't use $at
@@ -113,11 +117,11 @@ amips_clut_loop6:
 .macro TileEndCode
     xori    $t8, $t9, 0xff
     beqz    $t8, tile11111111            # common case
-    lui     $v1, %hi(HighCol)
+    lui     $v1, %hi(HighColBase)
     lui     $t8, %hi(TileTable)
     ins     $t8, $t9, 2, 8
     lw      $t8, %lo(TileTable)($t8)
-    lw      $v1, %lo(HighCol)($v1)
+    lw      $v1, %lo(HighColBase)($v1)
     jr      $t8
     addu    $a0, $v1
 .endm
@@ -154,8 +158,8 @@ TileFlip:
 
 
 SingleColor:
-    lui     $t9, %hi(HighCol)
-    lw      $t9, %lo(HighCol)($t9)
+    lui     $t9, %hi(HighColBase)
+    lw      $t9, %lo(HighColBase)($t9)
     andi    $t0, $a1, 0xf
     or      $t0, $t0, $a2
     addu    $a0, $t9
@@ -174,7 +178,7 @@ TileEmpty:
     or      $v0, $0, 1                   # empty tile
 
 tile11111111:
-    lw      $v1, %lo(HighCol)($v1)
+    lw      $v1, %lo(HighColBase)($v1)
     or      $t0, $t0, $a2
     addu    $a0, $v1
     sb      $t0, 0($a0)
@@ -1749,4 +1753,4 @@ TileTable:
   .long tile11110000, tile11110001, tile11110010, tile11110011, tile11110100, tile11110101, tile11110110, tile11110111
   .long tile11111000, tile11111001, tile11111010, tile11111011, tile11111100, tile11111101, tile11111110, tile11111111
 
-
+# vim:filetype=mips