PUT_DIB_BLOCK@

Platform

Win32, x64

Purpose

To save a DIB block in a BMP file (24 bits per pixel) or a JPEG file.

Syntax

 SUBROUTINE PUT_DIB_BLOCK@( FILENAME, PARRAY, AW, AH, ADX,
+  ADY, W, H, NBPP, ERCODE )
 CHARACTER(*) FILENAME
 CHARACTER PARRAY(3,AW,AH)
 INTEGER AW,AH,ADX,ADY,W,H,NBBP,ERCODE

Description

All of the arguments are input values except for ERCODE which returns the error status.

FILENAME is the name of the BMP file.

AW and AH are dimensions of PARRAY.

ADX and ADY are offsets used when reading the data from PARRAY.

W and H are the width and height of the image data to be copied.

PARRAY is the same as in GET_DIB_BLOCK@.

NBPP is currently not used but should be set to 24 because currently this routine always writes out BMP files with 24 bits per pixel.

ERROR will return:


 

0

SUCCESS

 

1

ERROR ON FILE OPEN

 

3

ERROR ON WRITE

 

13

BAD NUMBER

 

For JPEG data the file name must have a .jpg or .jpeg extension.

See also

GET_DIB_SIZE@, GET_DIB_BLOCK@, DIB_PAINT@

Example

See Drawing device independent bitmaps.

 

 

Basket
Empty
 
Copyright © 1999-2024 Silverfrost Limited