A decoder for video frames. More...
#include <cvb/codec_bridge/decoders.hpp>
Public Member Functions | |
CodecStatus | Decode (const Packet &packet) |
Decode a packet. More... | |
void | Flush () |
Flush the decoder and finish decoding. More... | |
std::unique_ptr< Frame > | ReceiveFrame () |
Receive an an decoded frame. More... | |
int | StreamIndex () const |
Get the stream index this decoder can work on. More... | |
A decoder for video frames.
A decoder can decode packets into video frames.
|
inline |
Decode a packet.
[in] | packet | The packet to decode. |
Any | exception derived from std::exception including CvbException. |
Decoders will usually deliver frames only after a few packets have been decoded. If no frames are received the decoder will refuse to take new packets and return ReadoutRequired.
|
inline |
Flush the decoder and finish decoding.
Any | exception derived from std::exception including CvbException. |
Notify the decoder that no more packets will be send, so the remaining frames can be delivered. The decoder will not accept any more packets after flushing.
|
inline |
Receive an an decoded frame.
Any | exception derived from std::exception including CvbException. |
Decoders will usually deliver frames only after a few packets have been decoded. If no new frames can be received this method will return empty pointers.
|
inline |
Get the stream index this decoder can work on.
Any | exception derived from std::exception including CvbException. |
When the decoder is created from a container file, stream index will be the index of the first video stream in the file.