RotateDIB90

#include "BIDIB.H"

 

HANDLE CALLBACK RotateDIB90(HANDLE hbmOld)

Description

This function rotates the device independent bitmap (DIB) 90 degrees, physically, bit by bit, in a positive direction.

Parameters

HANDLE

hbmOld

Handle to the DIB to be rotated

Limitation

The available global memory.

Return values

Handle to the newly created, rotated DIB. NULL on error.

Programming notes

This function creates another DIB whose dimensions are the rotated dimensions of the original (transposes horizontal and vertical size).

Requirements

Header :     Declared in BiDIB.h; include BiDIB.h.

Library :    Use BiDIB.lib.

DLLs :       BiDIB.dll.

Code example

#include "BIDIB.H"

 

HANDLE hOriginalDIB, hRotatedDIB;

// create, or load original DIB

.

.

.

if ( (hRotatedDIB = RotateDIB90(hOriginalDIB)) == NULL)

{

                // could not rotate DIB

                // possible not enough memory or too many DCs are in use

}