Unit 'agraphics' Package
[Overview][Constants][Types][Procedures and functions][Variables][Index] [#amunits]

WritePixelArray8

Write the pen number value of a rectangular array of pixels starting at a specified x,y location and continuing through to another x,y location within a certain RastPort.

Declaration

Source position: agraphics.pas line 2412

function WritePixelArray8(

  rp: pRastPort;

  xstart: LongWord;

  ystart: LongWord;

  xstop: LongWord;

  ystop: LongWord;

  array_: PByte;

  temprp: pRastPort

):LongInt;

Arguments

rp

  

A pointer to a RastPort

xstart

  

X Start point

ystart

  

Y Start point

xstop

  

X end point

ystop

  

Y end point

array_

  

a pointer to an array of Bytess from which to fetch the pixel data. Allocate at least ((((Width + 15) shr 4) shl 4) * (ystop - ystart + 1)) bytes.

temprp

  

A temporary rastport (copy of rp with Layer set = nil, temporary memory allocated for temprp^.BitMap with Rows set = 1, temprp^.BitMap with BytesPerRow = (((width + 15) shr 4) shl 1), and temporary memory allocated for temprp^.BitMap^.Planes[])

Function result

Count will be set to the number of pixels plotted.

Description

For each pixel in a rectangular region, decode the pen number selector from a linear array of pen numbers into the bit-planes used to describe a particular rastport. xstop must be >= xstart and ystop must be >= ystart

See also

WritePixel

  

Change the pen num of one specific pixel in a specified RastPort.


Documentation generated on: 2021-07-30