LoadImage
Top  Previous  Next

Description

Loads the image from the specified file into the internal frame buffer and displays it in ActiveDcam window. The method supports BMP, TIFF and JPEG formats.


Syntax


[VB]
objActiveDcam.LoadImage File


[C/C++]
HRESULT LoadImage( bstr File );


Data Types
[VB]

File: String


Parameters
[C/C++]

File [in]  
The string containing the file name and path  


Return Values


S_OK  
Success  
E_FAIL  
Failure.  
E_INVALIDARG  
Invalid file name.  


Example


This VB example shows how to load an image file.


ActiveDcam1.LoadImage "C:\\myframe.jpg"
 

Remarks


When the image has been loaded into the internal buffer, the FrameLoaded event will be fired.

The image format is defined by the file extension indicated in the File argument. Use "bmp" for a BMP file, "tif" for TIFF, and "jpg" for JPEG. If none of these extensions are found in the File string, an error will occur.