StreamPlaybackUtil_zlib mimics video stream. More...
#include <stream_util_zlib.hpp>
Public Member Functions | |
| bool | doDecode (const string &in, vector< char > &out) KZ_OVERRIDE |
| Decode frame from buffer. More... | |
| ~StreamPlaybackUtil_zlib () KZ_OVERRIDE | |
| Destructor. More... | |
Public Member Functions inherited from kanzi::connect::ConnectStreamPlaybackUtil | |
| const string & | getAuxData () const |
| Get the optional data from encoder or stream provider. More... | |
| void | startDecoderThread () |
| Perform decoding on a dedicated thread. Deriving class should call this function after it has initialized the infra for decoding. More... | |
| void | stopDecoderThread () |
| Perform decoding on main thread. Releases Decoder thread if it exists. More... | |
| ~ConnectStreamPlaybackUtil () KZ_OVERRIDE | |
| Destructor. More... | |
| kzUint | getWidth () KZ_OVERRIDE |
| kzUint | getHeight () KZ_OVERRIDE |
| Gets height of video frame. More... | |
| kanzi::FramebufferSharedPtr | getNextRenderBuffer () KZ_OVERRIDE |
| void | onRendering () KZ_OVERRIDE |
| notify frame consumed More... | |
Public Member Functions inherited from kanzi::connect::StreamPlaybackUtil | |
| virtual | ~StreamPlaybackUtil () |
Static Public Member Functions | |
| static shared_ptr< StreamPlaybackUtil_zlib > | create (Domain &domain, const string &filename, function< void()> onProcessSampleTask, FrameBufferFactorySharedPtr bufferFactory, const int maxQueueSize) |
Static Public Member Functions inherited from kanzi::connect::ConnectStreamPlaybackUtil | |
| static shared_ptr< ConnectStreamPlaybackUtil > | create (Domain &domain, const string &streamId, function< void()> onProcessSampleTask, FrameBufferFactorySharedPtr bufferFactory) |
| Create new stream playback util. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from kanzi::connect::ConnectStreamPlaybackUtil | |
| ConnectStreamPlaybackUtil (function< void()> onProcessSampleTask, int queueMaxLength, bool dropOldOnKeyFrame) | |
| Constructor. More... | |
| bool | hasConfigFrame (const StreamNewBlobEvent &blobMessage) const |
| Check if the message contains a configuration frame for the encoder. More... | |
| bool | hasKeyFrame (const StreamNewBlobEvent &blobMessage) const |
| Check if the message contains a key frame. More... | |
| bool | hasPartialFrame (const StreamNewBlobEvent &blobMessage) const |
| Check if the message contains a partial frame. More... | |
| bool | initialize (Domain &domain, const string &streamId, FrameBufferFactorySharedPtr bufferFactory) KZ_OVERRIDE |
| Initializes video util. More... | |
| bool | queueHasSpace () const |
| Check if the data queue has space to add more items. More... | |
| void | queueRenderBuffer (FramebufferSharedPtr framebuffer) |
| Add a buffer to ui-queue. More... | |
| virtual void | remoteSettingsChanged (bool wasValid, bool isValid) |
| Callback from runtime data observer. More... | |
| void | requestEncoderParameter (const string ¶meterName) const |
| void | requestStreamInfo () const |
| void | restartEncoder () const |
| void | setEncoderParameter (const string ¶meterName, const string ¶meterValue) const |
| virtual bool | shouldProcessThisFrame (const StreamNewBlobEvent &blobMessage) |
| Check if this message should be passed to the decoder Decoder implementations should implement this function e.g. More... | |
| void | uninitialize () KZ_OVERRIDE |
| Uninitializes video util. More... | |
| virtual void | updateVideoSurfaceTexture () |
| Populate framebuffer with data received from doDecode and queue render buffer for UI. More... | |
StreamPlaybackUtil_zlib mimics video stream.
| kanzi::connect::StreamPlaybackUtil_zlib::~StreamPlaybackUtil_zlib | ( | ) |
Destructor.
|
static |
| filename | uri of video file to load. |
|
virtual |
Decode frame from buffer.
If output is pixel data, provide it to output buffer and return true. Depending on threading strategy, runs either on dedicated thread or within the main thread,
| in | Input buffer as raw string. Connect infra has no knowledge on the contents. May contain a full or partial frame. |
| out | Optional. If decoder provides pixels to be rendered, they need to be populated here. Decoder may use received input and pass a gpu handle to kanzi using getNextRenderBuffer instead. |
Reimplemented from kanzi::connect::ConnectStreamPlaybackUtil.