Scaffold C++20 screencast project with Meson, agent workflow, and phase plan

This commit is contained in:
2026-08-28 21:54:32 +02:00
commit 742611b841
25 changed files with 1322 additions and 0 deletions
+39
View File
@@ -0,0 +1,39 @@
#pragma once
#include "screencast/codec/encoder.h"
#include <cstdint>
#include <memory>
#include <optional>
#include <span>
#include <vector>
namespace sc {
struct DecodedFrame {
int width = 0;
int height = 0;
uint64_t capture_timestamp_ns = 0;
std::vector<std::byte> rgba_pixels;
};
struct DecoderConfig {
std::string_view codec_name = "h264";
int width = 0;
int height = 0;
};
class Decoder {
public:
virtual ~Decoder () = default;
// Feed one encoded frame. Returns decoded frames when available.
virtual std::vector<DecodedFrame> decode ( const EncodedFrame &frame ) = 0;
};
class DecoderFactory {
public:
static std::unique_ptr<Decoder> create ( const DecoderConfig &config );
};
} // namespace sc