nx_server_plugin_sdk 1.0 Server Plugin SDK

Public Member Functions | Protected Member Functions | List of all members
nx::vms_server_plugins::cloud_storage::sample::StreamReader Class Reference
Inheritance diagram for nx::vms_server_plugins::cloud_storage::sample::StreamReader:

## Public Member Functions
| StreamReader (const std::string &deviceId, int streamIndex, int64_t startTimeMs, int64_t durationMs)
virtual nx::sdk::ErrorCode | getNextData (nx::sdk::cloud_storage::IMediaDataPacket **packet) override
virtual int64_t | startTimeUs () const override
virtual int64_t | endTimeUs () const override
virtual nx::sdk::ErrorCode | seek (int64_t timestampUs, bool findKeyFrame, int64_t *selectedPositionUs) override

## Protected Member Functions
virtual void | getOpaqueMetadata (nx::sdk::Result< const nx::sdk::IString *> *outResult) const override
virtual const nx::sdk::IList< nx::sdk::cloud_storage::ICodecInfo > * | getCodecInfoList () const override

## Member Function Documentation

## ◆ getNextData()

nx::sdk::ErrorCode StreamReader::getNextData | ( | nx::sdk::cloud_storage::IMediaDataPacket ** | packet | ) |
| overridevirtual

Attempts to read a next media data packet. Should return ErrorCode::noData if there is no data left to read.

Implements nx::sdk::cloud_storage::IStreamReader.

## ◆ seek()

nx::sdk::ErrorCode StreamReader::seek | ( | int64_t | timestampUs,
|  | bool | findKeyFrame,
|  | int64_t * | selectedPositionUs
| ) |  |
| overridevirtual

Moves stream data cursor to the required position if possible. This position may be greater than requested if there is no media data packet with the exact timestamp. If 'findKeyFrame' is true, selected position should correspond to the media data packet which has 'isKeyFrame' flag set.

Implements nx::sdk::cloud_storage::IStreamReader.

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

- samples/cloud_storage/sample_cloud_storage_plugin/src/nx/vms_server_plugins/cloud_storage/sample/stream_reader.h
- samples/cloud_storage/sample_cloud_storage_plugin/src/nx/vms_server_plugins/cloud_storage/sample/stream_reader.cpp