Auto-Weißabgleich konfigurieren

uEye Kamera-Handbuch Version 4.92


Auto-Weißabgleich konfigurieren

Windows_Logo
Linux_Logo

USB 2.0

USB 3.0

GigE

USB 2.0

USB 3.0

GigE

Syntax

INT is_AutoParameter(HIDS hCam, UINT nCommand, void* pParam, UINT cbSizeOfParam)

Beschreibung

Die Funktion aktiviert/deaktiviert den Auto-Weißabgleich. Mit der Funktion können alle unterstützten Typen für den Weißabgleichs abgefragt werden. Neben dem älteren Weißabgleich über den Grey-World-Algorithmus gibt es auch eine Farbtemperaturregelung (color temperature) nach Kelvin. Daneben können mit der Funktion die unterstützten Farbräume abgefragt und gesetzt werden.

Über den Übergabeparameter nCommand wird dabei der Funktionsmodus gewählt. Der Übergabeparameter pParam ist abhängig vom Funktionsmodus unterschiedlich belegt; bei Funktionen zum Setzen oder Rücklesen eines Wertes enthält pParam einen Zeiger auf eine Variable vom Typ UINT. Die Größe des Speicherbereichs, auf den pParam verweist, wird im Übergabeparameter cbSizeOfParam angegeben.

Übergabeparameter

hCam

Handle auf Kamera

pParam

Zeiger auf Funktionsparameter, der abhängig von nCommand unterschiedlich belegt ist.

cbSizeOfParam

Größe des Speicherbereichs in Byte, auf den pParam verweist.

Beispiel 1

UINT nSupportedTypes = 0;

INT nRet = is_AutoParameter(m_hCam, IS_AWB_CMD_GET_SUPPORTED_TYPES, (void*)&nSupportedTypes,

                          sizeof(nSupportedTypes));

 

if (nRet == IS_SUCCESS)

{

  if ((nSupportedTypes & IS_AWB_COLOR_TEMPERATURE) != 0)

  {

      // AWB type "Color Temperature" is supported

  }

 

  if ((nSupportedTypes & IS_AWB_GREYWORLD) != 0)

  {

      // AWB type "Greyworld" is supported

  }

}

Beispiel 2

UINT nType = 0;

 

// Read current type

INT nRet = is_AutoParameter(m_hCam, IS_AWB_CMD_GET_TYPE, (void*)&nType, sizeof(nType));

 

// Write new type

nType = IS_AWB_GREYWORLD;

nRet = is_AutoParameter(m_hCam, IS_AWB_CMD_SET_TYPE, (void*)&nType, sizeof(nType));

Beispiel 3

// Is AWB enabled?

UINT nEnable;

INT nRet = is_AutoParameter(m_hCam, IS_AWB_CMD_GET_ENABLE, (void*)&nEnable, sizeof(nEnable));

 

// Enable AWB (once)

nEnable = IS_AUTOPARAMETER_ENABLE_RUNONCE;

nRet = is_AutoParameter(m_hCam, IS_AWB_CMD_SET_ENABLE, (void*)&nEnable, sizeof(nEnable));

Beispiel 4

// Choose the auto color mode to get the supported color models for this mode
// See uEye.h for auto color mode defines
INT nSupported = IS_AWB_COLOR_TEMPERATURE;
 
if (IS_SUCCESS == is_AutoParameter(m_hCam, IS_AWB_CMD_GET_SUPPORTED_RGB_COLOR_MODELS,
                                  (void*)&nSupported, sizeof(nSupported)))
{
if ((nSupported & RGB_COLOR_MODEL_SRGB_D50) != 0)
{
  // Color model SRGB D50 is supported. See uEye.h for color model defines
}
}

Beispiel 5

UINT nRGBColorModel = 0;

INT nRet = is_AutoParameter(m_hCam, IS_AWB_CMD_GET_RGB_COLOR_MODEL, (void*)&nRGBColorModel,

                          sizeof(nRGBColorModel));

 

nRGBColorModel = RGB_COLOR_MODEL_CIE_RGB_E;

 

nRet = is_AutoParameter(m_hCam, IS_AWB_CMD_SET_RGB_COLOR_MODEL, (void*)&nRGBColorModel,

                      sizeof(nRGBColorModel));

Haben Sie Verbesserungshinweise? Senden Sie ein kurzes Feedback zu diesem Kapitel. Vielen Dank!
Bei technischen Fragen wenden Sie sich bitte an Ihren lokalen Händler oder nutzen Sie das Support-Formular auf unserer Internetseite.


© 2019 IDS Imaging Development Systems GmbH
https://de.ids-imaging.com