[MPlayer-users] Re: Question on "trans-coding" with mencoder...

Rainer Hantsch rainer at hantsch.co.at
Mon Aug 18 16:38:49 CEST 2003


On Mon, 18 Aug 2003, Oliver Fromme wrote:

| Did you try to concatenate the MPEG files first, and then encode the result
| as a whole?  That should work.

I could find no tool within the last 4 years, which allows me to do anything
with MPEG files within LINUX. But I found transcode (and later
mplayer/mencoder), and both allow working with AVI.

Therefore a clear answer: NO.
I converted both parts into AVI first, and then I used what I have to proceed,
this are parts of transcode and/or mplayer.


| Again, I would recommend you do the cutting on the source MPEG, not on the
| resulting AVI file.  You can use the mpgtx tool for that purpose.

I hear the first time of it. Is it part of mplayer/mencoder? Where to get it?


| Although, if the audio is layer-3, cutting is difficult. That's because in
| layer-3 streams, the contents of frames can partially depend on previous
| frames.  So you need a pretty sophisticated tool to cut those without
| inserting errors into the result and/or loosing sync.  I don't think that
| mpgtx is smart enough for that.  Nor any other tool that I'm aware of right
| now, I'm afraid.

Exactly. Because the MPEG files already had an MP3 audio track, I could only
extract it with "-oac copy". I am nearely sure that the probelms are because
of a possibly varying bitrate in MP3. I also got heaviest problems with
synchronization when converting VOB files, but then I got the idea to use a
constant bitrate -- and not it works fine.
But how to convert a "any" MP3 into a constant bitrate MP3 without any change
in playing length and quality loss?


|> · Can mencoder create mpeg files, too? (I have an original SuSE 8.0, which
|> has a downstripped jpeglib, which cannot ENcode mpeg, only DEcode. When
|> mencoder can do encoding without this library, shouldn't it work? - How?
|
| No.  To the best of my knowledge, mencoder only supports
| AVI as a "container" format.  Personally, I use mplayer +
| yuvscale + mpeg2enc (+ sox + lame/toolame) to create MPEG
| files from any source material (DVD, AVI, MOV, ...).
| It's a bit tedious because several different tools are
| involved, so I wrote a small script to make that task
| easier.  Maybe it's helpful:
| http://www.secnetix.de/~olli/scripts/dvd-to-vcd.tar.gz
|
| (The name might imply it's only to convert DVDs to VCDs,
| but that's not true anymore.  You can feed it almost
| anything that mplayer is capable of reading, and it can
| produce VCD, SVCD, or generic MPEG1 or MPEG2 streams.)

I did something similar. A bash script which does the documented 3-pass
conversion with re-scaling and so on. Works great from VOB files, but I prefer
dvd::rip when starting on DVD sources, it is easier. I use mencoder only when
I do have only VOB files because dvd::rip forces the INF file.

| Not that I'm aware of.  personally I prefer to do such
| things with CLI tools, not GUI.  Because CLI tools are
| much easier to automate, and easier to control, and the
| actions are always exactly reproducible.

My words and opinion, too. But without a highly detailled documentation and
many samples, you waste a lot of time until you get first "acceptable"
results.


| Having said that, there are tools which might come somewhat close to what
| you're looking for, such as the video editor which is part of the
| NuppelVideo tool set.  Disclaimer: I haven't tried any of those GUI tools.

Well, I always see tools which need extremely much dependices, because they
are often written for KDE. X11 apps would be much simpler, because they do
not have so many dependices, and also work under KDE, so I do not understand
why everybody codes for KDE. =8-/
But - Cutting/pasting videos without a GUI is not really usable - isn't it?
How to cut out commercials from recordings without a GUI? Here it is a must to
cut exactly!


mfg

  Ing. Rainer Hantsch




More information about the MPlayer-users mailing list