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
|
;license:MIT
|
||||||
;(c) 2019 by 4am
|
;(c) 2019 by 4am
|
||||||
;
|
;
|
||||||
src3 = $E8 ; word
|
mirror_src1 = $E8 ; word
|
||||||
dest3 = $EA ; word
|
mirror_dest1 = $EA ; word
|
||||||
src4 = $EC ; word
|
mirror_src2 = $EC ; word
|
||||||
dest4 = $EE ; word
|
mirror_dest2 = $EE ; word
|
||||||
src1 = $F0 ; word
|
src1 = $F0 ; word
|
||||||
dest1 = $F2 ; word
|
dest1 = $F2 ; word
|
||||||
src2 = $F4 ; word
|
src2 = $F4 ; word
|
||||||
@ -83,19 +83,19 @@ hgr1himirror = $BF40 ; $C0 bytes
|
|||||||
|
|
||||||
!macro ROW_X_TO_MIRROR_ADDRESSES {
|
!macro ROW_X_TO_MIRROR_ADDRESSES {
|
||||||
lda hgrlomirror,x
|
lda hgrlomirror,x
|
||||||
sta dest3
|
sta mirror_dest1
|
||||||
sta src3
|
sta mirror_src1
|
||||||
lda hgr1himirror,x
|
lda hgr1himirror,x
|
||||||
sta dest3+1
|
sta mirror_dest1+1
|
||||||
eor #$60
|
eor #$60
|
||||||
sta src3+1
|
sta mirror_src1+1
|
||||||
lda hgrlomirror+1,x
|
lda hgrlomirror+1,x
|
||||||
sta dest4
|
sta mirror_dest2
|
||||||
sta src4
|
sta mirror_src2
|
||||||
lda hgr1himirror+1,x
|
lda hgr1himirror+1,x
|
||||||
sta dest4+1
|
sta mirror_dest2+1
|
||||||
eor #$60
|
eor #$60
|
||||||
sta src4+1
|
sta mirror_src2+1
|
||||||
}
|
}
|
||||||
|
|
||||||
!macro HIGH_3_LOW_5 .input {
|
!macro HIGH_3_LOW_5 .input {
|
||||||
@ -163,14 +163,14 @@ InputLoop
|
|||||||
+COPY_BIT src2, dest2, mirror_copymasks
|
+COPY_BIT src2, dest2, mirror_copymasks
|
||||||
|
|
||||||
; corresponding 1x2 block in bottom-right quadrant (opposite row, opposite column)
|
; corresponding 1x2 block in bottom-right quadrant (opposite row, opposite column)
|
||||||
+COPY_BIT src3, dest3, mirror_copymasks
|
+COPY_BIT mirror_src1, mirror_dest1, mirror_copymasks
|
||||||
+COPY_BIT src4, dest4, mirror_copymasks
|
+COPY_BIT mirror_src2, mirror_dest2, mirror_copymasks
|
||||||
|
|
||||||
; corresponding 1x2 block in bottom-left quadrant (opposite row, original column)
|
; corresponding 1x2 block in bottom-left quadrant (opposite row, original column)
|
||||||
lda mirror_cols,y
|
lda mirror_cols,y
|
||||||
tay
|
tay
|
||||||
+COPY_BIT src3, dest3, copymasks
|
+COPY_BIT mirror_src1, mirror_dest1, copymasks
|
||||||
+COPY_BIT src4, dest4, copymasks
|
+COPY_BIT mirror_src2, mirror_dest2, copymasks
|
||||||
|
|
||||||
+INC_INPUT_AND_LOOP InputLoop
|
+INC_INPUT_AND_LOOP InputLoop
|
||||||
rts
|
rts
|
||||||
|
@ -23,8 +23,8 @@ LoopBL ; bottom-left quadrant (opposite row, origi
|
|||||||
iny
|
iny
|
||||||
lda (input),y
|
lda (input),y
|
||||||
+HIGH_3_LOW_5 input
|
+HIGH_3_LOW_5 input
|
||||||
+COPY_BIT src3, dest3, copymasks
|
+COPY_BIT mirror_src1, mirror_dest1, copymasks
|
||||||
+COPY_BIT src4, dest4, copymasks
|
+COPY_BIT mirror_src2, mirror_dest2, copymasks
|
||||||
+DEC_INPUT_AND_LOOP LoopBL
|
+DEC_INPUT_AND_LOOP LoopBL
|
||||||
DoneBL
|
DoneBL
|
||||||
|
|
||||||
@ -75,8 +75,8 @@ LoopBR ; bottom-right quadrant (opposite row, oppo
|
|||||||
+HIGH_3_LOW_5 input
|
+HIGH_3_LOW_5 input
|
||||||
lda mirror_cols,y
|
lda mirror_cols,y
|
||||||
tay
|
tay
|
||||||
+COPY_BIT src3, dest3, mirror_copymasks
|
+COPY_BIT mirror_src1, mirror_dest1, mirror_copymasks
|
||||||
+COPY_BIT src4, dest4, mirror_copymasks
|
+COPY_BIT mirror_src2, mirror_dest2, mirror_copymasks
|
||||||
+INC_INPUT_AND_LOOP LoopBR
|
+INC_INPUT_AND_LOOP LoopBR
|
||||||
DoneBR
|
DoneBR
|
||||||
rts
|
rts
|
||||||
|
@ -34,8 +34,8 @@ Loop ldy #0
|
|||||||
; bottom-right quadrant (opposite row, opposite column, original input order)
|
; bottom-right quadrant (opposite row, opposite column, original input order)
|
||||||
lda mirror_cols,y
|
lda mirror_cols,y
|
||||||
tay
|
tay
|
||||||
+COPY_BIT src3, dest3, mirror_copymasks
|
+COPY_BIT mirror_src1, mirror_dest1, mirror_copymasks
|
||||||
+COPY_BIT src4, dest4, mirror_copymasks
|
+COPY_BIT mirror_src2, mirror_dest2, mirror_copymasks
|
||||||
|
|
||||||
ldy #0
|
ldy #0
|
||||||
lda (reverse_input),y
|
lda (reverse_input),y
|
||||||
@ -47,8 +47,8 @@ Loop ldy #0
|
|||||||
+HIGH_3_LOW_5 reverse_input
|
+HIGH_3_LOW_5 reverse_input
|
||||||
|
|
||||||
; bottom-left quadrant (opposite row, original column, reverse input order)
|
; bottom-left quadrant (opposite row, original column, reverse input order)
|
||||||
+COPY_BIT src3, dest3, copymasks
|
+COPY_BIT mirror_src1, mirror_dest1, copymasks
|
||||||
+COPY_BIT src4, dest4, copymasks
|
+COPY_BIT mirror_src2, mirror_dest2, copymasks
|
||||||
|
|
||||||
; top-right quadrant (same row, opposite column, reverse input order)
|
; top-right quadrant (same row, opposite column, reverse input order)
|
||||||
lda mirror_cols,y
|
lda mirror_cols,y
|
||||||
|
Loading…
Reference in New Issue
Block a user