DHGR transform Iris to Ripple

This commit is contained in:
Peter Ferrie 2020-11-17 23:32:34 -08:00
parent 1064e55dae
commit 26338f9a4e
4 changed files with 104 additions and 3850 deletions

View File

@ -1,5 +1,5 @@
;license:MIT ;license:MIT
;(c) 2018-9 by 4am ;(c) 2018-2020 by 4am/qkumba
; ;
coord = $FE coord = $FE
CoordinatesDHGR = $A000 ; $1E01 bytes ($1E00 on disk + 1 byte EOF marker) CoordinatesDHGR = $A000 ; $1E01 bytes ($1E00 on disk + 1 byte EOF marker)
@ -25,6 +25,101 @@ InitOnce
+READ_RAM1_WRITE_RAM1 +READ_RAM1_WRITE_RAM1
} }
!macro FX_RIPPLE_DHGR {
ldx #$0f
- lda ptrtbl, x
sta $c0, x
dex
bpl -
lda #$66
sta $fe
ldx #3
stx $ff
- lda CoordinatesDHGR + 2, x
sta $80, x
dex
bpl -
dex
- lda CoordinatesDHGR + 22 - 254, x
sta $86, x
lda CoordinatesDHGR + 34 - 254, x
sta $88, x
lda CoordinatesDHGR + 44 - 254, x
sta $8a, x
lda CoordinatesDHGR + 68 - 254, x
sta $8c, x
lda CoordinatesDHGR + 698 - 254, x
sta $8e, x
lda CoordinatesDHGR + 1396 - 254, x
sta $90, x
inx
bne -
--- ldx #$10
-- lda $bf, x
bmi +
ldy $be, x
jsr aslmod2
sty $be, x
sta $bf, x
sty $fc
clc
adc #>CoordinatesDHGR
sta $fd
ldy #0
!byte $a9
- sec
lda ($fc), y
pha
lda $7e, x
sta ($fc), y
pla
sta $7e, x
inx
iny
bcc -
dex
dex
+ dex
dex
bne --
dex
lda $fe
eor #<(871 - 5)
bne +
stx $cd
stx $cf
+ eor #<(871 - 5) xor <(871 - 174)
bne +
lda $ff
eor #>(871 - 174)
bne +
stx $c5
stx $c9
+ dec $fe
bne ---
dec $ff
bpl ---
bmi ++ ; always branches
aslmod2 jsr aslmod
aslmod cmp #$0F
pha
tya
adc #0
asl
tay
pla
rol
cmp #$1E
bcc +
sbc #$1E
+ rts
ptrtbl !word 2, 4, 22, 34, 44, 68, 698, 1396
++
}
!macro FX_RADIAL2_DHGR .coords { !macro FX_RADIAL2_DHGR .coords {
ldx #$0d ldx #$0d
- lda ptrtbl, x - lda ptrtbl, x

View File

@ -8,8 +8,9 @@
!source "src/fx/fx.dhgr.precomputed.a" !source "src/fx/fx.dhgr.precomputed.a"
+FX_INITONCE_DHGR CoordinatesFile, PostInit +FX_INITONCE_DHGR CoordinatesFile, PostInit
lda #$80 sec
sta EndCoordinatesDHGR ror EndCoordinatesDHGR
+FX_RIPPLE_DHGR
+COPY_SELF_TO_AUXMEM +COPY_SELF_TO_AUXMEM
PostInit PostInit
+FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1 +FX_PRECOMPUTED_DHGR HGRHalfBlockCopy, Coordinates, $1
@ -19,4 +20,4 @@ PostInit
Coordinates=CoordinatesDHGR Coordinates=CoordinatesDHGR
CoordinatesFile CoordinatesFile
!byte 17 !byte 17
!text "FX/DHGR.RIPP.DATA" !text "FX/DHGR.IRIS.DATA"

File diff suppressed because it is too large Load Diff

View File

@ -8,8 +8,9 @@
!source "src/fx/fx.dhgr.precomputed.a" !source "src/fx/fx.dhgr.precomputed.a"
+FX_INITONCE_DHGR CoordinatesFile, PostInit +FX_INITONCE_DHGR CoordinatesFile, PostInit
lda #$80 sec
sta EndCoordinatesDHGR ror EndCoordinatesDHGR
+FX_RIPPLE_DHGR
+COPY_SELF_TO_AUXMEM +COPY_SELF_TO_AUXMEM
PostInit PostInit
+FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0 +FX_PRECOMPUTED_DHGR HGRHalfBlockToWhite, Coordinates, $0
@ -20,4 +21,4 @@ PostInit
Coordinates=CoordinatesDHGR Coordinates=CoordinatesDHGR
CoordinatesFile CoordinatesFile
!byte 17 !byte 17
!text "FX/DHGR.RIPP.DATA" !text "FX/DHGR.IRIS.DATA"