Loading...
Searching...
No Matches
GStreamerPipelineParse.hpp File Reference

Appsink discovery and media-type classification from a pipeline string. More...

Detailed Description

Appsink discovery and media-type classification from a pipeline string.

A live source has no negotiated caps when the pipeline is built, so the only thing that can say whether an appsink carries audio or video – and at what geometry – is the pipeline description itself. Kept out of GStreamerDevice.cpp so it can be exercised without a GStreamer library: this is ctre over a string plus Video::gstreamerToLibav().

Go to the source code of this file.

Classes

struct  Gfx::GStreamer::AppsinkInfo
 

Namespaces

namespace  Gfx
 Binds the rendering pipeline to ossia processes.
 

Functions

std::vector< std::string > Gfx::GStreamer::find_appsink_names (const std::string &pipeline)
 
std::vector< std::string > Gfx::GStreamer::find_all_named_elements (const std::string &pipeline)
 
template<ctll::fixed_string Rexp>
int Gfx::GStreamer::last_int_of (std::string_view str, int fallback)
 
void Gfx::GStreamer::classify_from_pipeline_string (const std::string &pipeline, const std::string &sink_name, AppsinkInfo &info)
 

Variables

constexpr auto Gfx::GStreamer::appsink_name_rexp = ctll::fixed_string{R"(appsink\b[^!]*?\bname\s*=\s*([A-Za-z0-9_]+))"}
 
constexpr auto Gfx::GStreamer::elem_name_rexp = ctll::fixed_string{R"(\bname\s*=\s*([A-Za-z0-9_]+))"}
 
constexpr auto Gfx::GStreamer::channels_rexp = ctll::fixed_string{R"(channels=(?:\‍(int\))?\s*([0-9]+))"}
 
constexpr auto Gfx::GStreamer::rate_rexp = ctll::fixed_string{R"((?:^|[^A-Za-z0-9_\-])rate=(?:\‍(int\))?\s*([0-9]+))"}
 
constexpr auto Gfx::GStreamer::width_rexp = ctll::fixed_string{R"(width=(?:\‍(int\))?\s*([0-9]+))"}
 
constexpr auto Gfx::GStreamer::height_rexp = ctll::fixed_string{R"(height=(?:\‍(int\))?\s*([0-9]+))"}
 
constexpr auto Gfx::GStreamer::format_rexp = ctll::fixed_string{R"(format=(?:\‍(string\))?\s*([A-Za-z0-9]+))"}