Changes

Jump to: navigation, search

Programming:Fast plot

57 bytes added, 18:04, 17 March 2018
/* Fast plotting routine for MODE 1 */
<pre>
CMASK EQU &B338 ;Adress Address for colormask
;664/6128: &B6A3
== Fast plotting routine for MODE 1 ==
This routine is approx. 6 times faster than the OS routine GRA PLOT, because it is dpendent dependent to MODE 1 and doesn't perform range checks. It can draw 10500 pixels per second.
'''Input:''' DE = ''X (0..319)'', HL = ''Y (0..199)''
<pre>
CMASK EQU &B338 ;Adress Address for colormask
;664/6128: &B6A3
<pre>
CMASK EQU &B338 ;Adress Address for colormask
;664/6128 - &B6A3
ADD HL, HL ;of the raster line
LD A, E ;Lowbyte X to A
SRL D ;calculate X\8, because
RR E ;8 pixel per byte
RET ;done
</pre>
 
[[Category:Programming]]
14
edits