mirror of
https://github.com/deater/dos33fsprogs.git
synced 2024-06-24 12:29:29 +00:00
demo: outline: more progress
This commit is contained in:
parent
9962c261ed
commit
8cee9a1994
|
@ -54,7 +54,7 @@ OUTLINE: outline.o
|
|||
|
||||
outline.o: outline.s zp.inc \
|
||||
shimmer.s a2_inside.s drops.s wires.s \
|
||||
rotoplasma_tiny.s \
|
||||
rotoplasma_tiny.s rocket_away.s \
|
||||
flying_dir.inc tfv_flying.s flying_mode7.s credits.s
|
||||
ca65 -o outline.o outline.s -l outline.lst
|
||||
|
||||
|
|
|
@ -13,37 +13,6 @@
|
|||
; then flip buffers
|
||||
|
||||
|
||||
.if 0
|
||||
|
||||
|
||||
; zero page
|
||||
|
||||
GBASH = $27
|
||||
MASK = $2E
|
||||
COLOR = $30
|
||||
SEEDL = $4E
|
||||
|
||||
FRAME = $F8
|
||||
XX = $F9
|
||||
DROPL = $FA
|
||||
DROPH = $FB
|
||||
BUF1L = $FC
|
||||
BUF1H = $FD
|
||||
BUF2L = $FE
|
||||
BUF2H = $FF
|
||||
|
||||
; soft switches
|
||||
FULLGR = $C052
|
||||
LORES = $C056 ; Enable LORES graphics
|
||||
|
||||
|
||||
; ROM routines
|
||||
HGR = $F3E2
|
||||
HGR2 = $F3D8
|
||||
PLOT = $F800 ;; PLOT AT Y,A
|
||||
PLOT1 = $F80E ;; PLOT at (GBASL),Y (need MASK to be $0f or $f0)
|
||||
|
||||
.endif
|
||||
|
||||
;================================
|
||||
; Clear screen and setup graphics
|
||||
|
@ -53,6 +22,8 @@ drops:
|
|||
; A is $00 after this
|
||||
; Y is $00
|
||||
|
||||
sta FRAME
|
||||
|
||||
bit FULLGR ; full page
|
||||
bit LORES ; switch to LORES
|
||||
|
||||
|
@ -193,7 +164,15 @@ no_oflo:
|
|||
|
||||
weird_outer:
|
||||
|
||||
bmi drops_outer ; small enough now!
|
||||
; bmi drops_outer ; small enough now!
|
||||
|
||||
lda FRAME
|
||||
cmp #64
|
||||
beq drops_done
|
||||
jmp drops_outer
|
||||
drops_done:
|
||||
rts
|
||||
|
||||
|
||||
colors:
|
||||
.byte $22,$66,$77,$ff
|
||||
|
|
29
demos/outline2021/demo/graphics/Makefile
Normal file
29
demos/outline2021/demo/graphics/Makefile
Normal file
|
@ -0,0 +1,29 @@
|
|||
|
||||
PNG2RLE = ../../../../utils/gr-utils/png2rle
|
||||
PNG2GR = ../../../../utils/gr-utils/png2gr
|
||||
PNG2HGR = ../../../../utils/hgr-utils/png2hgr
|
||||
LZSA = ~/research/lzsa/lzsa/lzsa
|
||||
B2D = ../../../../utils/bmp2dhr/b2d
|
||||
|
||||
all: outline.inc
|
||||
|
||||
|
||||
outline.inc: \
|
||||
outline_space.lzsa
|
||||
echo "outline_space_lzsa: .incbin \"outline_space.lzsa\"" > outline.inc
|
||||
|
||||
|
||||
###
|
||||
|
||||
outline_space.lzsa: outline_space.hgr
|
||||
$(LZSA) -r -f2 outline_space.hgr outline_space.lzsa
|
||||
|
||||
outline_space.hgr: outline_space.png
|
||||
$(PNG2HGR) outline_space.png > outline_space.hgr
|
||||
|
||||
###
|
||||
|
||||
|
||||
clean:
|
||||
rm -f *~ outline.inc *.lzsa *.gr *.hgr
|
||||
|
BIN
demos/outline2021/demo/graphics/outline_space.png
Normal file
BIN
demos/outline2021/demo/graphics/outline_space.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 13 KiB |
44
demos/outline2021/demo/graphics/pixel_shifter.c
Normal file
44
demos/outline2021/demo/graphics/pixel_shifter.c
Normal file
|
@ -0,0 +1,44 @@
|
|||
#include <stdio.h>
|
||||
|
||||
unsigned char pixels[12][8]=
|
||||
{
|
||||
{ 0x00,0x00,0x00,0x00,0xAA,0x81,0x00,0x00 },
|
||||
{ 0x00,0x00,0x00,0xC0,0x8A,0x00,0x00,0x00 },
|
||||
{ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 },
|
||||
{ 0xA0,0xC5,0xAA,0xD5,0x8A,0x00,0x00,0x00 },
|
||||
{ 0x88,0xD5,0xAA,0x95,0xAA,0x55,0x2A,0x00 },
|
||||
{ 0xAA,0xD1,0x80,0xD5,0xAA,0xD5,0xAA,0x00 },
|
||||
{ 0xAA,0xD5,0xAA,0xD5,0xAA,0x55,0x2A,0x00 },
|
||||
{ 0xA8,0xD1,0x88,0x95,0xAA,0x00,0x00,0x00 },
|
||||
{ 0xA0,0xC5,0xAA,0xD5,0x8A,0x00,0x00,0x00 },
|
||||
{ 0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00 },
|
||||
{ 0x00,0x00,0x00,0xC0,0x8A,0x00,0x00,0x00 },
|
||||
{ 0x00,0x00,0x00,0x00,0xAA,0x81,0x00,0x00 },
|
||||
};
|
||||
|
||||
int main(int argc, char **argv) {
|
||||
|
||||
int x,y;
|
||||
int temp,next,high,nextnext;
|
||||
|
||||
for(y=0;y<12;y++) {
|
||||
printf(".byte ");
|
||||
nextnext=0;
|
||||
for(x=0;x<8;x++) {
|
||||
temp=pixels[y][x];
|
||||
high=temp&0x80;
|
||||
next=!!(temp&0x40);
|
||||
temp=temp<<1;
|
||||
temp=temp&0x7f;
|
||||
temp|=high;
|
||||
temp|=nextnext;
|
||||
nextnext=next;
|
||||
printf("$%02X,",temp);
|
||||
}
|
||||
printf("\n");
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
21
demos/outline2021/demo/hgr_pageflip.s
Normal file
21
demos/outline2021/demo/hgr_pageflip.s
Normal file
|
@ -0,0 +1,21 @@
|
|||
;==============
|
||||
; hgr_page_flip
|
||||
;==============
|
||||
|
||||
hgr_page_flip:
|
||||
lda DISP_PAGE ;
|
||||
beq hgr_page_flip_show_1 ;
|
||||
hgr_page_flip_show_0:
|
||||
bit PAGE0 ;
|
||||
lda #$40 ;
|
||||
sta HGR_PAGE ; HGR_PAGE=$40 ;
|
||||
lda #0 ;
|
||||
sta DISP_PAGE ; DISP_PAGE=0 ;
|
||||
rts ;
|
||||
hgr_page_flip_show_1:
|
||||
bit PAGE1 ;
|
||||
lda #$20
|
||||
sta HGR_PAGE ; DRAW_PAGE=$20 ;
|
||||
lda #1 ;
|
||||
sta DISP_PAGE ; DISP_PAGE=1 ;
|
||||
rts ;
|
|
@ -63,6 +63,8 @@ mockingboard_not_found:
|
|||
;=============================
|
||||
|
||||
|
||||
jsr rocket_away
|
||||
|
||||
jsr a2_inside
|
||||
|
||||
jsr wires
|
||||
|
@ -114,6 +116,11 @@ forever:
|
|||
.include "long_wait.s"
|
||||
.include "random16.s"
|
||||
|
||||
.include "decompress_fast_v2.s"
|
||||
.include "rocket_away.s"
|
||||
.include "graphics/outline.inc"
|
||||
.include "hgr_pageflip.s"
|
||||
|
||||
PT3_LOC = song
|
||||
.align $100
|
||||
song:
|
||||
|
|
|
@ -10,7 +10,7 @@ COUNT = $06
|
|||
MENU_BASE = $06
|
||||
MENU_HIGHLIGHT = $07
|
||||
DELTA = $08
|
||||
|
||||
NIBCOUNT = $09
|
||||
|
||||
; Zero page monitor routines addresses
|
||||
|
||||
|
@ -112,6 +112,7 @@ SCALE_F = $AD
|
|||
|
||||
SHIPY = $E4 ; mode7
|
||||
|
||||
HGR_PAGE = $E6
|
||||
HGR_SCALE = $E7
|
||||
|
||||
DISP_PAGE = $ED
|
||||
|
|
Loading…
Reference in New Issue
Block a user