[gst-devel] mp3 decoder

Zaheer Merali zaheermerali at gmail.com
Wed Nov 19 13:07:02 CET 2008


On Wed, Nov 19, 2008 at 12:03 PM, Edward Hervey <bilboed at gmail.com> wrote:
> Let me rephrase it in another way:
>  The most efficient way to use libmad with GStreamer is how it's being
> done in the mad gstreamer plugin.
>
> If you want to do it another way you're:
>  1. looking for trouble
>  2. doubling your work
>  3. going to end up with a really inefficient plugin
>
> Why do you want to load everything in memory ? What's going to happen if
> I give it a one hour podcast ? you're going to load the 60Mbytes in
> memory.
>

Or worse, a live stream such as an internet radio that runs 24 hours long.

Z

>   Edward
>
> On Wed, 2008-11-19 at 17:21 +0530, Gnanasekar wrote:
>> No , I am not .I am not going to do in the same way as mad used libmad
>> decoder.
>> I was planned to dump the whole data (each 4K) in to a single buffer
>> and passing that
>> buffer to decoder_init function of libmad which is doing decode
>> oparation and processing those stuffs.Because decoder_int takes whole
>> size of the source file(thats why i have been transfered all 4K's to a
>> single  buffer).
>>
>> So my functionality is goes like this,
>>
>> filesrc -> passing 4K for each iteration
>> Gbuf   -> my own buffer for holding all 4K's in a single buffer
>> decoder_init(&Gbuf) -> passing Gbuf to decoder_init (libmad function)
>> input ,output,error -> these are callback functions which is defined
>> in libmad.I am using all these call back functions altogether with
>> this decode of libmad.
>>
>> whether my flow is fine or any changes needed in the flow?
>>
>> Thanks and Regards,
>> SK.Gnanasekar
>>
>>
>>
>>
>> Edward Hervey wrote:
>> > So...
>> >
>> >   Let me get this right. You want to create your own plugin using
>> > 'libmad' and for that you're looking at the code from the mad plugins
>> > which ... already uses 'libmad'.
>> >
>> >   You realize you're trying to do the EXACT SAME THING as the mad
>> > plugin ?
>> >
>> >     Edward
>> >
>> >
>> > On Wed, 2008-11-19 at 14:59 +0530, Gnanasekar wrote:
>> >
>> > > Hi all,
>> > >
>> > >           I am working on developing plug-in for mp3.From the help of
>> > > mad plugin i found some of the ideas.from this what i came to know is
>> > > filesrc is getting an every 4K of data and passing it to chain function
>> > > of mad plugin.Here in chain this 4K is processed in some manner and
>> > > pushed to ( gst_pad_push (filter->srcpad, buf) ) source pad.
>> > >
>> > >           But the thing is that i dont want to use this mad .. i have to
>> > > use my own plugin for mp3 decoder ... for this i found a decoder called
>> > > libmad. which is having some decoding algorithm.
>> > > But it is getting data as a single buffer of whole data.
>> > >
>> > >           My query is that
>> > >          1. how to pass whole data from filesrc to plugin decoder?
>> > >          2. how to use libmad in my plugin ?
>> > >          3. how to pass output of decoded data to alsasink or osssink ?
>> > >
>> > > Thanks and regards,
>> > > SK.Gnanasekar,
>> > >
>> > >
>> > >
>> > > -------------------------------------------------------------------------
>> > > This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
>> > > Build the coolest Linux based applications with Moblin SDK & win great prizes
>> > > Grand prize is a trip for two to an Open Source event anywhere in the world
>> > > http://moblin-contest.org/redirect.php?banner_id=100&url=/
>> > > _______________________________________________
>> > > gstreamer-devel mailing list
>> > > gstreamer-devel at lists.sourceforge.net
>> > > https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>> > >
>> >
>> >
>> >
>>
>
>
> -------------------------------------------------------------------------
> This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
> Build the coolest Linux based applications with Moblin SDK & win great prizes
> Grand prize is a trip for two to an Open Source event anywhere in the world
> http://moblin-contest.org/redirect.php?banner_id=100&url=/
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
>




More information about the gstreamer-devel mailing list