Tekkotsu Homepage
Demos
Overview
Downloads
Dev. Resources
Reference
Credits

ImageHeader Struct Reference

This structure should be written into the beginning of each image buffer sent via setImage(). More...

#include <DataSource.h>


Detailed Description

This structure should be written into the beginning of each image buffer sent via setImage().

Using "placement new" avoids doing a memcpy: new (buffer) ImageHeader(...);
If you are storing a visual image to be processed by the pipeline (vs. a laser rangefinder sweep or such), then values should be interleaved YUV samples.

Definition at line 108 of file DataSource.h.

List of all members.

Public Member Functions

 ImageHeader (unsigned int sourceID_, int layer_, unsigned int width_, unsigned int height_, unsigned int components_, unsigned int frameNumber_, unsigned int timestamp_, const std::string &name_)
 full constructor, see corresponding members for documentation on arguments

Public Attributes

unsigned int sourceID
 In order to support multiple cameras, this tracks how to identify the cameras within Tekkotsu. You should allow users to configure the value you store here.
int layer
 the resolution layer for this image, if 0 then automatically chooses the closest in size based on expected values in RobotInfo namespace. Otherwise should be presented as a configuration item.
unsigned int width
 pixels per row of image
unsigned int height
 pixels per column of image
unsigned int components
 number of color channels, vision pipeline expects 3 for YUV images.
unsigned int frameNumber
 serial number per image sent, provides user notification for dropped images if the SharedGlobals::StreamSimConfig::verbose flag is set
unsigned int timestamp
 timestamp image was recorded
char name [MAX_NAME_LEN]
 a user identifiable name for the image... see DataSource::nextName()

Static Public Attributes

static const unsigned int MAX_NAME_LEN = 64
 maximum length of name

Constructor & Destructor Documentation

ImageHeader ( unsigned int  sourceID_,
int  layer_,
unsigned int  width_,
unsigned int  height_,
unsigned int  components_,
unsigned int  frameNumber_,
unsigned int  timestamp_,
const std::string &  name_ 
)

full constructor, see corresponding members for documentation on arguments

Definition at line 110 of file DataSource.h.


Member Data Documentation

unsigned int components

number of color channels, vision pipeline expects 3 for YUV images.

Definition at line 117 of file DataSource.h.

Referenced by Main::gotCamera(), and DataSource::setImage().

unsigned int frameNumber

serial number per image sent, provides user notification for dropped images if the SharedGlobals::StreamSimConfig::verbose flag is set

Definition at line 119 of file DataSource.h.

Referenced by Main::gotCamera().

unsigned int height

pixels per column of image

Definition at line 116 of file DataSource.h.

Referenced by Main::gotCamera(), and DataSource::setImage().

int layer

the resolution layer for this image, if 0 then automatically chooses the closest in size based on expected values in RobotInfo namespace. Otherwise should be presented as a configuration item.

Definition at line 114 of file DataSource.h.

Referenced by Main::gotCamera().

const unsigned int MAX_NAME_LEN = 64 [static]

maximum length of name

Definition at line 121 of file DataSource.h.

Referenced by ImageHeader::ImageHeader().

a user identifiable name for the image... see DataSource::nextName()

Definition at line 122 of file DataSource.h.

Referenced by Main::gotCamera(), and ImageHeader::ImageHeader().

unsigned int sourceID

In order to support multiple cameras, this tracks how to identify the cameras within Tekkotsu. You should allow users to configure the value you store here.

Definition at line 113 of file DataSource.h.

Referenced by Main::gotCamera().

unsigned int timestamp

timestamp image was recorded

Definition at line 120 of file DataSource.h.

unsigned int width

pixels per row of image

Definition at line 115 of file DataSource.h.

Referenced by Main::gotCamera(), and DataSource::setImage().


The documentation for this struct was generated from the following file:

Tekkotsu Hardware Abstraction Layer 5.1CVS
Generated Mon May 9 05:01:41 2016 by Doxygen 1.6.3