mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 20:21:24 +00:00
audioparse: Set framesize and properties correctly when taking format
from caps.
This commit is contained in:
parent
ba47769823
commit
e3a1e489d2
1 changed files with 6 additions and 0 deletions
|
@ -373,8 +373,14 @@ gst_audio_parse_get_caps (GstRawParse * rp)
|
|||
GstCaps *caps = gst_pad_get_current_caps (rp->sinkpad);
|
||||
gst_audio_info_from_caps (&info, caps);
|
||||
|
||||
ap->format = GST_AUDIO_PARSE_FORMAT_RAW;
|
||||
ap->raw_format = GST_AUDIO_INFO_FORMAT (&info);
|
||||
ap->channels = GST_AUDIO_INFO_CHANNELS (&info);
|
||||
ap->interleaved = info.layout == GST_AUDIO_LAYOUT_INTERLEAVED;
|
||||
|
||||
rate = GST_AUDIO_INFO_RATE (&info);
|
||||
gst_raw_parse_set_fps (GST_RAW_PARSE (ap), rate, 1);
|
||||
gst_audio_parse_update_frame_size (ap);
|
||||
|
||||
return caps;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue