[vlc-devel] Transcoding with API 0.9.0

jf massol jf.massol at gmail.com
Mon Jun 25 16:55:21 CEST 2007


Hello,

I solved my problem. In my first e-mail, the code was :

/* ***************************************** */
string trspts =
"\"#transcode{vcodec=mp2v,vb=512k,scale=1,acodec=128,ab=128}:duplicate{dst=std{access=file,dst="+
this->home +"}}\"";
/* ***************************************** */

There is no need to add \" when API is used though it's needed by using VLC
in command line.
I hope it will help whereas it was a stupid mistake :(.

Regards,

JF

2007/6/24, Jean-François Massol <jf.massol at gmail.com>:
>
> Hello !
>
> I look for informations about how to compose arguments in order to
> transcode
> through API. After some researches, it seems that it's not possible to
> use "sout" with API (no problem for vout, aout etc.). I saw a "to do" in
> the
> API documentation. Am I wrong ?
>
> regards,
>
> JF
>
> Le vendredi 22 juin 2007 15:01, vous avez écrit:
> > Hello everybody,
> >
> > I fixed my API problems (0.9.0). I followed API guidelines given. But
> I'm
> > facing a problem, within API, as argv arguments given (mainly for
> > transcoding), I got those error messages :
> >
> > /* error messages */
> > [00000328] stream_out_standard private error: no access _and_ no muxer
> > (fatal error)
> > [00000327] main stream output error: stream chain failed for
> >
> `std{mux="",access=""#transcode{vcodec=mp2v,vb=512k,scale=1,acodec=128,ab=1
>
> >28}",dst="duplicate{dst=std{access=file,dst=/home/videogate/FRANCE.ts}}""}'
> > [00000326] main input error: cannot start stream output instance,
> aborting
> > [00000317] access_mms access error: error while asking for file -1
> > [00000317] access_mms access error: error while asking for file -1
> > [00000317] access_mms access error: cannot connect to server
> > [00000317] access_mms access error: no stream selected
> > [00000317] access_mms access error: cannot start stream
> > /* ************ */
> >
> > and this is my source code :
> >
> > int Transcoder::transcoder_init()
> > {
> >     cout << "Transcoder_init() : " << this->home << endl;
> >     string trspts =
> >
> "\"#transcode{vcodec=mp2v,vb=512k,scale=1,acodec=128,ab=128}:duplicate{dst=
> >std{access=file,dst="+ this->home +"}}\"";
> >     char *opts[] = {"vlc","--sout",(char *)trspts.c_str()};
> >     libvlc_exception_init (&_transexcep);
> >     _transcoder = libvlc_new(3,opts,&_transexcep);
> >
> >     if(libvlc_exception_raised(&_transexcep))
> >     {
> >             cerr << "Transcoder init : " <<
> > libvlc_exception_get_message(&_transexcep);
> >         MSG_GENERIC("Cannot init Transcoder")
> >         libvlc_exception_clear(&_transexcep);
> >             exit(1);
> >     }
> >
> >     if(_transcoder == NULL)
> >     {
> >         cerr << "No Transcoder instance found !";
> >         MSG_GENERIC("Cannot init Transcoder")
> >         exit(1);
> >     }
> >
> >     MSG_GENERIC("Transcoder successfully initialized")
> >     return 0;
> > }
> >
> > My VLC instance is successfully initialized. But I don't understand why
> a
> > "std{mux="",access=" in addition to my args ?
> > Is there a special format for argv in order to transcode my streams ?
> When
> > I tried "-vvv", it works fine, but no way for my transcode args.
> >
> > Thanks a lot one more time.
> >
> > regards,
> >
> > JF
>
> --
> Jean-François Massol
> jf.massol at gmail.com
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.videolan.org/pipermail/vlc-devel/attachments/20070625/548e3738/attachment.html>
-------------- next part --------------
_______________________________________________
vlc-devel mailing list
vlc-devel at videolan.org
http://mailman.videolan.org/listinfo/vlc-devel


More information about the vlc-devel mailing list