27 lines
527 B
C++
27 lines
527 B
C++
#pragma once
|
|
|
|
#include "cvmmap_streamer/config/runtime_config.hpp"
|
|
|
|
#include <expected>
|
|
#include <memory>
|
|
#include <string>
|
|
#include <string_view>
|
|
|
|
namespace cvmmap_streamer::core {
|
|
|
|
class FrameSource {
|
|
public:
|
|
virtual ~FrameSource() = default;
|
|
|
|
[[nodiscard]]
|
|
virtual std::string_view backend_name() const = 0;
|
|
|
|
[[nodiscard]]
|
|
virtual std::expected<void, std::string> prepare_runtime() const = 0;
|
|
};
|
|
|
|
[[nodiscard]]
|
|
std::expected<std::unique_ptr<FrameSource>, std::string> make_frame_source(const RuntimeConfig &config);
|
|
|
|
}
|