All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
rcg Namespace Reference

Classes

class  Buffer
 The buffer class encapsulates a Genicam buffer that is provided by a stream. More...
 
class  CPort
 This is the port definition that connects GenAPI to GenTL. More...
 
class  Device
 The device class encapsulates a Genicam device. More...
 
class  GenTLException
 
class  GenTLWrapper
 Wrapper for dynamically loaded GenICam transport layers. More...
 
class  Image
 The image class encapsulates image information. More...
 
class  ImageList
 An object of this class manages a limited number of images. More...
 
class  Interface
 The interface class encapsulates a Genicam interface. More...
 
class  Stream
 The stream class encapsulates a Genicam stream. More...
 
class  System
 The system class encapsulates a Genicam transport layer. More...
 

Enumerations

enum  ImgFmt { PNM, PNG }
 
enum  PARTDATATYPE_IDS {
  PART_DATATYPE_UNKNOWN = 0, PART_DATATYPE_2D_IMAGE = 1, PART_DATATYPE_2D_PLANE_BIPLANAR = 2, PART_DATATYPE_2D_PLANE_TRIPLANAR = 3,
  PART_DATATYPE_2D_PLANE_QUADPLANAR = 4, PART_DATATYPE_3D_IMAGE = 5, PART_DATATYPE_3D_PLANE_BIPLANAR = 6, PART_DATATYPE_3D_PLANE_TRIPLANAR = 7,
  PART_DATATYPE_3D_PLANE_QUADPLANAR = 8, PART_DATATYPE_CONFIDENCE_MAP = 9, PART_DATATYPE_CHUNKDATA = 10, PART_DATATYPE_CUSTOM_ID = 1000
}
 Enumeration describing which data type is present in given buffer part as taken from GenTL 1.5 definition. More...
 
enum  PAYLOADTYPE_INFO_IDS {
  PAYLOAD_TYPE_UNKNOWN = 0, PAYLOAD_TYPE_IMAGE = 1, PAYLOAD_TYPE_RAW_DATA = 2, PAYLOAD_TYPE_FILE = 3,
  PAYLOAD_TYPE_CHUNK_DATA = 4, PAYLOAD_TYPE_JPEG = 5, PAYLOAD_TYPE_JPEG2000 = 6, PAYLOAD_TYPE_H264 = 7,
  PAYLOAD_TYPE_CHUNK_ONLY = 8, PAYLOAD_TYPE_DEVICE_SPECIFIC = 9, PAYLOAD_TYPE_MULTI_PART = 10, PAYLOAD_TYPE_CUSTOM_ID = 1000
}
 Payload types as taken from GenTL 1.5 definition. More...
 
enum  PIXELFORMAT_NAMESPACE_IDS {
  PIXELFORMAT_NAMESPACE_UNKNOWN = 0, PIXELFORMAT_NAMESPACE_GEV = 1, PIXELFORMAT_NAMESPACE_IIDC = 2, PIXELFORMAT_NAMESPACE_PFNC_16BIT = 3,
  PIXELFORMAT_NAMESPACE_PFNC_32BIT = 4, PIXELFORMAT_NAMESPACE_CUSTOM_ID = 1000
}
 Pixelformat namespace IDs as taken from GenTL 1.5 definition. More...
 

Functions

std::shared_ptr< GenApi::CNodeMapRefallocNodeMap (std::shared_ptr< const GenTLWrapper > gentl, void *port, CPort *cport, const char *xml=0)
 Convenience function that returns a GenICam node map from the given port. More...
 
bool callCommand (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, bool exception=false)
 Calls the given command. More...
 
void checkFeature (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, const char *value, bool igncache=false)
 Checks the value of given feature and throws an exception in case of a mismatch. More...
 
bool convertImage (uint8_t *rgb_out, uint8_t *mono_out, const uint8_t *raw, uint64_t pixelformat, size_t width, size_t height, size_t xpadding)
 Converts image to RGB and monochrome format. More...
 
void convYCbCr411toQuadRGB (uint8_t rgb[12], const uint8_t *row, int i)
 Conversion of a group of four pixels from YCbCr411 format (6 bytes for four pixels) to RGB. More...
 
void convYCbCr411toRGB (uint8_t rgb[3], const uint8_t *row, int i)
 Conversion of one pixel from YCbCr411 format (6 bytes for four pixels) to RGB. More...
 
void convYCbCr422toQuadRGB (uint8_t rgb[12], const uint8_t *row, int i)
 Conversion of a group of four pixels from YCbCr422 format (8 bytes for 4 pixels) to RGB. More...
 
void convYCbCr422toRGB (uint8_t rgb[3], const uint8_t *row, int i)
 Conversion of one pixel from YCbCr422 format (4 bytes for 2 pixels) to RGB. More...
 
bool editNodemap (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char root[])
 Shows nodemap in a curses gui in the terminal and allows editing of parameters. More...
 
std::string ensureNewFileName (std::string name)
 This method checks if the given file name already exists and produces a new file name if this happens. More...
 
std::string formatValue (GenApi::IInteger *node, int64_t value)
 Takes an integer value and formats it according to the specification in the node. More...
 
std::vector< std::string > getAvailableGenTLs (const char *paths)
 The function uses the given list files of paths that is separated by colons or semicolons, depending on the used operating system, and returns all files with the suffix .cti. More...
 
bool getBoolean (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, bool exception=false, bool igncache=false)
 Get the value of a boolean feature of the given nodemap. More...
 
std::shared_ptr< GenApi::CChunkAdaptergetChunkAdapter (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const std::string &tltype)
 NOTE: This function is deprecated. More...
 
void getColor (uint8_t rgb[3], const std::shared_ptr< const Image > &img, uint32_t ds, uint32_t i, uint32_t k)
 Expects an image in Mono8, RGB8, YCbCr411_8, YCbCr422_8 or YUV422_8 format and returns the color as RGB value at the given pixel location. More...
 
std::string getComponetOfPart (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const Buffer *buffer, uint32_t ipart)
 
std::shared_ptr< DevicegetDevice (const char *devid, uint64_t timeout)
 Searches across all transport layers and interfaces for a device. More...
 
std::shared_ptr< DevicegetDevice (const char *id)
 
std::vector< std::shared_ptr< Device > > getDevices ()
 
std::vector< std::shared_ptr< Device > > getDevices (uint64_t timeout)
 Returns a list of all devices that are available across all transport layers and interfaces. More...
 
std::string getEnum (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, bool exception=false)
 Get the value of an enumeration of the given nodemap. More...
 
std::string getEnum (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, std::vector< std::string > &list, bool exception=false)
 Get the current value and list of possible values of an enumeration of the given nodemap. More...
 
double getFloat (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, double *vmin=0, double *vmax=0, bool exception=false, bool igncache=false)
 Get the value of a double feature of the given nodemap. More...
 
int64_t getInteger (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, int64_t *vmin=0, int64_t *vmax=0, bool exception=false, bool igncache=false)
 Get the value of an integer feature of the given nodemap. More...
 
size_t getRegister (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, uint8_t *buffer, size_t len, size_t *total=0, bool exception=false, bool igncache=false)
 Read value of type register. More...
 
std::string getString (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, bool exception=false, bool igncache=false)
 Get the value of a feature of the given nodemap. More...
 
bool isFormatSupported (uint64_t pixelformat, bool only_color)
 Returns true if the given pixel format is supported by the convertImage() function. More...
 
bool isHostBigEndian ()
 
std::string loadFile (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, bool exception=false)
 Loads the contents of a file via the GenICam FileAccessControl interface. More...
 
bool loadStreamableParameters (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, bool exception=false)
 Load all streamable parameters from file into the nodemap. More...
 
void printNode (const std::string &prefix, GenApi::INode *node, int depth, bool show_enum_list)
 Recursive printing of nodes to standard out. More...
 
bool printNodemap (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char root[], int depth=100, bool show_enum_list=true)
 Printing of nodemap, starting at given root node. More...
 
bool saveFile (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, const std::string &data, bool exception=false)
 Loads the contents of the given string as a file via the GenICam FileAccessControl interface. More...
 
bool saveStreamableParameters (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, bool exception=false)
 Store all streamable parameters from the nodemap into the file. More...
 
bool setBoolean (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, bool value, bool exception=false)
 Set the value of a boolean feature of the given nodemap. More...
 
bool setEnum (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, const char *value, bool exception=false)
 Set the value of an enumeration of the given nodemap. More...
 
bool setFloat (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, double value, bool exception=false)
 Set the value of a float feature of the given nodemap. More...
 
bool setInteger (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, int64_t value, bool exception=false)
 Set the value of an integer feature of the given nodemap. More...
 
bool setIPV4Address (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, const char *value, bool exception)
 Set the value of an integer feature of the given nodemap from an IP address. More...
 
size_t setRegister (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, const uint8_t *buffer, size_t len, bool exception=false)
 Set value of type register. More...
 
bool setString (const std::shared_ptr< GenApi::CNodeMapRef > &nodemap, const char *name, const char *value, bool exception=false)
 Set the value of a feature of the given nodemap. More...
 
std::string storeImage (const std::string &name, ImgFmt fmt, const Image &image, size_t yoffset=0, size_t height=0)
 Stores the given image. More...
 
std::string storeImageAsDisparityPFM (const std::string &name, const Image &image, int inv, float scale, float offset)
 Stores the given image as disparity. More...
 
void storePointCloud (std::string name, double f, double t, double scale, std::shared_ptr< const Image > left, std::shared_ptr< const Image > disp, std::shared_ptr< const Image > conf, std::shared_ptr< const Image > error)
 

Enumeration Type Documentation

◆ ImgFmt

Enumerator
PNM 
PNG 

Definition at line 46 of file image_store.h.

◆ PARTDATATYPE_IDS

Enumeration describing which data type is present in given buffer part as taken from GenTL 1.5 definition.

See Buffer::getPartDataType().

Enumerator
PART_DATATYPE_UNKNOWN 
PART_DATATYPE_2D_IMAGE 
PART_DATATYPE_2D_PLANE_BIPLANAR 
PART_DATATYPE_2D_PLANE_TRIPLANAR 
PART_DATATYPE_2D_PLANE_QUADPLANAR 
PART_DATATYPE_3D_IMAGE 
PART_DATATYPE_3D_PLANE_BIPLANAR 
PART_DATATYPE_3D_PLANE_TRIPLANAR 
PART_DATATYPE_3D_PLANE_QUADPLANAR 
PART_DATATYPE_CONFIDENCE_MAP 
PART_DATATYPE_CHUNKDATA 
PART_DATATYPE_CUSTOM_ID 

Definition at line 94 of file buffer.h.

◆ PAYLOADTYPE_INFO_IDS

Payload types as taken from GenTL 1.5 definition.

See Buffer::getPayloadType().

Enumerator
PAYLOAD_TYPE_UNKNOWN 
PAYLOAD_TYPE_IMAGE 
PAYLOAD_TYPE_RAW_DATA 
PAYLOAD_TYPE_FILE 
PAYLOAD_TYPE_CHUNK_DATA 
PAYLOAD_TYPE_JPEG 
PAYLOAD_TYPE_JPEG2000 
PAYLOAD_TYPE_H264 
PAYLOAD_TYPE_CHUNK_ONLY 
PAYLOAD_TYPE_DEVICE_SPECIFIC 
PAYLOAD_TYPE_MULTI_PART 
PAYLOAD_TYPE_CUSTOM_ID 

Definition at line 56 of file buffer.h.

◆ PIXELFORMAT_NAMESPACE_IDS

Pixelformat namespace IDs as taken from GenTL 1.5 definition.

See Buffer::getPixelFormatNamespace().

Enumerator
PIXELFORMAT_NAMESPACE_UNKNOWN 
PIXELFORMAT_NAMESPACE_GEV 
PIXELFORMAT_NAMESPACE_IIDC 
PIXELFORMAT_NAMESPACE_PFNC_16BIT 
PIXELFORMAT_NAMESPACE_PFNC_32BIT 
PIXELFORMAT_NAMESPACE_CUSTOM_ID 

Definition at line 78 of file buffer.h.

Function Documentation

◆ allocNodeMap()

std::shared_ptr< GenApi::CNodeMapRef > rcg::allocNodeMap ( std::shared_ptr< const GenTLWrapper gentl,
void *  port,
CPort cport,
const char *  xml = 0 
)

Convenience function that returns a GenICam node map from the given port.

Parameters
gentlPointer to GenTL Wrapper.
portPointer to module or remote port.
cportPointer to CPort Wrapper.
xmlPath and name for storing the received XML file or 0 if xml file should not be stored.
Returns
Allocated node map object or 0 if it cannot be allocated. The pointer must be freed by the calling function with delete.

Definition at line 156 of file cport.cc.

◆ callCommand()

bool rcg::callCommand ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
bool  exception = false 
)

Calls the given command.

Parameters
nodemapInitialized nodemap.
nameName of command.
exceptionTrue if an error should be signaled via exception instead of a return value.
Returns
True if value has been changed. False if feature does not exist, has a different datatype or is not writable.

Definition at line 61 of file config.cc.

◆ checkFeature()

void rcg::checkFeature ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
const char *  value,
bool  igncache = false 
)

Checks the value of given feature and throws an exception in case of a mismatch.

The check succeeds if the feature does not exist.

Parameters
nodemapFeature nodemap.
nameName of feature.
valueExpected value of feature.
igncacheTrue if value is always read from the device, even if cached.

Definition at line 1040 of file config.cc.

◆ convertImage()

bool rcg::convertImage ( uint8_t *  rgb_out,
uint8_t *  mono_out,
const uint8_t *  raw,
uint64_t  pixelformat,
size_t  width,
size_t  height,
size_t  xpadding 
)

Converts image to RGB and monochrome format.

Supported formats can be checked with isFormatSupported().

Parameters
rgb_outPointer to target array for rgb image. The array must have a size of 3*width*height pixel. The pointer can be 0.
mono_outPointer to target array for monochrome image. The array must have a size of width*height pixel. The pointer can be 0.
rawPointer to input pixels.
pixelformatPixel format of input.
widthWidth of image.
heightHeight of image.
xpaddingPadding of input image.
Returns
False, if pixelformat is not supported. In this case, nothing is written to the target pointers.

Definition at line 486 of file image.cc.

◆ convYCbCr411toQuadRGB()

void rcg::convYCbCr411toQuadRGB ( uint8_t  rgb[12],
const uint8_t *  row,
int  i 
)

Conversion of a group of four pixels from YCbCr411 format (6 bytes for four pixels) to RGB.

Conversion of four pixels is a bit more efficient than conversions of individual pixels.

Parameters
rgbPointer to an array of size 3 for storing the result.
rowImage row.
iIndex of first pixel in row that should be converted. The index must be a multiple of 4!

Definition at line 123 of file image.cc.

◆ convYCbCr411toRGB()

void rcg::convYCbCr411toRGB ( uint8_t  rgb[3],
const uint8_t *  row,
int  i 
)

Conversion of one pixel from YCbCr411 format (6 bytes for four pixels) to RGB.

Parameters
rgbPointer to an array of size 3 for storing the result.
rowImage row.
iIndex of pixel in row that should be converted.

Definition at line 99 of file image.cc.

◆ convYCbCr422toQuadRGB()

void rcg::convYCbCr422toQuadRGB ( uint8_t  rgb[12],
const uint8_t *  row,
int  i 
)

Conversion of a group of four pixels from YCbCr422 format (8 bytes for 4 pixels) to RGB.

Conversion of four pixels is a bit more efficient than conversions of individual pixels.

Parameters
rgbPointer to an array of size 3*4 for storing the result.
rowImage row.
iIndex of first pixel in row that should be converted. The index must be a multiple of 4!

Definition at line 163 of file image.cc.

◆ convYCbCr422toRGB()

void rcg::convYCbCr422toRGB ( uint8_t  rgb[3],
const uint8_t *  row,
int  i 
)

Conversion of one pixel from YCbCr422 format (4 bytes for 2 pixels) to RGB.

Parameters
rgbPointer to an array of size 3 for storing the result.
rowImage row.
iIndex of pixel in row that should be converted.

Definition at line 144 of file image.cc.

◆ editNodemap()

bool rcg::editNodemap ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char  root[] 
)

Shows nodemap in a curses gui in the terminal and allows editing of parameters.

Parameters
nodemapNodemap.
rootName of root node, which must be a category.

Definition at line 1126 of file nodemap_edit.cc.

◆ ensureNewFileName()

std::string rcg::ensureNewFileName ( std::string  name)

This method checks if the given file name already exists and produces a new file name if this happens.

Definition at line 60 of file image_store.cc.

◆ formatValue()

std::string rcg::formatValue ( GenApi::IInteger *  node,
int64_t  value 
)

Takes an integer value and formats it according to the specification in the node.

Parameters
nodeNode.
valueInteger value.
Returns
Formated value.

Definition at line 92 of file nodemap_out.cc.

◆ getAvailableGenTLs()

std::vector< std::string > rcg::getAvailableGenTLs ( const char *  paths)

The function uses the given list files of paths that is separated by colons or semicolons, depending on the used operating system, and returns all files with the suffix .cti.

Parameters
Paths,whichmay be 0.
Returns
List of files with suffix cti, including path to that file.

Definition at line 50 of file gentl_wrapper_linux.cc.

◆ getBoolean()

bool rcg::getBoolean ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
bool  exception = false,
bool  igncache = false 
)

Get the value of a boolean feature of the given nodemap.

Parameters
nodemapInitialized nodemap.
nameName of feature.
exceptionTrue if an error should be signaled via exception.
igncacheTrue if value is always read from the device, even if cached.
Returns
Value of boolean feature or false if the feature does not exist, has a different datatype or is not readable.

Definition at line 589 of file config.cc.

◆ getChunkAdapter()

std::shared_ptr< GenApi::CChunkAdapter > rcg::getChunkAdapter ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const std::string &  tltype 
)

NOTE: This function is deprecated.

Instead, enable chunks with ChunkModeActive=true and call Stream::attachBuffers(true).

Sets ChunkModeActive to 1, creates a chunk adapter for the specified transport layer and attaches it to the given nodemap.

The returned chunk adapter must be attached to a buffer that contains chunk data. Thereafter, the data can be accessed through the Chunk* features of the given nodemap. After accessing all required data, the adapter must be detached from the buffer!

Parameters
nodemapFeature nodemap.
tltypeTransport layer type as returned by, e.g. System::getTLType() or Device::getTLType()
Returns
Chunk adapter that is already attached to the given nodemap or null pointer if chunk mode cannot be activated.

Definition at line 1053 of file config.cc.

◆ getColor()

void rcg::getColor ( uint8_t  rgb[3],
const std::shared_ptr< const Image > &  img,
uint32_t  ds,
uint32_t  i,
uint32_t  k 
)

Expects an image in Mono8, RGB8, YCbCr411_8, YCbCr422_8 or YUV422_8 format and returns the color as RGB value at the given pixel location.

The downscale factor ds can be greater than one. In this case, the given pixel location refers to the downscaled image and the returned color is averaged over ds x ds pixels.

Parameters
rgbArray of size 3 for returning the color.
imgPointer to image.
dsDownscale factor, i.e. >= 1
i,kPixel location in downscaled coordinates.

Definition at line 187 of file image.cc.

◆ getComponetOfPart()

std::string rcg::getComponetOfPart ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const Buffer buffer,
uint32_t  ipart 
)

Definition at line 1077 of file config.cc.

◆ getDevice() [1/2]

std::shared_ptr< Device > rcg::getDevice ( const char *  devid,
uint64_t  timeout 
)

Searches across all transport layers and interfaces for a device.

This method accepts optionally specifying the interface ID as prefix, followed by ':', i.e. "[<interfaca_id>[:]]<device_id>". If the interface ID is not given, then all interfaces are sought and the first device with the given ID returned.

Parameters
devidDevice ID.
timeoutTimeout in ms for discovery of devices on each interface. The function without this parameter uses a timeout of 1000 ms.
Returns
Device or null pointer.

Definition at line 726 of file device.cc.

◆ getDevice() [2/2]

std::shared_ptr< Device > rcg::getDevice ( const char *  id)

Definition at line 814 of file device.cc.

◆ getDevices() [1/2]

std::vector< std::shared_ptr< Device > > rcg::getDevices ( )

Definition at line 721 of file device.cc.

◆ getDevices() [2/2]

std::vector< std::shared_ptr< Device > > rcg::getDevices ( uint64_t  timeout)

Returns a list of all devices that are available across all transport layers and interfaces.

Parameters
timeoutTimeout in ms for discovery of devices on each interface. The function without this parameter uses a timeout of 1000 ms.
Returns
List of available devices.

Definition at line 689 of file device.cc.

◆ getEnum() [1/2]

std::string rcg::getEnum ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
bool  exception = false 
)

Get the value of an enumeration of the given nodemap.

Parameters
nodemapInitialized nodemap.
nameName of feature.
exceptionTrue if an error should be signaled via exception.
Returns
Value of enumeration or an empty string if the feature does not exist, has a different datatype or is not readable.

Definition at line 747 of file config.cc.

◆ getEnum() [2/2]

std::string rcg::getEnum ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
std::vector< std::string > &  list,
bool  exception = false 
)

Get the current value and list of possible values of an enumeration of the given nodemap.

Parameters
nodemapInitialized nodemap.
nameName of feature.
listList of possible values.
exceptionTrue if an error should be signaled via exception.
Returns
Value of enumeration or an empty string if the feature does not exist, has a different datatype or is not readable. In this case, the returned list will be empty.

Definition at line 801 of file config.cc.

◆ getFloat()

double rcg::getFloat ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
double *  vmin = 0,
double *  vmax = 0,
bool  exception = false,
bool  igncache = false 
)

Get the value of a double feature of the given nodemap.

Parameters
nodemapInitialized nodemap.
nameName of feature.
vminMinimum value. A null poiter can be given if the value is not required.
vmaxMaximum value. A null poiter can be given if the value is not required.
exceptionTrue if an error should be signaled via exception.
igncacheTrue if value is always read from the device, even if cached.
Returns
Value of feature or 0 if the feature does not exist, has a different datatype or is not readable. In this case vmin and vmax will also be set to 0.

Definition at line 696 of file config.cc.

◆ getInteger()

int64_t rcg::getInteger ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
int64_t vmin = 0,
int64_t vmax = 0,
bool  exception = false,
bool  igncache = false 
)

Get the value of an integer feature of the given nodemap.

Parameters
nodemapInitialized nodemap.
nameName of feature.
vminMinimum value. A null poiter can be given if the value is not required.
vmaxMaximum value. A null poiter can be given if the value is not required.
exceptionTrue if an error should be signaled via exception.
igncacheTrue if value is always read from the device, even if cached.
Returns
Value of feature or 0 if the feature does not exist, has a different datatype or is not readable. In this case vmin and vmax will also be set to 0.

Definition at line 634 of file config.cc.

◆ getRegister()

size_t rcg::getRegister ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
uint8_t *  buffer,
size_t  len,
size_t *  total = 0,
bool  exception = false,
bool  igncache = false 
)

Read value of type register.

Parameters
nodemapInitialized nodemap.
nameName of feature.
bufferBuffer of length len.
lenNumber of bytes to read. This can be 0 if only the size of the register is of interest.
totalTotal size of register. A null pointer can be given if this is not required.
exceptionTrue if an error should be signaled via exception.
igncacheTrue if value is always read from the device, even if cached.
Returns
Number of successfuly read bytes.

Definition at line 865 of file config.cc.

◆ getString()

std::string rcg::getString ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
bool  exception = false,
bool  igncache = false 
)

Get the value of a feature of the given nodemap.

The datatype of the feature can be boolean, integer, float, enum, register or string. The given value will be converted depending on the datatype and representation of the feature, which can be hex, ip4v or mac for an integer feature.

Note: Only the first 32 bytes of registers will be converted and represented in hex.

Parameters
nodemapInitialized nodemap.
nameName of feature.
exceptionTrue if an error should be signaled via exception.
igncacheTrue if value is always read from the device, even if cached.
Returns
Value or an empty string if the feature does not exist, has a different datatype or is not readable.

Definition at line 918 of file config.cc.

◆ isFormatSupported()

bool rcg::isFormatSupported ( uint64_t  pixelformat,
bool  only_color 
)

Returns true if the given pixel format is supported by the convertImage() function.

Currently supported color formats are: RGB8, BayerRG8, BayerBG8, BayerGR8, BayerGB8, YCbCr411_8, YCbCr422_8 and YUV422_8

Currently supported monochrome formats: Mono8, Confidence8, Error8

Parameters
only_colorIf true, the true is returned only for supported color formats.
Returns
True if given pixel format is supported.

Definition at line 690 of file image.cc.

◆ isHostBigEndian()

bool rcg::isHostBigEndian ( )

Definition at line 722 of file buffer.cc.

◆ loadFile()

std::string rcg::loadFile ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
bool  exception = false 
)

Loads the contents of a file via the GenICam FileAccessControl interface.

Parameters
nodemapInitialized nodemap.
nameName of file.
exceptionTrue if an error should be signaled via exception.
Returns
Value or an empty string in case of an error and exception is false.

Definition at line 1159 of file config.cc.

◆ loadStreamableParameters()

bool rcg::loadStreamableParameters ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
bool  exception = false 
)

Load all streamable parameters from file into the nodemap.

Parameters
nodemapInitialized nodemap.
nameName of file from which the streamable parameters can be loaded.
exceptionTrue if an error should be signaled via exception.
Returns
True if the parameters have been loaded successfully. False in case of an error.

Definition at line 1267 of file config.cc.

◆ printNode()

void rcg::printNode ( const std::string &  prefix,
GenApi::INode *  node,
int  depth,
bool  show_enum_list 
)

Recursive printing of nodes to standard out.

Parameters
prefixPrefix that will be prepended to every line.
nodeNode to be printed.
depthThis value is reduced when calling printNode() recursively on category nodes. If the value is <= 0, then no recursion is done.
show_enum_listIf true, all possible enum values of a parameter are printed as well.

Definition at line 121 of file nodemap_out.cc.

◆ printNodemap()

bool rcg::printNodemap ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char  root[],
int  depth = 100,
bool  show_enum_list = true 
)

Printing of nodemap, starting at given root node.

Parameters
nodemapNodemap to be printed.
rootRoot node that will be printed with all child nodes.
depthMaximum depth that will be printed.
show_enum_listIf true, all possible enum values of a parameter are printed as well.
Returns
False if root node cannot be found.

Definition at line 324 of file nodemap_out.cc.

◆ saveFile()

bool rcg::saveFile ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
const std::string &  data,
bool  exception = false 
)

Loads the contents of the given string as a file via the GenICam FileAccessControl interface.

Parameters
nodemapInitialized nodemap.
nameName of file.
dataString with file contents.
exceptionTrue if an error should be signaled via exception.
Returns
True if file has been written successfully. False in case of an error.

Definition at line 1221 of file config.cc.

◆ saveStreamableParameters()

bool rcg::saveStreamableParameters ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
bool  exception = false 
)

Store all streamable parameters from the nodemap into the file.

Parameters
nodemapInitialized nodemap.
nameName of file to which the streamable parameters should be stored.
exceptionTrue if an error should be signaled via exception.
Returns
True if the parameters have been saved successfully. False in case of an error.

Definition at line 1305 of file config.cc.

◆ setBoolean()

bool rcg::setBoolean ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
bool  value,
bool  exception = false 
)

Set the value of a boolean feature of the given nodemap.

Parameters
nodemapInitialized nodemap.
nameName of feature.
valueNew value of feature.
exceptionTrue if an error should be signaled via exception instead of a return value.
Returns
True if value has been changed. False if feature does not exist, has a different datatype or is not writable.

Definition at line 107 of file config.cc.

◆ setEnum()

bool rcg::setEnum ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
const char *  value,
bool  exception = false 
)

Set the value of an enumeration of the given nodemap.

Parameters
nodemapInitialized nodemap.
nameName of feature.
valueNew value of feature.
exceptionTrue if an error should be signaled via exception instead of a return value.
Returns
True if value has been changed. False if feature does not exist, has a different datatype or is not writable.

Definition at line 302 of file config.cc.

◆ setFloat()

bool rcg::setFloat ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
double  value,
bool  exception = false 
)

Set the value of a float feature of the given nodemap.

Parameters
nodemapInitialized nodemap.
nameName of feature.
valueNew value of feature.
exceptionTrue if an error should be signaled via exception instead of a return value.
Returns
True if value has been changed. False if feature does not exist, has a different datatype or is not writable.

Definition at line 256 of file config.cc.

◆ setInteger()

bool rcg::setInteger ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
int64_t  value,
bool  exception = false 
)

Set the value of an integer feature of the given nodemap.

Parameters
nodemapInitialized nodemap.
nameName of feature.
valueNew value of feature.
exceptionTrue if an error should be signaled via exception instead of a return value.
Returns
True if value has been changed. False if feature does not exist, has a different datatype or is not writable.

Definition at line 153 of file config.cc.

◆ setIPV4Address()

bool rcg::setIPV4Address ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
const char *  value,
bool  exception 
)

Set the value of an integer feature of the given nodemap from an IP address.

Parameters
nodemapInitialized nodemap.
nameName of feature.
valueIP address formated as string, i.e. <v0>.<v1>.<v2>.<v3>
exceptionTrue if an error should be signaled via exception instead of a return value.
Returns
True if value has been changed. False if feature does not exist, has a different datatype or is not writable.

Definition at line 199 of file config.cc.

◆ setRegister()

size_t rcg::setRegister ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
const uint8_t *  buffer,
size_t  len,
bool  exception = false 
)

Set value of type register.

Parameters
nodemapInitialized nodemap.
nameName of feature.
bufferBuffer of length len.
lenNumber of bytes to write.
totalTotal size of register. A null pointer can be given if this is not required.
exceptionTrue if an error should be signaled via exception.
Returns
Number of successfuly written bytes.

Definition at line 366 of file config.cc.

◆ setString()

bool rcg::setString ( const std::shared_ptr< GenApi::CNodeMapRef > &  nodemap,
const char *  name,
const char *  value,
bool  exception = false 
)

Set the value of a feature of the given nodemap.

The datatype of the feature can be boolean, integer, float, enum or string. The given value will be converted depending on the datatype and representation of the feature, which can be hex, ip4v or mac for an integer feature.

Parameters
nodemapInitialized nodemap.
nameName of feature.
valueNew value of feature.
exceptionTrue if an error should be signaled via exception instead of a return value.
Returns
True if value has been changed. False if feature does not exist or is not writable or conversion failed.

Definition at line 413 of file config.cc.

◆ storeImage()

std::string rcg::storeImage ( const std::string &  name,
ImgFmt  fmt,
const Image image,
size_t  yoffset = 0,
size_t  height = 0 
)

Stores the given image.

NOTE: An exception that is based on std::exception is thrown in case of an error, e.g. if input or output format is not supported.

Parameters
nameName of output file without suffix.
fmtImage file format.
imageImage to be stored.
yoffsetFirst image row to be stored.
heightNumber of image rows to be stored. 0 means all rows.

Definition at line 567 of file image_store.cc.

◆ storeImageAsDisparityPFM()

std::string rcg::storeImageAsDisparityPFM ( const std::string &  name,
const Image image,
int  inv,
float  scale,
float  offset 
)

Stores the given image as disparity.

The image format must be Coord3D_C16.

NOTE: An exception that is based on std::exception is thrown in case of an error, e.g. if input or output format is not supported.

Parameters
nameName of output file without suffix.
imageImage to be stored.
invValue to mark invalid pixels.
scaleScale factor for valid values.
offsetOffset for valid values.

Definition at line 591 of file image_store.cc.

◆ storePointCloud()

void rcg::storePointCloud ( std::string  name,
double  f,
double  t,
double  scale,
std::shared_ptr< const Image left,
std::shared_ptr< const Image disp,
std::shared_ptr< const Image conf,
std::shared_ptr< const Image error 
)

Definition at line 86 of file pointcloud.cc.



rc_genicam_api
Author(s): Heiko Hirschmueller
autogenerated on Wed Dec 4 2024 03:10:13