#include "l_bitmap.h"
L_VOID pEXT_CALLBACK YourFunction(pOutScan, pInScan, pBitmap, nLeft, nRight, pDibInfo, pUserData)
This callback is used to convert input image data to output data suitable for display.
Pointer to the output buffer. The function should fill this buffer with data compatible with the display, according to information in pDibInfo.
Pointer to the input buffer containing data of the same type as pBitmap.
Pointer to the bitmap handle structure indicating the format of the input buffer.
Index of the first pixel in pInScan that should be copied to pOutBuf.
Index of the first pixel after nLeft that should not be copied to pOutBuf.
Pointer to PAINTDIBINFO structure containing information on the expected output image data.
Void pointer that you can use to access a variable or structure containing data that your callback function needs. This gives you a way to receive data indirectly from the function that uses this callback function. (This is the same pointer that you pass in the pUserData parameter of the PAINTCALLBACKDATA structure.)
This function does not return any value.
You should use this callback if the built-in LEADTOOLS functions for converting image data are not suitable. However, the built-in functions are fast should be capable of performing most conversion needed. So it is recommended you use this callback only as a last resort.
The callback is expected to convert one row of image data. pInScan
contains the input data and pOutScan contains the output data.
The callback is expected to skip the first nLeft
pixels in the input buffer and convert the next (nRight - nLeft) pixels. So, nLeft is the index of the first pixel and not the byte offset into the input buffer. nRight
is the index of the first pixel that should not be converted. Only pixels nLeft, nLeft+1, ... , nRight - 1 are expected to be copied to pOutScan.
pDibInfo
is the PAINTDIBINFO structure initialized by the PAINTCALLBACK_GETDIBINFO callback. This callback will not be called unless you provide a valid PAINTCALLBACK_GETDIBINFO callback.
Required DLLs and Libraries
For an example, refer to L_PaintDCCallback.
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document