Collapse All
Parallels C API Reference Guide
PrlApi_ScaleImage Function
PrlApi.h System Functions

The PrlApi_ScaleImage scales image and put a new image to a buffer.

Syntax
PRL_RESULT PrlApi_ScaleImage(
    PRL_CONST_VOID_PTR pOriginalImage, 
    PRL_UINT32 nOriginalImageSize, 
    PRL_IMAGE_FORMAT nFormat, 
    PRL_INT32 nQuality, 
    PRL_UINT32 nScaleWidth, 
    PRL_UINT32 nScaleHeight, 
    PRL_VOID_PTR pNewImage, 
    PRL_UINT32_PTR pnNewImageSize
);
File
Parameters

pOriginalImage
[in] Original image raw data.
nOriginalImageSize
Original image data size.
nFormat
Image format to use.
nQuality
Image quality factor. Must be in the range from 0 to 100, or -1. Specify 0 to use the highest data compression, 100 for no compression, and -1 for default.
nScaleWidth
The width of the area to scale (pixels).
nScaleHeight
The height of the area to scale (pixels).
pNewImage
[out] New image raw data.
pnNewImageSize
New image data size. [in] The size of the output buffer (in bytes). Set the buffer pointer to null and this parameter's value to zero to receive the required size. [out] The required output buffer size.
Returns

PRL_RESULT . Possible values:

PRL_ERR_INVALID_ARG - invalid handle or null pointer was passed.

PRL_ERR_BUFFER_OVERRUN - the size of the output buffer is not large enough. The parameter that is used to specify the size will contain the required size.

PRL_ERR_NO_DATA - incorrect image format.

PRL_ERR_SUCCESS - function completed successfully.

Links
Copyright © 1999-2011 Parallels Holdings, Ltd. and its affiliates. All rights reserved.
What do you think about this topic? Send feedback!