mirror of
https://gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git
synced 2025-06-05 15:08:58 +00:00
rav1enc: Include stream-format and alignment in the caps
This commit is contained in:
parent
ed7b6e8c19
commit
e024eb331d
1 changed files with 11 additions and 2 deletions
|
@ -462,7 +462,10 @@ impl ElementImpl for Rav1Enc {
|
||||||
)
|
)
|
||||||
.unwrap();
|
.unwrap();
|
||||||
|
|
||||||
let src_caps = gst::Caps::builder("video/x-av1").build();
|
let src_caps = gst::Caps::builder("video/x-av1")
|
||||||
|
.field("stream-format", "obu-stream")
|
||||||
|
.field("alignment", "tu")
|
||||||
|
.build();
|
||||||
let src_pad_template = gst::PadTemplate::new(
|
let src_pad_template = gst::PadTemplate::new(
|
||||||
"src",
|
"src",
|
||||||
gst::PadDirection::Src,
|
gst::PadDirection::Src,
|
||||||
|
@ -635,7 +638,13 @@ impl VideoEncoderImpl for Rav1Enc {
|
||||||
});
|
});
|
||||||
|
|
||||||
let output_state = element
|
let output_state = element
|
||||||
.set_output_state(gst::Caps::builder("video/x-av1").build(), Some(state))
|
.set_output_state(
|
||||||
|
gst::Caps::builder("video/x-av1")
|
||||||
|
.field("stream-format", "obu-stream")
|
||||||
|
.field("alignment", "tu")
|
||||||
|
.build(),
|
||||||
|
Some(state),
|
||||||
|
)
|
||||||
.map_err(|_| gst::loggable_error!(CAT, "Failed to set output state"))?;
|
.map_err(|_| gst::loggable_error!(CAT, "Failed to set output state"))?;
|
||||||
element
|
element
|
||||||
.negotiate(output_state)
|
.negotiate(output_state)
|
||||||
|
|
Loading…
Reference in a new issue