29 #ifndef NVXIO_FRAMESOURCE_HPP
30 #define NVXIO_FRAMESOURCE_HPP
126 virtual bool open() = 0;
159 virtual void close() = 0;
234 #endif // NVXIO_FRAMESOURCE_HPP
struct _vx_image * vx_image
An opaque reference to an image.
Indicates a timeout has been exceeded.
FrameSource(FrameSource::SourceType type=FrameSource::UNKNOWN_SOURCE, const std::string &name="Undefined")
std::string getSourceName() const
Returns the source name of the FrameSource.
Indicates a sequence of images.
FrameStatus
Defines the status of read operations.
Indicates a single image.
struct _vx_context * vx_context
An opaque reference to the implementation context.
Indicates an unknown source.
vx_uint32 frameHeight
Holds the height of the frame.
uint32_t vx_df_image
Used to hold a VX_DF_IMAGE code to describe the pixel format and color space.
A single plane of 24-bit pixel as 3 interleaved 8-bit units of R then G then B data. This uses the BT709 full range by default.
virtual void close()=0
Closes the FrameSource.
A single plane of 32-bit pixel as 4 interleaved 8-bit units of R then G then B data, then a don't care byte. This uses the BT709 full range by default.
Indicates the frame source has been closed.
virtual FrameSource::Parameters getConfiguration()=0
Gets the configuration of the FrameSource.
vx_image loadImageFromFile(vx_context context, const std::string &fileName, vx_df_image format=VX_DF_IMAGE_RGB)
Loads image from file into OpenVX Image object.
The top level OpenVX Header.
Indicates the frame has been read successfully.
std::unique_ptr< FrameSource > createDefaultFrameSource(vx_context context, const std::string &uri)
FrameSource interface factory that provides appropriate implementation by source URI.
const std::string sourceName
uint32_t vx_uint32
A 32-bit unsigned value.
vx_uint32 fps
Holds the FPS (for video only).
virtual FrameSource::FrameStatus fetch(vx_image image, vx_uint32 timeout=5)=0
Fetches frames from the source.
virtual ~FrameSource()
Destructor.
virtual bool open()=0
Opens the FrameSource.
SourceType
Defines the type of source.
const FrameSource::SourceType sourceType
vx_df_image format
Holds the format of the frame.
virtual bool setConfiguration(const FrameSource::Parameters ¶ms)=0
Sets the configuration of the FrameSource.
vx_uint32 frameWidth
Holds the width of the frame.
FrameSource::SourceType getSourceType() const
Returns the source type of the FrameSource.