src/audio/mint/SDL_mintaudio_it.S
changeset 1093 d00b4d8508ab
parent 961 185acc07127a
child 1096 37b766becf3b
equal deleted inserted replaced
1092:1f37386ef508 1093:d00b4d8508ab
    64 	notw	_SDL_MintAudio_mutex
    64 	notw	_SDL_MintAudio_mutex
    65 	
    65 	
    66 	/* Swap buffers */
    66 	/* Swap buffers */
    67 	eorw	#1,_SDL_MintAudio_numbuf
    67 	eorw	#1,_SDL_MintAudio_numbuf
    68 
    68 
    69 	moveml	d0-d2/a0-a2,sp@-
    69 	moveml	d0-d7/a0-a6,sp@-
    70 
    70 
    71 	/* Callback */
    71 	/* Callback */
    72 	jsr	_SDL_MintAudio_Callback
    72 	jsr	_SDL_MintAudio_Callback
    73 
    73 
    74 	/* Set new buffer */
    74 	/* Set new buffer */
    88 	clrw	sp@-
    88 	clrw	sp@-
    89 	movew	#131,sp@-
    89 	movew	#131,sp@-
    90 	trap	#14
    90 	trap	#14
    91 	lea	sp@(12),sp
    91 	lea	sp@(12),sp
    92 
    92 
    93 	moveml	sp@+,d0-d2/a0-a2
    93 	moveml	sp@+,d0-d7/a0-a6
    94 
    94 
    95 	clrw	_SDL_MintAudio_mutex
    95 	clrw	_SDL_MintAudio_mutex
    96 _SDL_MintAudio_EmptyGsxbInterrupt:
    96 _SDL_MintAudio_EmptyGsxbInterrupt:
    97 	rts
    97 	rts
    98 
    98 
   123 	notw	_SDL_MintAudio_mutex
   123 	notw	_SDL_MintAudio_mutex
   124 	
   124 	
   125 	/* Swap buffers */
   125 	/* Swap buffers */
   126 	eorw	#1,_SDL_MintAudio_numbuf
   126 	eorw	#1,_SDL_MintAudio_numbuf
   127 
   127 
   128 	moveml	d0-d2/a0-a2,sp@-
   128 	moveml	d0-d7/a0-a6,sp@-
   129 
   129 
   130 	/* Callback */
   130 	/* Callback */
   131 	jsr	_SDL_MintAudio_Callback
   131 	jsr	_SDL_MintAudio_Callback
   132 
   132 
   133 	/* Set new buffer */
   133 	/* Set new buffer */
   147 	clrw	sp@-
   147 	clrw	sp@-
   148 	movew	#131,sp@-
   148 	movew	#131,sp@-
   149 	trap	#14
   149 	trap	#14
   150 	lea	sp@(12),sp
   150 	lea	sp@(12),sp
   151 
   151 
   152 	moveml	sp@+,d0-d2/a0-a2
   152 	moveml	sp@+,d0-d7/a0-a6
   153 
   153 
   154 	clrw	_SDL_MintAudio_mutex
   154 	clrw	_SDL_MintAudio_mutex
   155 SDL_MintAudio_XbiosEnd:
   155 SDL_MintAudio_XbiosEnd:
   156 	rte
   156 	rte
   157 
   157 
   171 	notw	_SDL_MintAudio_mutex
   171 	notw	_SDL_MintAudio_mutex
   172 	
   172 	
   173 	/* Swap buffers */
   173 	/* Swap buffers */
   174 	eorw	#1,_SDL_MintAudio_numbuf
   174 	eorw	#1,_SDL_MintAudio_numbuf
   175 
   175 
   176 	moveml	d0-d1/a0-a1,sp@-
   176 	moveml	d0-d7/a0-a6,sp@-
   177 
   177 
   178 	/* Callback */
   178 	/* Callback */
   179 	jsr	_SDL_MintAudio_Callback
   179 	jsr	_SDL_MintAudio_Callback
   180 
   180 
   181 	/* Set new buffer */
   181 	/* Set new buffer */
   203 	rorl	#8,d1
   203 	rorl	#8,d1
   204 	moveb	d1,a0@(0x11)
   204 	moveb	d1,a0@(0x11)
   205 	rorl	#8,d1
   205 	rorl	#8,d1
   206 	moveb	d1,a0@(0x0f)
   206 	moveb	d1,a0@(0x0f)
   207 
   207 
   208 	moveml	sp@+,d0-d1/a0-a1
   208 	moveml	sp@+,d0-d7/a0-a6
   209 
   209 
   210 	clrw	_SDL_MintAudio_mutex
   210 	clrw	_SDL_MintAudio_mutex
   211 SDL_MintAudio_Dma8End:
   211 SDL_MintAudio_Dma8End:
   212 	rte
   212 	rte
   213 
   213 
   227 	notw	_SDL_MintAudio_mutex
   227 	notw	_SDL_MintAudio_mutex
   228 	
   228 	
   229 	/* Swap buffers */
   229 	/* Swap buffers */
   230 	eorw	#1,_SDL_MintAudio_numbuf
   230 	eorw	#1,_SDL_MintAudio_numbuf
   231 
   231 
   232 	moveml	d0-d1/a0-a1,sp@-
   232 	moveml	d0-d7/a0-a6,sp@-
   233 
   233 
   234 	/* Callback */
   234 	/* Callback */
   235 	jsr	_SDL_MintAudio_Callback
   235 	jsr	_SDL_MintAudio_Callback
   236 
   236 
   237 	/* Set new buffer */
   237 	/* Set new buffer */
   247 	/* Modify STFA replay buffers */
   247 	/* Modify STFA replay buffers */
   248 	movel	d1,a1@(STFA_SOUND_START)
   248 	movel	d1,a1@(STFA_SOUND_START)
   249 	addl	_SDL_MintAudio_audiosize,d1
   249 	addl	_SDL_MintAudio_audiosize,d1
   250 	movel	d1,a1@(STFA_SOUND_END)
   250 	movel	d1,a1@(STFA_SOUND_END)
   251 
   251 
   252 	moveml	sp@+,d0-d1/a0-a1
   252 	moveml	sp@+,d0-d7/a0-a6
   253 
   253 
   254 	clrw	_SDL_MintAudio_mutex
   254 	clrw	_SDL_MintAudio_mutex
   255 SDL_MintAudio_StfaEnd:
   255 SDL_MintAudio_StfaEnd:
   256 	rte
   256 	rte