MP3 + JPEG --> MP4 - what's wrong with this pipeline?

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

MP3 + JPEG --> MP4 - what's wrong with this pipeline?

minimalniemand
gst-launch --gst-debug-level=2 
filesrc location=audio.mp3 ! mp4mux name=mux 
filesrc location=image.jpg ! jpegdec ! caps="image/jpg,framerate=30" ! x264enc ! caps="video/x-raw-yuv,width=640,height=480,framerate=30" ! mux. ! filesink location=output.mp4

the files audio.mp3 and image.jpg both reside in the folder where I try to execute this. The error message is "link without source element"


_______________________________________________
gstreamer-devel mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: MP3 + JPEG --> MP4 - what's wrong with this pipeline?

Wim Taymans
On 03/04/2012 10:45 AM, Michael Niemand wrote:
> gst-launch --gst-debug-level=2
> filesrc location=audio.mp3 ! mp4mux name=mux
> filesrc location=image.jpg ! jpegdec ! caps="image/jpg,framerate=30" !
> x264enc ! caps="video/x-raw-yuv,width=640,height=480,framerate=30" !
> mux. ! filesink location=output.mp4

The caps="" part is invalid, either use capsfilter caps="..." or remove
the caps=

Also you might want to put mpegaudiopare between the filesrc and mp4mux
else mp4mux has no idea what those bytes mean.

Wim

>
> the files audio.mp3 and image.jpg both reside in the folder where I
> try to execute this. The error message is "link without source element"
>
>
>
> _______________________________________________
> gstreamer-devel mailing list
> [hidden email]
> http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: MP3 + JPEG --> MP4 - what's wrong with this pipeline?

minimalniemand
On Sun, Mar 4, 2012 at 4:44 PM, Wim Taymans <[hidden email]> wrote:
[....]
Also you might want to put mpegaudiopare between the filesrc and mp4mux else mp4mux has no idea what those bytes mean.

Wim

Thank you very much! There seems to be no element "mpegaudiopare" though - at least I don't find anything about it ... could you please elaborate a little bit?








_______________________________________________
gstreamer-devel mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: MP3 + JPEG --> MP4 - what's wrong with this pipeline?

minimalniemand
oh, it's "parse" excuse my stupidity xD



On Sun, Mar 4, 2012 at 10:10 PM, Michael Niemand <[hidden email]> wrote:
On Sun, Mar 4, 2012 at 4:44 PM, Wim Taymans <[hidden email]> wrote:
[....]
Also you might want to put mpegaudiopare between the filesrc and mp4mux else mp4mux has no idea what those bytes mean.

Wim

Thank you very much! There seems to be no element "mpegaudiopare" though - at least I don't find anything about it ... could you please elaborate a little bit?










--
Michael Niemand

Albusstr. 17
60313 Frankfurt/M
Germany

Tel.: +49 (0) 69 200 130 60
Mobile: +49 (0) 171 645 29 07



_______________________________________________
gstreamer-devel mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: MP3 + JPEG --> MP4 - what's wrong with this pipeline?

minimalniemand
Hmmm ...  after hours of trying, I still get "Link without source element" ... can't figure out why. The source files are both definitely in the right place (the path I execute in). I also tried with providing full paths.

gst-launch filesrc location=audio.mp3 ! mp3parse ! mp4mux name=mux filesrc location=image.jpg ! jpegdec ! x264enc ! mux. ! filesink location=output.mp4




On Sun, Mar 4, 2012 at 10:18 PM, Michael Niemand <[hidden email]> wrote:
oh, it's "parse" excuse my stupidity xD



On Sun, Mar 4, 2012 at 10:10 PM, Michael Niemand <[hidden email]> wrote:
On Sun, Mar 4, 2012 at 4:44 PM, Wim Taymans <[hidden email]> wrote:
[....]
Also you might want to put mpegaudiopare between the filesrc and mp4mux else mp4mux has no idea what those bytes mean.

Wim

Thank you very much! There seems to be no element "mpegaudiopare" though - at least I don't find anything about it ... could you please elaborate a little bit?










--
Michael Niemand

Albusstr. 17
60313 Frankfurt/M
Germany

Tel.: <a href="tel:%2B49%20%280%29%2069%20200%20130%2060" value="+496920013060" target="_blank">+49 (0) 69 200 130 60
Mobile: <a href="tel:%2B49%20%280%29%20171%20645%2029%2007" value="+491716452907" target="_blank">+49 (0) 171 645 29 07





--
Michael Niemand

Albusstr. 17
60313 Frankfurt/M
Germany

Tel.: +49 (0) 69 200 130 60
Mobile: +49 (0) 171 645 29 07



_______________________________________________
gstreamer-devel mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: MP3 + JPEG --> MP4 - what's wrong with this pipeline?

Tim-Philipp Müller-2
On Mon, 2012-03-05 at 17:56 +0100, Michael Niemand wrote:

> gst-launch filesrc location=audio.mp3 ! mp3parse ! mp4mux name=mux
> filesrc location=image.jpg ! jpegdec ! x264enc ! mux. ! filesink
> location=output.mp4

The problematic bit is "mux. ! filesink"

mux. means 'link the left element to a suitable pad on the element named
mux', so the ! after that doesn't make sense.

Try:

gst-launch filesrc location=audio.mp3 ! mp3parse ! mp4mux name=mux
filesink location=output.mp4  filesrc location=image.jpg ! jpegdec !
x264enc ! mux.

Cheers
 -Tim



_______________________________________________
gstreamer-devel mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: MP3 + JPEG --> MP4 - what's wrong with this pipeline?

minimalniemand
On Mon, Mar 5, 2012 at 6:26 PM, Tim-Philipp Müller <[hidden email]> wrote:
[...]

The problematic bit is "mux. ! filesink"

mux. means 'link the left element to a suitable pad on the element named
mux', so the ! after that doesn't make sense.

Thanks for your answer! I haven't yet understood it completely though. What I wanted to do was to provide a sink pad to the muxer where the muxer can link its source pad (=the muxed mp4 stream) to. In the pipeline you provided, the filesink has no sink, does it?
 

Try:

gst-launch filesrc location=audio.mp3 ! mp3parse ! mp4mux name=mux
filesink location=output.mp4  filesrc location=image.jpg ! jpegdec !
x264enc ! mux.


I've tried it and the pipeline starts! Thanks a lot again! But: after a few dozen "<mpegaudioparse0> invalid sync" it hangs, the generated mp4 file is empty (0 Bytes). What can I do? I'm pretty new to gstreamer ... thanks for your patience



_______________________________________________
gstreamer-devel mailing list
[hidden email]
http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel