Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.freedesktop.org/gstreamer/gst-plugins-rs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVivia Nikolaidou <vivia@ahiru.eu>2022-08-09 14:18:12 +0300
committerVivia Nikolaidou <vivia@ahiru.eu>2022-08-09 22:01:10 +0300
commit8ee8ae581aae44860bb891d5be3d567c19e49ef2 (patch)
tree387173b673798d2f7359c074b098bea33b01e24d /audio/csound
parent247702b76d645c1ccdebe5727b31d461ec7bd598 (diff)
audio: Use gst_audio::AudioCapsBuilder in some plugins
Simplify caps creation codes
Diffstat (limited to 'audio/csound')
-rw-r--r--audio/csound/src/filter/imp.rs8
1 files changed, 3 insertions, 5 deletions
diff --git a/audio/csound/src/filter/imp.rs b/audio/csound/src/filter/imp.rs
index 2761f7e8a..4972fea3a 100644
--- a/audio/csound/src/filter/imp.rs
+++ b/audio/csound/src/filter/imp.rs
@@ -453,11 +453,9 @@ impl ElementImpl for CsoundFilter {
fn pad_templates() -> &'static [gst::PadTemplate] {
static PAD_TEMPLATES: Lazy<Vec<gst::PadTemplate>> = Lazy::new(|| {
- let caps = gst::Caps::builder("audio/x-raw")
- .field("format", gst_audio::AUDIO_FORMAT_F64.to_str())
- .field("rate", gst::IntRange::new(1, i32::MAX))
- .field("channels", gst::IntRange::new(1, i32::MAX))
- .field("layout", "interleaved")
+ let caps = gst_audio::AudioCapsBuilder::new()
+ .format(gst_audio::AUDIO_FORMAT_F64)
+ .layout(gst_audio::AudioLayout::Interleaved)
.build();
let src_pad_template = gst::PadTemplate::new(
"src",