HDF5Data
HDF5Data
#include <HDF5_Data.hpp>
Inherits from MediaData, ObserverData
Public Functions
| Name | |
|---|---|
| HDF5Data() =default | |
| virtual MediaType | getMediaType() const override Get the media type of this instance. |
| virtual std::string | GetFrameID(int frame_id) const override |
| virtual int | getFrameIndexFromNumber(int frame_id) override |
Protected Functions
| Name | |
|---|---|
| virtual void | doLoadMedia(std::string const & name) override |
| virtual void | doLoadFrame(int frame_id) override |
Additional inherited members
Public Types inherited from MediaData
| Name | |
|---|---|
| enum class | MediaType { Video, Images, HDF5} |
| enum | DisplayFormat { Gray, Color} |
| using MediaStorage::BitDepth | BitDepth |
| using MediaStorage::ImageDataVariant | DataStorage |
Public Functions inherited from MediaData
| Name | |
|---|---|
| MediaData() | |
| virtual | ~MediaData() |
| std::string | getFilename() const |
| void | setFilename(std::string const & filename) |
| void | setFormat(DisplayFormat format) |
| DisplayFormat | getFormat() const |
| int | getHeight() const |
| int | getWidth() const |
| ImageSize | getImageSize() const |
| void | updateHeight(int height) |
| void | updateWidth(int width) |
| int | getTotalFrameCount() const |
| void | setTotalFrameCount(int total_frame_count) |
| BitDepth | getBitDepth() const Get the current bit depth of the media data. |
| void | setBitDepth(BitDepth depth) Set the bit depth (can be used to override auto-detected depth). |
| bool | is8Bit() const Check if the media data is using 8-bit storage. |
| bool | is32Bit() const Check if the media data is using 32-bit float storage. |
| void | LoadMedia(std::string const & name) LoadMedia. |
| void | LoadFrame(int frame_id) LoadFrame. |
| std::vector< uint8_t > const & | getRawData8(int frame_number) Get raw data as uint8_t (for 8-bit data or converted from 32-bit). |
| std::vector< float > const & | getRawData32(int frame_number) Get raw data as float (for 32-bit data or converted from 8-bit). |
| std::vector< uint8_t > | getProcessedData8(int frame_number) Get processed data as uint8_t (for 8-bit data or converted from 32-bit). |
| std::vector< float > | getProcessedData32(int frame_number) Get processed data as float (for 32-bit data or converted from 8-bit). |
| DataStorage const & | getRawDataVariant(int frame_number) Get raw data as variant (native format). |
| DataStorage | getProcessedDataVariant(int frame_number) Get processed data as variant (native format). |
| std::vector< uint8_t > const & | getRawData(int frame_number) Legacy method - get raw data (defaults to 8-bit behavior for compatibility). |
| std::vector< uint8_t > | getProcessedData(int frame_number) Legacy method - get processed data (defaults to 8-bit behavior for compatibility). |
| void | setRawData(MediaStorage::ImageData8 data) Set raw data from uint8_t vector. |
| void | setRawData(MediaStorage::ImageData32 data) Set raw data from float vector (normalized to 0-255 range). |
| bool | setImageProcessor(std::string const & processor_name) Set the image processor backend (e.g., “opencv”, “simd”, etc.). |
| std::string | getImageProcessorName() const Get the current image processor backend name. |
| void | addProcessingStep(std::string const & key, std::function< void(void *)> processor) Add a processing step using the current processor. |
| void | removeProcessingStep(std::string const & key) Remove a processing step. |
| void | clearProcessingSteps() Clear all processing steps. |
| bool | hasProcessingStep(std::string const & key) const Check if a processing step exists. |
| size_t | getProcessingStepCount() const Get the number of processing steps. |
| void | setTimeFrame(std::shared_ptr< TimeFrame > time_frame) Set the time frame. |
| std::shared_ptr< TimeFrame > | getTimeFrame() const |
Public Classes inherited from ObserverData
| Name | |
|---|---|
| struct | ObserverEntry Entry in the observer map. |
Public Types inherited from ObserverData
| Name | |
|---|---|
| using std::function< void()> | ObserverCallback Type alias for observer callback functions. |
| using int | CallbackID Type alias for callback identifiers. |
Public Functions inherited from ObserverData
| Name | |
|---|---|
| ObserverData(std::string name =“UnnamedObservable”) | |
| CallbackID | addObserver(ObserverCallback callback, std::string name =“Anonymous”) Register a new observer callback. |
| void | notifyObservers() Notify all registered observers. |
| void | removeObserver(CallbackID id) Remove a previously registered observer. |
Public Functions Documentation
function HDF5Data
HDF5Data() =defaultfunction getMediaType
inline virtual MediaType getMediaType() const overrideGet the media type of this instance.
Return: The MediaType enum value
Reimplements: MediaData::getMediaType
function GetFrameID
virtual std::string GetFrameID(
int frame_id
) const overrideReimplements: MediaData::GetFrameID
function getFrameIndexFromNumber
inline virtual int getFrameIndexFromNumber(
int frame_id
) overrideReimplements: MediaData::getFrameIndexFromNumber
Protected Functions Documentation
function doLoadMedia
virtual void doLoadMedia(
std::string const & name
) overrideReimplements: MediaData::doLoadMedia
function doLoadFrame
virtual void doLoadFrame(
int frame_id
) overrideReimplements: MediaData::doLoadFrame
Updated on 2026-11-13 at 20:25:40 +0000