
Machine Vision Camera SDK (C) Developer Guide
4.8.4 MV_CC_GetImageInfo
Get the basic image information.
API Definition
int MV_CC_GetImageInfo(
void
MV_IMAGE_BASIC_INFO
);
*handle,
*pstInfo
Parameters
handle
[IN] Device handle, which is returned by MV_CC_CreateHandle or
MV_CC_CreateHandleWithoutLog .
pstInfo
[OUT] Basic image information, see the structure MV_IMAGE_BASIC_INFO for details.
Return Value
Return MV_OK(0) on success, and return Error Code on failure.
Remarks
● After the device is connected, call this API to get basic image information, including width,
height, frame rate and resolution.
● This API is not supported by CameraLink device.
Example
The following sample code is for reference only.
#include "MvCameraControl.h"
void main()
{
int nRet = -1;
void* m_handle = NULL;
//Enumerate all devices corresponding to specified transport protocol
within subnet
unsigned int nTLayerType = MV_GIGE_DEVICE | MV_USB_DEVICE;
MV_CC_DEVICE_INFO_LIST m_stDevList = {0};
int nRet = MV_CC_EnumDevices(nTLayerType, &m_stDevList);
if (MV_OK != nRet)
{
printf("error: EnumDevices fail [%x]\n", nRet);
return;
}
140



































































































































































































































































































































































































