Valkka
1.6.1
OpenSource Video Management
|
#include <frame.h>
Public Member Functions | |
BasicFrame () | |
Default ctor. | |
virtual | ~BasicFrame () |
Default virtual dtor. | |
frame_essentials (FrameClass::basic, BasicFrame) | |
frame_clone (FrameClass::basic, BasicFrame) | |
virtual void | print (std::ostream &os) const |
How to print this frame to output stream. | |
virtual std::string | dumpPayload () |
Dumps internal payload data. | |
virtual void | dumpPayloadToFile (std::ofstream &fout) |
Dumps internal payload data into a file. | |
virtual void | reset () |
Reset the internal data. | |
virtual bool | isSeekable () |
for H264 true if sps, other codecs, always true | |
void | reserve (std::size_t n_bytes) |
Reserve space for internal payload. | |
void | resize (std::size_t n_bytes) |
Init space for internal payload. | |
void | fillPars () |
Fill codec-dependent parameters based on the payload. | |
void | fillH264Pars () |
Inspects payload and fills BasicFrame::h264_pars;. | |
void | fillAVPacket (AVPacket *avpkt) |
Copy payload to AVPacket structure. | |
void | copyFromAVPacket (AVPacket *avpkt) |
Copy data from AVPacket structure. | |
void | filterFromAVPacket (AVPacket *avpkt, AVCodecContext *codec_ctx, AVBitStreamFilterContext *filter) |
Copy data from AVPacket structure. | |
std::size_t | calcSize () |
How much this frame occupies in bytes when serialized. | |
bool | dump (IdNumber device_id, RaWriter &raw_writer) |
Write the frame to filestream with a certain device id. | |
IdNumber | read (RawReader &raw_reader) |
Read the frame from filestream. Returns device id. | |
Public Member Functions inherited from Frame | |
Frame () | |
Default ctor. | |
virtual | ~Frame () |
Default virtual dtor. | |
frame_essentials (FrameClass::none, Frame) | |
frame_clone (FrameClass::none, Frame) | |
virtual void | updateAux () |
Update internal auxiliary state variables. | |
virtual void | update () |
Update helper points (call always) | |
void | copyMetaFrom (Frame *f) |
Copy metadata (slot, subsession index, timestamp) to this frame. | |
Public Attributes | |
std::vector< uint8_t > | payload |
Raw payload data (use .data() to get the pointer from std::vector) | |
AVMediaType | media_type |
Type of the media (video/audio) | |
AVCodecID | codec_id |
AVCodeCID of the media. | |
H264Pars | h264_pars |
H264 parameters, extracted from the payload. | |
Public Attributes inherited from Frame | |
SlotNumber | n_slot |
Slot number identifying the media source. | |
int | subsession_index |
Media subsession index. | |
long int | mstimestamp |
Presentation time stamp (PTS) in milliseconds. | |
Additional Inherited Members | |
Protected Attributes inherited from Frame | |
FrameClass | frameclass |
Declares frametype for correct typecast. Used by Frame::getFrameClass() | |
Custom payload Frame.
Includes codec info and the payload. Received typically from LiveThread or FileThread.
Copiable/Queueable : yes
TODO: update to the metadata scheme using metadata.h