This commit is contained in:
Aria 2025-03-21 22:23:30 +11:00
commit 9c94d113d3
Signed by untrusted user who does not match committer: aria
GPG key ID: 19AB7AA462B8AB3B
10260 changed files with 1237388 additions and 0 deletions

View file

@ -0,0 +1,54 @@
#ifndef STAR_STREAMING_VIDEO_CONTROLLER_HPP
#define STAR_STREAMING_VIDEO_CONTROLLER_HPP
#include "StarVariantExtra.hpp"
namespace Star {
struct StreamingVideoFrameBuffer {
StreamingVideoFrameBuffer() : width(), height(), buffer() {}
unsigned width;
unsigned height;
void* buffer;
};
class StreamingVideoController;
typedef shared_ptr<StreamingVideoController> StreamingVideoControllerPtr;
class StreamingVideoController {
public:
StreamingVideoController();
virtual ~StreamingVideoController();
virtual void setStreamConfiguration(Variant const& configuration);
virtual bool active() const;
virtual void update();
virtual void start();
virtual void stop();
virtual bool hasError();
virtual String nextError();
virtual bool hasStatus();
virtual String nextStatus();
virtual void setFrameBufferSize(Vec2U const& size);
virtual void setStreamMetadata(Variant const& metadata);
virtual bool nextFrameExpected();
virtual StreamingVideoFrameBuffer acquireFrameBuffer();
virtual void submitFrameBuffer(StreamingVideoFrameBuffer buffer);
protected:
virtual String kind() const;
private:
StreamingVideoControllerPtr m_impl;
List<String> m_errors;
Vec2U m_size;
};
}
#endif