HomeLine-AInitializationGet pixel

6.6 Put pixel

Name: »Put pixel«
Line-A number: $A001
Syntax: See 'Bindings for put_pixel'
Description: This Line-A function sets one pixel in the specified colour at the specified coordinates.
Return value: The function does not return a result.
Availability: All TOS versions.
See also: Binding   LINEA   Get Pixel

6.6.1 Bindings for put_pixel

Pure-C: void put_pixel( int16_t x, int16_t y, int16_t color );
Assembler:
movem.l   D0-D2/A0-A2,-(A7)  ; Save registers
move.l    pParamblk,A0       ; Pointer parameter block LINEA
move.l    (8,A0),A1          ; Address of intin
move.w    color,(A1)         ; Colour in intin[0]
move.l    (12,A0),A1         ; Address of ptsin
move.w    x,(A1)             ; X-coordinate in ptsin[0]
move.w    y,(2,A1)           ; Y-coordinate in ptsin[1]
dc.w      $A001              ; Line-A opcode
movem.l   (A7)+,D0-D2/A0-A2  ; Restore registers

HomeLine-AInitializationGet pixel