A gstreamermm dynamic Gst::Pad example.
#include <gstreamermm.h>
#include <glibmm/main.h>
int main(int argc, char *argv[])
{
try
{
pipeline->add(source)->add(decodebin)->add(sink);
}
{
return 1;
}
try
{
source->link(decodebin);
}
{
}
switch (message->get_message_type())
{
case Gst::MESSAGE_EOS:
case Gst::MESSAGE_ERROR:
main_loop->quit();
break;
default:
break;
}
return true;
});
{
}
else
{
}
});
main_loop->run();
return 0;
}
static Glib::RefPtr< MainLoop > create(bool is_running=false)