THORLABS DCU223x Operation Manual And Sdk page 204

Cdd and cmos cameras
Hide thumbs Also See for DCU223x:
Table of Contents

Advertisement

DCx Cameras
Example overlay size and position
//------------------------------------
//
Size of overlay
//------------------------------------
// Query maximum size of overlay area
UINT OverlaySize[2];
is_DirectRenderer
(hCam, DR_GET_MAX_OVERLAY_SIZE,
(void*)OverlaySize, sizeof(OverlaySize));
INT nWidth = OverlaySize[0];
INT nHeight = OverlaySize[1];
// Set size of overlay area
UINT Size[2];
Size[0] = 100;
Size[1] = 120;
is_DirectRenderer
(hCam, DR_SET_OVERLAY_SIZE,
(void*)Size,
// Set position of overlay area
UINT Position[2];
Position[0] = 20;
Position[1] = 0;
is_DirectRenderer
(hCam, DR_SET_OVERLAY_POSITION,
void*)Position,
Example key color
//------------------------------------
//
Key color
//------------------------------------
// Get current key color
UINT OverlayKeyColor[3];
is_DirectRenderer
(hCam, DR_GET_OVERLAY_KEY_COLOR,
(void*)OverlayKeyColor, sizeof(OverlayKeyColor));
INT nRed = OverlayKeyColor[0];
INT nGreen = OverlayKeyColor[1];
INT nBlue = OverlayKeyColor[2];
// Set new key color
OverlayKeyColor[0] = GetRValue(m_rgbKeyColor);
OverlayKeyColor[1] = GetGValue(m_rgbKeyColor);
OverlayKeyColor[2] = GetBValue(m_rgbKeyColor);
is_DirectRenderer
(hCam, DR_SET_OVERLAY_KEY_COLOR,
(void*)OverlayKeyColor, sizeof(OverlayKeyColor));
Example display
//------------------------------------
//
Display
//------------------------------------
// Show overlay
is_DirectRenderer
(hCam, DR_SHOW_OVERLAY, NULL, NULL);
// Hide overlay
is_DirectRenderer
(hCam, DR_HIDE_OVERLAY, NULL, NULL);
Example scaling
//------------------------------------
//
Scaling
//------------------------------------
// Enable scaling
is_DirectRenderer
(hCam, DR_ENABLE_SCALING, NULL, NULL);
// Disable scaling
is_DirectRenderer
(hCam, DR_DISABLE_SCALING, NULL, NULL);
Example transparency
//------------------------------------
//
Transparency
//------------------------------------
// Enable semi-transparent overlay
is_DirectRenderer
(hCam, DR_ENABLE_SEMI_TRANSPARENT_OVERLAY, NULL, NULL);
// Disable semi-transparent overlay
is_DirectRenderer
(hCam, DR_DISABLE_SEMI_TRANSPARENT_OVERLAY, NULL, NULL);
202
sizeof
(Size));
sizeof
(Position));
© 2013 Thorlabs GmbH

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Dcu224xDcc1240xDcc1545mDcc1645c

Table of Contents