From a8872b4e661bb95b4c32b413800c68052c235edf Mon Sep 17 00:00:00 2001 From: Brion Vibber Date: Sun, 22 Jan 2023 08:34:06 -0800 Subject: [PATCH] hmm --- mandel.s | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/mandel.s b/mandel.s index c6d3cf7..5cf1e9a 100644 --- a/mandel.s +++ b/mandel.s @@ -567,10 +567,10 @@ point: shl16 temp shl16 temp shl16 temp - add16 pixel_ptr, temp, temp + add16 pixel_ptr, pixel_ptr, temp shl16 temp shl16 temp - add16 pixel_ptr, temp, temp + add16 pixel_ptr, pixel_ptr, temp ; Ok so temp1 points to the start of the line, which is 40 bytes. ; Get the byte and bit offsets @@ -605,6 +605,7 @@ shift_done: lda (temp),y and pixel_mask ora pixel_color + lda #255 sta (temp),y rts @@ -701,7 +702,9 @@ loop_sy: loop_sx: zoom_factor cx, sx, zoom, aspect_x zoom_factor cy, sy, zoom, aspect_y - jsr mandelbrot + ;jsr mandelbrot + lda #1 + sta iter jsr pset @@ -709,13 +712,13 @@ loop_sx: clc adc #1 sta sx - - cmp #half_width - beq loop_sx_done - lda sx + 1 adc #0 sta sx + 1 + + lda sx + cmp #half_width + beq loop_sx_done jmp loop_sx loop_sx_done: @@ -724,13 +727,13 @@ loop_sx_done: clc adc #1 sta sy - - cmp #half_height - beq loop_sy_done - lda sy + 1 adc #0 sta sy + 1 + + lda sy + cmp #half_height + beq loop_sy_done jmp loop_sy loop_sy_done: