[MEncoder-users] Converting wmv to wmv
Lennart Börjeson
Lennart.Borjeson at cinnober.com
Tue Apr 18 09:51:43 CEST 2006
tisdag 18 april 2006 03:46 skrev Ko Ko:
> Hi
>
> I tried your -of lavf and it works! But sadly with a bit of problems.
>
> I tried like
>
> "mencoder -of lavf -oac mp3lame -ovc lavc -lavcopts vcodec=wmv1 -ofps
> 100.0 test.wmv output.wmv"
>
> I can't use wmv2. It doesn't render. I can't use copy for audio. Doesn't
> matter as well. But the movie was playing back too fast. Just like it is
> being 'fast forward'. I am not too sure why. Is it because I -ofps 100.0? I
> don't know what is the purpose of using this. But if I don't set this it
> doesn't produce wmv.
wmv supports a variable frame rate, but mencoder doesn't. In fact, mencoder
requires to use a fixed frame rate, either by default from the input or by
specifying it explicitly.
100fps is improbable. If your video material orgininates from "normal" video
or film, it will be, in average, either 30, 25, 24 or 15fps (or the absurd
1000/1001 NTSC fractions thereof), and you should specify -ofps 30 or
whatever matches your input.
Note that when the input has a variable frame rate and you enforce a fixed
frame rate, the A/V sync will always be off. It will alternatively lag and
lead. If you have specified a framerate which really is the average of the
original, audio and video will eventually end simultaneously, thus be in sync
on average, but in the course of the film it will alternate between lag and
lead.
>
> Previously I rendered this way
>
> " mencoder -oac copy -ovc lavc -lavcopts vcodec=wmv2 -ofps 100.0 test.wmv
> output.wmv"
>
> This produce wmv file as well. But may be it doesn't conform to those wmv
> standard. When I try to play using Windows Media Player, the player prompt
> me a warning message. Only if I click yes to play it played. But it doesn't
> play in fast forward manner and the pictures and sounds in the movie are
> sync.
>
> If the first method doesn't output the file in a fast forward way, then I
> think that should be exactly what I want. Your "-of lavf" option seems to
> make sure it produce in wmv format. I just don't understand why it is
> fast-forwarded.
>
> Ko Ko
>
> The Wanderer <inverseparadox at comcast.net> wrote:
>
> Ko Ko wrote:
> > Hi,
> >
> > I manage to encode other movie format like avi, mpg and mpeg without
> > much problems. I am actually trying to shorten the movie length to
> > make some preview clips for my website. But when it comes to wmv
> > format i cannot encode wmv to wmv. I can encode wmv to avi.
>
> That's because that is what MEncoder is intended to encode to. Any other
> output (container) formats are later additions.
>
> > But this is not exactly what I want. Normally how I encode is
> >
> > mencoder -oac copy -ovc lavc -lavcopts vcodec=msmpeg4v2 $upfile -o
> > $imagepath/$filename -endpos 10
>
> This command line does not specify an output format (-of), so it creates
> a file with the default container type, AVI. You want to add '-of lavf'
> and make sure that $filename ends in '.wmv'. If that doesn't work, then
> assuming you're using the latest CVS versions, it's probably not
> supported and I almost certainly can't help you.
>
> > This codes produce 10 seconds video clip of my uploaded file to the
> > specified file path on the server. But it doesn't really work for
> > wmv. Is there any codecs available to encode wmv to wmv and how?
>
> Codecs are probably not relevant, at least not at this stage. The
> problem is a matter of container formats.
--
!++
! Lennart Börjeson
! Partner, Developer
! Cinnober Financial Technology AB
! Industrigatan 2A
! S-112 46 STOCKHOLM
! Sverige/Sweden/Schweden/Suède
! mailto:Lennart.Borjeson at cinnober.com
! phone:+46-8-50304717
! gsm:+46-70-3394717
! fax:+46-8-50304701
! http://www.cinnober.com
!--
More information about the MEncoder-users
mailing list