[gstreamer-bugs] [Bug 617314] pbutils: Add codec-specific utility functions
GStreamer (bugzilla.gnome.org)
bugzilla at gnome.org
Fri May 7 04:33:20 PDT 2010
https://bugzilla.gnome.org/show_bug.cgi?id=617314
GStreamer | gst-plugins-base | unspecified
--- Comment #8 from Arun Raghavan <arun at accosted.net> 2010-05-07 11:33:14 UTC ---
(In reply to comment #7)
[...]
> - I think we should drop the pb_utils from the API, so e.g.
>
> gst_codec_utils_aac_*(),
> gst_codec_utils_h264_*()
I find the pb_utils prefix a little messy too, but chose it for consistency.
codec_utils does sound better, so let's go with that.
[...]
> - there's still a bit of a mishmash between parsing bits
> caller side and not, e.g. _aac_get_sample_rate() makes
> the caller parse the header/codec data to extract the
> sample rate index, while other functions do not. I think
The sample rate conversion function was really more of a pattern I saw being
used in multiple places while parsing the header, with the lookup table being
defined in multiple places. I don't see the function being of much value in any
other context, and the caller is going to be walking through the header anyway.
[...]
> - while the _get_foo() API is fairly clean and in line with
> what we do elsewhere, I wonder if it wouldn't be better
> to have functions that operate on, or return, caps
> straight away, instead of doing the whole
> foo = get_foo(); if (foo); gst_caps_set_simple (...);
> dance caller side. Then you'd just have e.g.
> gst_codec_utils_aac_get_caps()
> etc.
True, the check-return-and-set-caps repetition is ugly. Only concern here is if
this function may be used to only extract the profile/level at some point. We
could a small wrapper like gst_codec_utils_aac_set_profile_on_caps (though I'd
much rather have something shorter :)).
--
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
More information about the Gstreamer-bugs
mailing list