add an alternate viewport (compile-time currently)
zoomed to max
This commit is contained in:
parent
0fc5ba914f
commit
2118890977
1 changed files with 31 additions and 9 deletions
40
mandel.s
40
mandel.s
|
@ -246,6 +246,18 @@ fill_masks:
|
|||
.byte %00000001
|
||||
.byte %00000000
|
||||
|
||||
viewport_zoom:
|
||||
.byte 1
|
||||
.byte 8
|
||||
|
||||
viewport_ox:
|
||||
.word $0000
|
||||
.word $f110
|
||||
|
||||
viewport_oy:
|
||||
.word $0000
|
||||
.word $fbe0
|
||||
|
||||
; 2 + 9 * byte cycles
|
||||
.macro add bytes, dest, arg1, arg2
|
||||
clc ; 2 cyc
|
||||
|
@ -1213,13 +1225,27 @@ zero_byte_loop:
|
|||
|
||||
jsr imul8xe_init
|
||||
|
||||
; ox = 0; oy = 0
|
||||
; initialize viewport
|
||||
;ldx #0 ; overview
|
||||
ldx #1 ; closeup
|
||||
lda viewport_zoom,x
|
||||
sta zoom
|
||||
|
||||
txa
|
||||
asl a
|
||||
tax
|
||||
lda viewport_ox,x
|
||||
sta ox
|
||||
lda viewport_oy,x
|
||||
sta oy
|
||||
inx
|
||||
lda viewport_ox,x
|
||||
sta ox + 1
|
||||
lda viewport_oy,x
|
||||
sta oy + 1
|
||||
|
||||
; count_frames = 0; count_pixels = 0
|
||||
lda #0
|
||||
sta ox
|
||||
sta ox + 1
|
||||
sta oy
|
||||
sta oy + 1
|
||||
sta count_frames
|
||||
sta count_pixels
|
||||
|
||||
|
@ -1229,10 +1255,6 @@ zero_byte_loop:
|
|||
ldx #total_pixels
|
||||
jsr ZF1
|
||||
|
||||
; zoom = 2x
|
||||
lda #1
|
||||
sta zoom
|
||||
|
||||
; Disable display DMA
|
||||
lda #0
|
||||
sta DMACTL
|
||||
|
|
Loading…
Reference in a new issue