Public Member Functions | Private Attributes | List of all members
aditof::FrameHandler Class Reference

Handles operations on a frame such as saving it to file and creating a new frame with content read from file. More...

#include <frame_handler.h>

Public Member Functions

SDK_API FrameHandler ()
 
SDK_API FrameHandler (FrameHandler &&) noexcept
 Move constructor. More...
 
SDK_API FrameHandleroperator= (FrameHandler &&) noexcept
 Move assignment. More...
 
SDK_API aditof::Status readNextFrame (aditof::Frame &frame, const std::string &fullFileName="")
 Reads frame from a file. If same file is provided it will continue to read from the last position. More...
 
SDK_API aditof::Status saveFrameToFile (aditof::Frame &frame, const std::string &fileName="")
 Store frame to file. More...
 
SDK_API aditof::Status saveFrameToFileMultithread (aditof::Frame &frame, const std::string &fileName="")
 Store frame to file using a separate thread. More...
 
SDK_API aditof::Status setCustomFormat (const std::string &format)
 A custom format in which the frames will be stored/read. More...
 
SDK_API aditof::Status setFrameContent (const std::string &frameContent)
 Set which frame element you want to store/read (depth/ab/conf) More...
 
SDK_API aditof::Status setInputFileName (const std::string &fullFileName)
 Set the input file for the frames. More...
 
SDK_API aditof::Status setOutputFilePath (const std::string &filePath)
 Set the output path/output folder for the frames. More...
 
SDK_API aditof::Status storeFramesToSingleFile (bool enable)
 Enable/disable if single file is intended to use for storing data. More...
 
SDK_API ~FrameHandler ()
 

Private Attributes

std::unique_ptr< FrameHandlerImplm_impl
 

Detailed Description

Handles operations on a frame such as saving it to file and creating a new frame with content read from file.

Definition at line 57 of file frame_handler.h.

Constructor & Destructor Documentation

◆ FrameHandler() [1/2]

FrameHandler::FrameHandler ( )

Definition at line 43 of file frame_handler.cpp.

◆ ~FrameHandler()

FrameHandler::~FrameHandler ( )
default

◆ FrameHandler() [2/2]

FrameHandler::FrameHandler ( FrameHandler &&  )
defaultnoexcept

Move constructor.

Member Function Documentation

◆ operator=()

FrameHandler & FrameHandler::operator= ( FrameHandler &&  )
defaultnoexcept

Move assignment.

◆ readNextFrame()

Status FrameHandler::readNextFrame ( aditof::Frame frame,
const std::string fullFileName = "" 
)

Reads frame from a file. If same file is provided it will continue to read from the last position.

Parameters
[out]frame- Frame object in which the frame will be stored
[in]fullFileName- Full file name
Returns
Status

Definition at line 70 of file frame_handler.cpp.

◆ saveFrameToFile()

Status FrameHandler::saveFrameToFile ( aditof::Frame frame,
const std::string fileName = "" 
)

Store frame to file.

Parameters
[in]frame- frame object to be stored in file
[in]fileName- the name of the file. If none provided it will automatically generate one depending on time and frame number.
Returns
Status

Definition at line 59 of file frame_handler.cpp.

◆ saveFrameToFileMultithread()

Status FrameHandler::saveFrameToFileMultithread ( aditof::Frame frame,
const std::string fileName = "" 
)

Store frame to file using a separate thread.

Parameters
[in]frame- frame object to be stored in file
[in]fileName- the name of the file. If none provided it will automatically generate one depending on time and frame number.
Returns
Status

Definition at line 64 of file frame_handler.cpp.

◆ setCustomFormat()

Status FrameHandler::setCustomFormat ( const std::string format)

A custom format in which the frames will be stored/read.

Parameters
[in]format- Format name
Returns
Status

Definition at line 75 of file frame_handler.cpp.

◆ setFrameContent()

Status FrameHandler::setFrameContent ( const std::string frameContent)

Set which frame element you want to store/read (depth/ab/conf)

Parameters
[in]frameContent- a string providing the frame subelements that will be stored
Returns
Status

Definition at line 83 of file frame_handler.cpp.

◆ setInputFileName()

Status FrameHandler::setInputFileName ( const std::string fullFileName)

Set the input file for the frames.

Parameters
[in]fullFileName- Input file name
Returns
Status

Definition at line 55 of file frame_handler.cpp.

◆ setOutputFilePath()

Status FrameHandler::setOutputFilePath ( const std::string filePath)

Set the output path/output folder for the frames.

Parameters
[in]filePath- File path
Returns
Status

Definition at line 51 of file frame_handler.cpp.

◆ storeFramesToSingleFile()

Status FrameHandler::storeFramesToSingleFile ( bool  enable)

Enable/disable if single file is intended to use for storing data.

Parameters
[in]enable- true for single file use/ false for multiple file use
Returns
Status

Definition at line 79 of file frame_handler.cpp.

Member Data Documentation

◆ m_impl

std::unique_ptr<FrameHandlerImpl> aditof::FrameHandler::m_impl
private

Definition at line 138 of file frame_handler.h.


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


libaditof
Author(s):
autogenerated on Wed May 21 2025 02:07:06