[Gambas-user] media component syntax and the gstreamer filesink
Tobias Boege
taboege at ...626...
Sat Feb 15 02:54:44 CET 2014
On Sat, 15 Feb 2014, Beno?t Minisini wrote:
> Le 15/02/2014 02:23, Dominique Michel a ?crit :
> >>
> >> That solve the duration issue with mplayer and alsaplayer:
> >> $hAudio["is-live"] = "1"
> >> but not the 0 length file issue.
> >
> > That solve it only partly. Both players play it with the wanted
> > duration, but they display a file length of 0 seconde.
> >
> > I get the same problem with the following command line:
> > gst-launch-1.0 audiotestsrc is-live=1 ! flacenc ! filesink
> > location=generated.flac
> >
> > But I get the correct duration display with:
> > gst-launch-1.0 -e audiotestsrc is-live=1 ! flacenc ! filesink
> > location=generated.flac
>
> I think I can add the same trick to gb.media. I will tell you.
>
> >
> > Another issue is that ideally, I want to be able to use such a pipeline
> > with gambas:
> >
> > gst-launch-1.0 -e audiotestsrc is-live=1 !
> > audio/x-raw,channels=2,rate=48000 ! flacenc ! filesink
> > location=generated.flac
> >
> > and if I try something like:
> >
> > $hAudio["is-live"] = "1"
> > $hRaw = New MediaControl($hPlayer, "audio/x-raw")
> > $hConv = New MediaControl($hPlayer, "flacenc")
> > $hOutput["location"] = "wavegenerator.flac"
> > $hOutput["append"] = "1"
> > $hAudio.LinkTo($hRaw)
> > $hRaw.LinkTo($hConv)
> > $hConv.LinkTo($hOutput)
> >
> > it fail at $hRaw = New MediaControl($hPlayer, "audio/x-raw")
> >
> > How I can get it to work?
>
> 'audio/x-raw' is actually a special syntax for the 'capsfilter'
> GStreamer plugin.
>
> It is handled by the MediaFilter object, not just the MediaControl object:
>
> $hRaw = New MediaFilter($hPlayer, "audio/x-raw,channels=2,rate=48000")
>
> That should work. You will tell me.
>
Very sorry to step in (especially since I can say absolutely nothing about
the topic) but this mail has been the 10,000th I received from this list!
Congratulating myself and trying to finish the work as now I could
theoretically go to bed :-)
--
"There's an old saying: Don't change anything... ever!" -- Mr. Monk
More information about the User
mailing list