CreateFeature
|
[in] unsigned short type
|
Type of the feature to be created. Can be one of the following values:
|
FEATURE_TYPE_UINTEGER - unsigned 32-bit integer feature, maps to a slider with value, minimum, maximum and increment
|
FEATURE_TYPE_INTEGER - signed 32-bit integer feature, maps to a slider with value, min, maximum, increment and physical unit
|
FEATURE_TYPE_INTEGER64 - signed 62-bit integer feature, maps to a slider with value, min, maximum, increment and physical unit
|
FEATURE_TYPE_FLOAT - floating point 32-bit feature, maps to a slider with value, minimum, maximum and physical unit
|
FEATURE_TYPE_STRING - string feature, maps to an edit box showing a string of text
|
FEATURE_TYPE_BOOLEAN - boolean feature, maps to a check box
|
FEATURE_TYPE_COMMAND - command feature, maps to a command button
|
FEATURE_TYPE_ENUMERATION - enumeration feature, maps to dropdown box with a list of selectable items
|
|
[in] const char* name
|
Name of the feature to be created. Must not be NULL or empty.
|
|
[in] const char* category
|
GenICam category under which the feature will be created. This parameter should be either "Root" or the name of the existing category created via CreateCategory.
|
[in] unsigned short access
|
Access mode for the feature to be created. Can be one of the following values:
|
FEATURE_ACCESS_NA - feature is not available
|
FEATURE_ACCESS_RO - feature is available only for reading
|
FEATURE_ACCESS_WO - feature is available only for writing
|
FEATURE_ACCESS_RW - feature is fully available
|
|
[in] const char* description
|
String containing the description of the feature.
|
|
[in] unsigned short namespace
|
Namespace to which the feature will belong. Can be one of the following values:
|
FEATURE_NAMESPACE_STANDARD - feature will be created with the "Standard" namespace tag (recommended for features which follow the GenICam SFNC specifications).
|
FEATURE_NAMESPACE_CUSTOM - feature will be created with the "Custom" namespace tag (recommended for features with proprietary names).
|
|
S_OK
|
Success
|
E_FAIL
|
Failure
|
E_NOINTERFACE
|
Category does not exist
|
E_INVALIDARG
|
Wrong feature type or access
|
|
|
static CGevCamera* m_pCamera;
|
m_pCamera = createCamera();
|
|
m_pCamera->CreateFeature(FEATURE_TYPE_INTEGER, "TestFeatureInt", "Root", FEATURE_ACCESS_RW, "GigESim demo feature");
|
m_pCamera->SetFeatureRange("TestFeatureInt", 0, 1000, 1);
|
|
m_pCamera->CreateFeature(FEATURE_TYPE_ENUMERATION, "TestFeatureEnum", "Root", FEATURE_ACCESS_RW);
|
m_pCamera->AddEnumEntry("TestEnumFeature", "First item", 1);
|
m_pCamera->AddEnumEntry("TestFeatureEnum", "Second item", 2);
|
m_pCamera->AddEnumEntry("TestFeatureEnum", "Third item", 3);
|
Standard Feature
|
Type
|
Default Value
|
Width
|
Integer
|
640
|
Height
|
Integer
|
480
|
PayloadSize
|
Integer
|
SizeX * SizeY
|
PixelFormat
|
Enumerated
|
"Mono8"
|
AcquisitionMode
|
Enumerated
|
Continuous
|
AcquisitionStart
|
Command
|
N/A
|
AcquisitionStop
|
Command
|
N/A
|