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

BitMapScale

Perform raster scaling on a bit map.

Declaration

Source position: agraphics.pas line 2153

procedure BitMapScale(

  BitScaleArgs: PBitScaleArgs

);

Arguments

BitScaleArgs

  

Structure of parameters describing scale

Description

Scale a source bit map to a non-overlapping destination bit map.

Overlapping source and destination bitmaps are not supported Make sure that you provide enough memory for the destination bitmap to hold the result

In the destination bitmap only the area where the scaled source bitmap is put into is changed. A frame of the old bitmap is left.

Pass a BitScaleArgs structure filled with the following arguments to this function:

bsa_SrcX, bsa_SrcY
upper left coordinate in source bitmap
bsa_SrcWidth, bsa_SrcHeight
Width and Height of source bitmap
bsa_DestX, bsa_DestY
upper left coordinate in destination bitmap
bsa_DestWidth, bsa_DestHeight
this function will set these values. Use the bsa_???Factor for scaling
bsa_XSrcFactor:bsa_XDestFactor
Set these to get approximately the same ratio as bsa_SrcWidth:bsa_DestWidth, but usually not exactly the same number.
bsa_YSrcFactor:bsa_YDestFactor
Set these to get approximately the same ratio as bsa_SrcHeight:DestHeight, but usually not exactly the same number.
bsa_SrcBitMap
pointer to source bitmap to be scaled
bsa_DestBitMap
pointer to destination bitmap which will hold the scaled bitmap. Make sure it's big enough!
bsa_Flags
reserved for future use. Set it to zero!
bsa_XDDA, bsa_YDDA
for future use.
bsa_Reserved1, bsa_Reserved2
for future use.

bsa_DestWidth and bsa_DestHeight will be set by this function

See also

ScalerDiv

  

Get the scaling result that BitMapScale would.


Documentation generated on: 2021-07-30