Time-of-Flight Library(ToF) 3.13.4
 
chronoptics::tof::GigeInterface Class Reference

DEPRECATED, use KeaCamera. More...

#include <gige_interface.hpp>

+ Inheritance diagram for chronoptics::tof::GigeInterface:

Public Member Functions

 GigeInterface (tof_gige_interface_t ptr)
 Construct from pointer.
 
 GigeInterface (uint16_t port=0)
 Create an instance of the gige interface.
 
std::vector< DiscoveryMessagediscover ()
 Detect all the cameras on the network.
 
DiscoveryMessage discover_one ()
 Returns a message of the first camera that responded.
 
DiscoveryMessage find (StringView serial)
 Detect a specific camera on the network, will throw an error if it can't find the camera.
 
void connect (const DiscoveryMessage &message)
 Connect to the camera and gain exclusive access.
 
void disconnect ()
 Disconnect from the camera.
 
bool is_connected () const
 Check whether a connection is still maintained with the camera.
 
uint16_t get_stream_packet_size () const
 Get stream packet size.
 
void set_stream_packet_size (uint16_t packet_size)
 Set stream packet size.
 
bool test_stream_packet_size (uint16_t port=0)
 Test whether using the set packet size works.
 
uint32_t get_delay () const
 Get delay between network packets.
 
void set_delay (uint32_t delay)
 Set delay between network packets.
 
CameraConfig download_configuration (uint16_t port=0)
 Download camera configuration from the camera.
 
Calibration download_calibration (uint16_t port=0)
 Download calibration from the camera.
 
void upload_configuration (const CameraConfig &config, uint16_t port=0)
 Upload camera configuration to the camera.
 
bool depth_stream_capable (DepthStreamType stream) const
 Check whether this camera is capable of streaming the specified type.
 
void start_depth_stream (DepthStreamType stream, uint16_t port=0)
 Start the depth stream.
 
void stop_depth_stream ()
 Stop the depth stream.
 
bool has_depth_data () const
 Returns true if a depth frame is available.
 
Data get_depth_data ()
 Get a depth frame.
 
bool image_stream_capable () const
 Check whether camera supports an image stream.
 
void start_image_stream (uint16_t port=0)
 Start image stream.
 
void stop_image_stream ()
 Stop image stream.
 
bool has_image_data () const
 Check whether image frame is available.
 
Data get_image_data ()
 Get image frame.
 
Data get_image_data_into_pointer (uint8_t *pointer, size_t capacity, user_pointer_destructed_fn &callback)
 Get the image frame into the supplied pointer.
 
Data get_image_data_into_pointer (uint8_t *pointer, size_t capacity, tof_user_pointer_destructed_t callback, void *callback_user_data)
 Get the image frame into the supplied pointer.
 
bool persistent_ip_capable () const
 Get whether the camera is persistent ip capable.
 
PersistentIp get_persistent_ip () const
 Get the current persistent ip settings.
 
void set_persistent_ip (const PersistentIp &persistent_ip)
 Set the persistent ip settings.
 
size_t get_user_pointer_capacity () const
 Get the capacity for amount of user pointers that can be registered.
 
void set_user_pointer_capacity (size_t capacity)
 Set the capacity for amount of user pointers that can be registered.
 
void add_depth_user_pointer (uint8_t *pointer, size_t capacity, user_pointer_destructed_fn &callback)
 Add a pointer that will be filled with depth data.
 
void add_depth_user_pointer (uint8_t *pointer, size_t capacity, tof_user_pointer_destructed_t callback, void *callback_user_data)
 Add a pointer that will be filled with depth data.
 
const char * version ()
 Get the tof library version running on the camera.
 
bool software_trigger_capable ()
 Check whether the camera is capable of software trigger.
 
void software_trigger ()
 Software trigger the camera.
 

Detailed Description

DEPRECATED, use KeaCamera.

Connect to a camera directly using the gige interface

Definition at line 127 of file gige_interface.hpp.

Constructor & Destructor Documentation

◆ GigeInterface() [1/2]

chronoptics::tof::GigeInterface::GigeInterface ( tof_gige_interface_t  ptr)
inline

Construct from pointer.

Definition at line 130 of file gige_interface.hpp.

◆ GigeInterface() [2/2]

chronoptics::tof::GigeInterface::GigeInterface ( uint16_t  port = 0)
inline

Create an instance of the gige interface.

Parameters
portThe port to use for GVCP communication, if 0 is specified it will use an OS assigned port

Definition at line 138 of file gige_interface.hpp.

Member Function Documentation

◆ add_depth_user_pointer() [1/2]

void chronoptics::tof::GigeInterface::add_depth_user_pointer ( uint8_t *  pointer,
size_t  capacity,
tof_user_pointer_destructed_t  callback,
void *  callback_user_data 
)
inline

Add a pointer that will be filled with depth data.

This method allows you to fill data straight into your own data structure without any additional copying.

Parameters
pointerThe pointer to the data to write into
capacityThe amount of data the pointer can hold
callbackCallback that will be called when pointer is no longer in use
callback_user_dataUser data that will be passed back when the function pointer is called

Definition at line 431 of file gige_interface.hpp.

◆ add_depth_user_pointer() [2/2]

void chronoptics::tof::GigeInterface::add_depth_user_pointer ( uint8_t *  pointer,
size_t  capacity,
user_pointer_destructed_fn &  callback 
)
inline

Add a pointer that will be filled with depth data.

This method allows you to fill data straight into your own data structure without any additional copying.

Parameters
pointerThe pointer to the data to write into
capacityThe amount of data the pointer can hold
callbackCallback that will be called when pointer is no longer in use

Definition at line 418 of file gige_interface.hpp.

◆ connect()

void chronoptics::tof::GigeInterface::connect ( const DiscoveryMessage message)
inline

Connect to the camera and gain exclusive access.

Parameters
messageDiscovery message of the camera to connect to

Definition at line 181 of file gige_interface.hpp.

◆ depth_stream_capable()

bool chronoptics::tof::GigeInterface::depth_stream_capable ( DepthStreamType  stream) const
inline

Check whether this camera is capable of streaming the specified type.

Parameters
streamDepth stream type
Returns
Is capable

Definition at line 270 of file gige_interface.hpp.

◆ disconnect()

void chronoptics::tof::GigeInterface::disconnect ( )
inline

Disconnect from the camera.

Definition at line 187 of file gige_interface.hpp.

◆ discover()

std::vector< DiscoveryMessage > chronoptics::tof::GigeInterface::discover ( )
inline

Detect all the cameras on the network.

Returns
A list of discovery messages

Definition at line 145 of file gige_interface.hpp.

◆ discover_one()

DiscoveryMessage chronoptics::tof::GigeInterface::discover_one ( )
inline

Returns a message of the first camera that responded.

Returns
A discovery message

Definition at line 159 of file gige_interface.hpp.

◆ download_calibration()

Calibration chronoptics::tof::GigeInterface::download_calibration ( uint16_t  port = 0)
inline

Download calibration from the camera.

Parameters
portPort to download configuration on
Returns
Calibration

Definition at line 251 of file gige_interface.hpp.

◆ download_configuration()

CameraConfig chronoptics::tof::GigeInterface::download_configuration ( uint16_t  port = 0)
inline

Download camera configuration from the camera.

Parameters
portPort to download configuration on
Returns
Camera configuration

Definition at line 240 of file gige_interface.hpp.

◆ find()

DiscoveryMessage chronoptics::tof::GigeInterface::find ( StringView  serial)
inline

Detect a specific camera on the network, will throw an error if it can't find the camera.

Parameters
serialSerial number of camera to find
Returns
A discovery message

Definition at line 171 of file gige_interface.hpp.

◆ get_delay()

uint32_t chronoptics::tof::GigeInterface::get_delay ( ) const
inline

Get delay between network packets.

Returns
The delay, depending on the camera software it is in nanoseconds or in cpu instruction

Definition at line 224 of file gige_interface.hpp.

◆ get_depth_data()

Data chronoptics::tof::GigeInterface::get_depth_data ( )
inline

Get a depth frame.

Returns
Depth frame

Definition at line 298 of file gige_interface.hpp.

◆ get_image_data()

Data chronoptics::tof::GigeInterface::get_image_data ( )
inline

Get image frame.

Returns
Image data

Definition at line 335 of file gige_interface.hpp.

◆ get_image_data_into_pointer() [1/2]

Data chronoptics::tof::GigeInterface::get_image_data_into_pointer ( uint8_t *  pointer,
size_t  capacity,
tof_user_pointer_destructed_t  callback,
void *  callback_user_data 
)
inline

Get the image frame into the supplied pointer.

Parameters
pointerThe pointer to the data to write into
capacityThe amount of data the pointer can hold
callbackCallback that will be called when pointer is no longer in use
callback_user_dataUser data that will be passed back when the function pointer is called
Returns
Image data

Definition at line 364 of file gige_interface.hpp.

◆ get_image_data_into_pointer() [2/2]

Data chronoptics::tof::GigeInterface::get_image_data_into_pointer ( uint8_t *  pointer,
size_t  capacity,
user_pointer_destructed_fn &  callback 
)
inline

Get the image frame into the supplied pointer.

Parameters
pointerThe pointer to the data to write into
capacityThe amount of data the pointer can hold
callbackCallback that will be called when pointer is no longer in use
Returns
Image data

Definition at line 349 of file gige_interface.hpp.

◆ get_persistent_ip()

PersistentIp chronoptics::tof::GigeInterface::get_persistent_ip ( ) const
inline

Get the current persistent ip settings.

Returns
Persistent IP

Definition at line 381 of file gige_interface.hpp.

◆ get_stream_packet_size()

uint16_t chronoptics::tof::GigeInterface::get_stream_packet_size ( ) const
inline

Get stream packet size.

Returns
The packet size

Definition at line 201 of file gige_interface.hpp.

◆ get_user_pointer_capacity()

size_t chronoptics::tof::GigeInterface::get_user_pointer_capacity ( ) const
inline

Get the capacity for amount of user pointers that can be registered.

Returns
User pointer capacity

Definition at line 399 of file gige_interface.hpp.

◆ has_depth_data()

bool chronoptics::tof::GigeInterface::has_depth_data ( ) const
inline

Returns true if a depth frame is available.

Returns
Depth frame available

Definition at line 291 of file gige_interface.hpp.

◆ has_image_data()

bool chronoptics::tof::GigeInterface::has_image_data ( ) const
inline

Check whether image frame is available.

Returns
Image frame available

Definition at line 328 of file gige_interface.hpp.

◆ image_stream_capable()

bool chronoptics::tof::GigeInterface::image_stream_capable ( ) const
inline

Check whether camera supports an image stream.

Returns
Camera supports an image stream

Definition at line 308 of file gige_interface.hpp.

◆ is_connected()

bool chronoptics::tof::GigeInterface::is_connected ( ) const
inline

Check whether a connection is still maintained with the camera.

Returns
Is connected

Definition at line 194 of file gige_interface.hpp.

◆ persistent_ip_capable()

bool chronoptics::tof::GigeInterface::persistent_ip_capable ( ) const
inline

Get whether the camera is persistent ip capable.

Returns
Persistent IP capable

Definition at line 374 of file gige_interface.hpp.

◆ set_delay()

void chronoptics::tof::GigeInterface::set_delay ( uint32_t  delay)
inline

Set delay between network packets.

Parameters
delayThe delay, depending on the camera software it is in nanoseconds or in cpu instruction

Definition at line 232 of file gige_interface.hpp.

◆ set_persistent_ip()

void chronoptics::tof::GigeInterface::set_persistent_ip ( const PersistentIp persistent_ip)
inline

Set the persistent ip settings.

The persistent ip settings will be active on next reboot.

Parameters
persistent_ipThe persistent ip

Definition at line 392 of file gige_interface.hpp.

◆ set_stream_packet_size()

void chronoptics::tof::GigeInterface::set_stream_packet_size ( uint16_t  packet_size)
inline

Set stream packet size.

Parameters
packet_sizeThe packet size

Definition at line 208 of file gige_interface.hpp.

◆ set_user_pointer_capacity()

void chronoptics::tof::GigeInterface::set_user_pointer_capacity ( size_t  capacity)
inline

Set the capacity for amount of user pointers that can be registered.

Parameters
capacityUser pointer capacity

Definition at line 406 of file gige_interface.hpp.

◆ software_trigger()

void chronoptics::tof::GigeInterface::software_trigger ( )
inline

Software trigger the camera.

Definition at line 451 of file gige_interface.hpp.

◆ software_trigger_capable()

bool chronoptics::tof::GigeInterface::software_trigger_capable ( )
inline

Check whether the camera is capable of software trigger.

Returns
Software trigger capable

Definition at line 445 of file gige_interface.hpp.

◆ start_depth_stream()

void chronoptics::tof::GigeInterface::start_depth_stream ( DepthStreamType  stream,
uint16_t  port = 0 
)
inline

Start the depth stream.

Parameters
streamDepth stream type
portPort to receive depth data on

Definition at line 278 of file gige_interface.hpp.

◆ start_image_stream()

void chronoptics::tof::GigeInterface::start_image_stream ( uint16_t  port = 0)
inline

Start image stream.

Parameters
portPort to receive image data on

Definition at line 315 of file gige_interface.hpp.

◆ stop_depth_stream()

void chronoptics::tof::GigeInterface::stop_depth_stream ( )
inline

Stop the depth stream.

Definition at line 284 of file gige_interface.hpp.

◆ stop_image_stream()

void chronoptics::tof::GigeInterface::stop_image_stream ( )
inline

Stop image stream.

Definition at line 321 of file gige_interface.hpp.

◆ test_stream_packet_size()

bool chronoptics::tof::GigeInterface::test_stream_packet_size ( uint16_t  port = 0)
inline

Test whether using the set packet size works.

Parameters
portPort to send test packets to
Returns
Packet size works

Definition at line 216 of file gige_interface.hpp.

◆ upload_configuration()

void chronoptics::tof::GigeInterface::upload_configuration ( const CameraConfig config,
uint16_t  port = 0 
)
inline

Upload camera configuration to the camera.

Parameters
configCamera configuration
portPort to download configuration on

Definition at line 262 of file gige_interface.hpp.

◆ version()

const char * chronoptics::tof::GigeInterface::version ( )
inline

Get the tof library version running on the camera.

Returns
Version

Definition at line 438 of file gige_interface.hpp.