The "peak" namespace directly contains convenience functionality like the DeviceManager as well as the global Library::Initialize() / Library::Close() functions, which must be called before/after usage of the library.
More...
|
| namespace | core |
| | The "core" namespace contains the direct GenAPI and GenTL wrapper.
|
| |
| namespace | dynamic |
| |
The "peak" namespace directly contains convenience functionality like the DeviceManager as well as the global Library::Initialize() / Library::Close() functions, which must be called before/after usage of the library.
◆ BufferPartTo() [1/2]
Converts a core::BufferPart into a different type.
This function converts the buffer part into the format requested as template argument. Implement a template specialization for your custom data type yourself. For an example, have a look at the implementation to convert the buffer part to a peak::ipl::Image, i.e. see file converters/peak_bufferpart_converter_ipl.hpp.
Usage:
auto image = peak::BufferPartTo<CustomImageType>(bufferPart);
- Parameters
-
- Returns
- Image data in the requested image container/class.
- Since
- 1.8
- Exceptions
-
| InvalidArgumentException | The given buffer part is invalid. |
| InvalidCastException | The given buffer part can not be casted to the requested OutType. |
| InternalErrorException | An internal error has occurred. |
◆ BufferPartTo() [2/2]
Converts a core::BufferPart into a peak::ipl::Image.
This creates a peak::ipl::Image as a shallow copy of the buffer (i.e. using the same memory).
- Parameters
-
| [in] | part | The buffer part to convert |
- Returns
- The buffer part converted to an Image.
- Since
- 1.8
- Note
- To use this method, this file needs to be included explicitly:
◆ BufferTo()
Converts a core::Buffer into a different type.
This function converts the buffer into the format requested as template argument. Implement a template specialization for your custom data type yourself. For an example, have a look at the implementation to convert the buffer to a peak::ipl::Image, i.e. see file converters/peak_buffer_converter_ipl.hpp.
Usage:
auto image = peak::BufferTo<CustomImageType>(buffer);
- Parameters
-
- Returns
- Image data in the requested image container/class.
- Since
- 1.0
- Exceptions
-
| InvalidArgumentException | The given buffer is invalid. |
| InternalErrorException | An internal error has occurred. |
◆ BufferTo< peak::ipl::Image >()
Converts a core::Buffer into a peak::ipl::Image.
This creates a peak::ipl::Image as a shallow copy of the buffer (i.e. using the same memory).
- Parameters
-
| [in] | buffer | The buffer to convert |
- Returns
- The buffer converted to an Image.
- Note
- To use this method, this file needs to be included explicitly: