mirror of
https://github.com/a2-4am/4cade.git
synced 2024-12-19 20:32:02 +00:00
.
This commit is contained in:
parent
92d4f3f8fc
commit
a95e4a9c74
@ -1,10 +1,10 @@
|
||||
;license:MIT
|
||||
;(c) 2019 by 4am
|
||||
;
|
||||
src3 = $E8 ; word
|
||||
dest3 = $EA ; word
|
||||
src4 = $EC ; word
|
||||
dest4 = $EE ; word
|
||||
mirror_src1 = $E8 ; word
|
||||
mirror_dest1 = $EA ; word
|
||||
mirror_src2 = $EC ; word
|
||||
mirror_dest2 = $EE ; word
|
||||
src1 = $F0 ; word
|
||||
dest1 = $F2 ; word
|
||||
src2 = $F4 ; word
|
||||
@ -83,19 +83,19 @@ hgr1himirror = $BF40 ; $C0 bytes
|
||||
|
||||
!macro ROW_X_TO_MIRROR_ADDRESSES {
|
||||
lda hgrlomirror,x
|
||||
sta dest3
|
||||
sta src3
|
||||
sta mirror_dest1
|
||||
sta mirror_src1
|
||||
lda hgr1himirror,x
|
||||
sta dest3+1
|
||||
sta mirror_dest1+1
|
||||
eor #$60
|
||||
sta src3+1
|
||||
sta mirror_src1+1
|
||||
lda hgrlomirror+1,x
|
||||
sta dest4
|
||||
sta src4
|
||||
sta mirror_dest2
|
||||
sta mirror_src2
|
||||
lda hgr1himirror+1,x
|
||||
sta dest4+1
|
||||
sta mirror_dest2+1
|
||||
eor #$60
|
||||
sta src4+1
|
||||
sta mirror_src2+1
|
||||
}
|
||||
|
||||
!macro HIGH_3_LOW_5 .input {
|
||||
@ -163,14 +163,14 @@ InputLoop
|
||||
+COPY_BIT src2, dest2, mirror_copymasks
|
||||
|
||||
; corresponding 1x2 block in bottom-right quadrant (opposite row, opposite column)
|
||||
+COPY_BIT src3, dest3, mirror_copymasks
|
||||
+COPY_BIT src4, dest4, mirror_copymasks
|
||||
+COPY_BIT mirror_src1, mirror_dest1, mirror_copymasks
|
||||
+COPY_BIT mirror_src2, mirror_dest2, mirror_copymasks
|
||||
|
||||
; corresponding 1x2 block in bottom-left quadrant (opposite row, original column)
|
||||
lda mirror_cols,y
|
||||
tay
|
||||
+COPY_BIT src3, dest3, copymasks
|
||||
+COPY_BIT src4, dest4, copymasks
|
||||
+COPY_BIT mirror_src1, mirror_dest1, copymasks
|
||||
+COPY_BIT mirror_src2, mirror_dest2, copymasks
|
||||
|
||||
+INC_INPUT_AND_LOOP InputLoop
|
||||
rts
|
||||
|
@ -23,8 +23,8 @@ LoopBL ; bottom-left quadrant (opposite row, origi
|
||||
iny
|
||||
lda (input),y
|
||||
+HIGH_3_LOW_5 input
|
||||
+COPY_BIT src3, dest3, copymasks
|
||||
+COPY_BIT src4, dest4, copymasks
|
||||
+COPY_BIT mirror_src1, mirror_dest1, copymasks
|
||||
+COPY_BIT mirror_src2, mirror_dest2, copymasks
|
||||
+DEC_INPUT_AND_LOOP LoopBL
|
||||
DoneBL
|
||||
|
||||
@ -75,8 +75,8 @@ LoopBR ; bottom-right quadrant (opposite row, oppo
|
||||
+HIGH_3_LOW_5 input
|
||||
lda mirror_cols,y
|
||||
tay
|
||||
+COPY_BIT src3, dest3, mirror_copymasks
|
||||
+COPY_BIT src4, dest4, mirror_copymasks
|
||||
+COPY_BIT mirror_src1, mirror_dest1, mirror_copymasks
|
||||
+COPY_BIT mirror_src2, mirror_dest2, mirror_copymasks
|
||||
+INC_INPUT_AND_LOOP LoopBR
|
||||
DoneBR
|
||||
rts
|
||||
|
@ -34,8 +34,8 @@ Loop ldy #0
|
||||
; bottom-right quadrant (opposite row, opposite column, original input order)
|
||||
lda mirror_cols,y
|
||||
tay
|
||||
+COPY_BIT src3, dest3, mirror_copymasks
|
||||
+COPY_BIT src4, dest4, mirror_copymasks
|
||||
+COPY_BIT mirror_src1, mirror_dest1, mirror_copymasks
|
||||
+COPY_BIT mirror_src2, mirror_dest2, mirror_copymasks
|
||||
|
||||
ldy #0
|
||||
lda (reverse_input),y
|
||||
@ -47,8 +47,8 @@ Loop ldy #0
|
||||
+HIGH_3_LOW_5 reverse_input
|
||||
|
||||
; bottom-left quadrant (opposite row, original column, reverse input order)
|
||||
+COPY_BIT src3, dest3, copymasks
|
||||
+COPY_BIT src4, dest4, copymasks
|
||||
+COPY_BIT mirror_src1, mirror_dest1, copymasks
|
||||
+COPY_BIT mirror_src2, mirror_dest2, copymasks
|
||||
|
||||
; top-right quadrant (same row, opposite column, reverse input order)
|
||||
lda mirror_cols,y
|
||||
|
Loading…
Reference in New Issue
Block a user