present updates
This commit is contained in:
parent
86aa76b8c5
commit
197f2854d0
45
asm/blit.s
45
asm/blit.s
|
@ -185,7 +185,7 @@ dp ds 2
|
|||
|
||||
|
||||
*
|
||||
* void DrawRect(short x, short y, short width, short height)
|
||||
* void BlitRect(short x, short y, short width, short height)
|
||||
*
|
||||
|
||||
BlitRect start BLITCODE
|
||||
|
@ -221,6 +221,7 @@ stackFix equ 9
|
|||
lsr a
|
||||
lsr a
|
||||
sta inputW,s
|
||||
sta loopW
|
||||
|
||||
clc
|
||||
lda inputY,s
|
||||
|
@ -231,28 +232,43 @@ stackFix equ 9
|
|||
lsr a
|
||||
lsr a
|
||||
sta inputH,s
|
||||
sta loopH
|
||||
|
||||
lda inputY,s
|
||||
and #~3
|
||||
lsr a
|
||||
lsr a
|
||||
sta inputY,s
|
||||
sta loopY
|
||||
tay
|
||||
|
||||
lda inputX,s
|
||||
and #~3
|
||||
tax
|
||||
sta inputX,s ; maybe don't need this
|
||||
sta loopX
|
||||
|
||||
*---------------------------------------
|
||||
sei
|
||||
_shadowON
|
||||
_auxON
|
||||
*---------------------------------------
|
||||
|
||||
*
|
||||
* We're messing with the stack, and the DP
|
||||
* so operationally, we can't use these things
|
||||
* for variables, or for call returns
|
||||
*
|
||||
|
||||
*
|
||||
* Outter loop, once for each Y
|
||||
*
|
||||
YLOOP ANOP
|
||||
|
||||
lda inputX,s
|
||||
lda loopX
|
||||
sta tempX
|
||||
|
||||
lda inputW,s
|
||||
lda loopW
|
||||
sta tempW
|
||||
|
||||
XLOOP ANOP ; Inner Loop, for each X Block
|
||||
|
@ -279,13 +295,14 @@ BRET anop ; Blit Return
|
|||
lda tempW
|
||||
bne XLOOP
|
||||
|
||||
lda inputH,s
|
||||
dec a
|
||||
dec loopH
|
||||
bmi done
|
||||
sta inputH,s
|
||||
|
||||
iny ; next direct page
|
||||
iny
|
||||
iny
|
||||
|
||||
* TODO, every 4 lines or so (or every so many clocks)
|
||||
* re-enable interrupts, for audio, and the heartbeat
|
||||
|
||||
bra YLOOP
|
||||
|
||||
|
@ -299,6 +316,13 @@ done ANOP
|
|||
lda stack
|
||||
tcs
|
||||
|
||||
*---------------------------------------
|
||||
_auxOFF
|
||||
_shadowOFF
|
||||
cli
|
||||
*---------------------------------------
|
||||
|
||||
|
||||
* Patchup the Stack so we can return
|
||||
|
||||
lda 3,s
|
||||
|
@ -310,7 +334,12 @@ done ANOP
|
|||
rtl
|
||||
*-------------------------------------------------------------------------------
|
||||
tempX ds 2 ; inner X
|
||||
tempW ds 2 ; inner W
|
||||
tempW ds 2 ; inner W
|
||||
* Local bank copies of our stack variables
|
||||
loopX ds 2
|
||||
loopY ds 2
|
||||
loopW ds 2
|
||||
loopH ds 2
|
||||
stack ds 2 ; stack register
|
||||
dp ds 2 ; dp register
|
||||
|
||||
|
|
|
@ -174,6 +174,9 @@ extern void sysjoy_shutdown(void);
|
|||
#endif
|
||||
|
||||
#ifdef IIGS
|
||||
// GS Hardware Registers
|
||||
extern volatile char *VIDEO_REGISTER;
|
||||
|
||||
// GS Specific Stuff
|
||||
extern int LZ4_Unpack(char* pDest, char* pPackedSource);
|
||||
extern volatile unsigned long* tick;
|
||||
|
@ -184,6 +187,12 @@ extern void DrawTile(int offset, int tileNo);
|
|||
extern void SetSpriteBanks(short b0, short b1, short b2, short b3);
|
||||
extern void DrawSprite(int offset, int SpriteNo);
|
||||
|
||||
// Code for presenting backpage
|
||||
extern void PresentPalette(void);
|
||||
extern void PresentSCB(void);
|
||||
extern void PresentFrameBuffer(void);
|
||||
extern void BlitRect(short x, short y, short width, short height);
|
||||
|
||||
// ADB Support Code
|
||||
extern char KeyArray[128];
|
||||
extern void RemoveKeyboardDriver();
|
||||
|
|
Loading…
Reference in New Issue