Public Member Functions | Private Member Functions | Private Attributes
rcg::Stream Class Reference

#include <stream.h>

List of all members.

Public Member Functions

void close ()
size_t getBufAlignment () const
size_t getBufAnnounceMin () const
bool getDefinesPayloadsize () const
void * getHandle () const
const std::string & getID () const
bool getIsGrabbing () const
std::shared_ptr
< GenApi::CNodeMapRef
getNodeMap ()
size_t getNumAnnounced () const
size_t getNumAwaitDelivery () const
size_t getNumChunksMax () const
uint64_t getNumDelivered () const
size_t getNumQueued () const
uint64_t getNumStarted () const
uint64_t getNumUnderrun () const
std::shared_ptr< DevicegetParent () const
size_t getPayloadSize () const
std::string getTLType () const
const Buffergrab (int64_t timeout=-1)
void open ()
void startStreaming (int na=-1)
void stopStreaming ()
 Stream (const std::shared_ptr< Device > &parent, const std::shared_ptr< const GenTLWrapper > &gentl, const char *id)
 ~Stream ()

Private Member Functions

Streamoperator= (const Stream &)
 Stream (class Stream &)

Private Attributes

size_t bn
Buffer buffer
std::shared_ptr< CPortcport
void * event
std::shared_ptr< const
GenTLWrapper
gentl
std::string id
int n_open
std::shared_ptr
< GenApi::CNodeMapRef
nodemap
std::shared_ptr< Deviceparent
void * stream

Detailed Description

The stream class encapsulates a Genicam stream.

NOTE: A GenTLException is thrown in case of a severe error.

Definition at line 53 of file stream.h.


Constructor & Destructor Documentation

rcg::Stream::Stream ( const std::shared_ptr< Device > &  parent,
const std::shared_ptr< const GenTLWrapper > &  gentl,
const char *  id 
)

Constructs a stream class. Streams must only be created by the device class.

Definition at line 47 of file stream.cc.

Definition at line 61 of file stream.cc.

rcg::Stream::Stream ( class Stream ) [private]

Member Function Documentation

Closes the stream. Each call of open() must be followed by a call to close() at some point in time.

Definition at line 107 of file stream.cc.

size_t rcg::Stream::getBufAlignment ( ) const

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Buffer alignment in bytes.

Definition at line 425 of file stream.cc.

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Min number of buffers to announce before acq can start, if known.

Definition at line 420 of file stream.cc.

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Flag that indicated that this data stream defines a payload size independent from the remote device.

Definition at line 387 of file stream.cc.

void * rcg::Stream::getHandle ( ) const

Get internal stream handle.

Returns:
Internal handle.

Definition at line 441 of file stream.cc.

const std::string & rcg::Stream::getID ( ) const

Get the internal ID of this stream.

Returns:
ID.

Definition at line 81 of file stream.cc.

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Flag indicating whether the acquisition engine is started or not.

Definition at line 382 of file stream.cc.

Returns the node map of this object.

NOTE: open() must be called before calling this method. The returned pointer remains valid until close() of this object is called.

Returns:
Node map of this object.

Definition at line 430 of file stream.cc.

size_t rcg::Stream::getNumAnnounced ( ) const

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Number of announced buffers.

Definition at line 357 of file stream.cc.

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Number of buffers in the output queue.

Definition at line 367 of file stream.cc.

size_t rcg::Stream::getNumChunksMax ( ) const

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Max number of chunks in a buffer, if known.

Definition at line 415 of file stream.cc.

uint64_t rcg::Stream::getNumDelivered ( ) const

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Number of delivered buffers since last acquisition start.

Definition at line 347 of file stream.cc.

size_t rcg::Stream::getNumQueued ( ) const

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Number of buffers in the input pool.

Definition at line 362 of file stream.cc.

uint64_t rcg::Stream::getNumStarted ( ) const

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Number of buffers started in the acquisition engine.

Definition at line 372 of file stream.cc.

uint64_t rcg::Stream::getNumUnderrun ( ) const

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Number of lost buffers due to queue underrun.

Definition at line 352 of file stream.cc.

std::shared_ptr< Device > rcg::Stream::getParent ( ) const

Returns the pointer to the parent device object.

Returns:
Pointer to parent device object.

Definition at line 76 of file stream.cc.

size_t rcg::Stream::getPayloadSize ( ) const

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Size of the expected data in bytes.

Definition at line 377 of file stream.cc.

std::string rcg::Stream::getTLType ( ) const

Returns some information about the stream.

NOTE: open() must have called before calling this method.

Returns:
Transport layer technology that is supported.

Definition at line 392 of file stream.cc.

const Buffer * rcg::Stream::grab ( int64_t  timeout = -1)

Wait for the next image or data and return it in a buffer object. The buffer is valid until the next call to grab.

Parameters:
timeoutTimeout in ms. A value < 0 sets waiting time to infinite.
Returns:
Pointer to received buffer or 0 in case of an error or interrupt.

Definition at line 255 of file stream.cc.

Opens the stream for working with it. The stream may be opened multiple times. However, for each open(), the close() method must be called as well.

Definition at line 86 of file stream.cc.

Stream& rcg::Stream::operator= ( const Stream ) [private]
void rcg::Stream::startStreaming ( int  na = -1)

Allocates buffers and registers internal events if necessary and starts streaming.

Parameters:
naNumber of buffers to acquire. Set <= 0 for infinity.

Definition at line 125 of file stream.cc.

Stops streaming.

Definition at line 227 of file stream.cc.


Member Data Documentation

size_t rcg::Stream::bn [private]

Definition at line 287 of file stream.h.

Definition at line 278 of file stream.h.

std::shared_ptr<CPort> rcg::Stream::cport [private]

Definition at line 289 of file stream.h.

void* rcg::Stream::event [private]

Definition at line 286 of file stream.h.

std::shared_ptr<const GenTLWrapper> rcg::Stream::gentl [private]

Definition at line 281 of file stream.h.

std::string rcg::Stream::id [private]

Definition at line 282 of file stream.h.

int rcg::Stream::n_open [private]

Definition at line 284 of file stream.h.

std::shared_ptr<GenApi::CNodeMapRef> rcg::Stream::nodemap [private]

Definition at line 290 of file stream.h.

std::shared_ptr<Device> rcg::Stream::parent [private]

Definition at line 280 of file stream.h.

void* rcg::Stream::stream [private]

Definition at line 285 of file stream.h.


The documentation for this class was generated from the following files:


rc_visard_driver
Author(s): Heiko Hirschmueller , Christian Emmerich , Felix Ruess
autogenerated on Thu Jun 6 2019 20:43:12