[FFmpeg-user] Seeking for a method to remove sections of a video

Carlos E. R. robin.listas at telefonica.net
Tue Jun 20 05:23:53 EEST 2017


On 2017-06-19 22:56, James Girotti wrote:
>>
>>> I ultimately run avidemux as a frontend to ffmpeg. I have avidemux save
>>> (copy video and audio) to a FIFO which is then the input for my ffmpeg
>>> command. From my limited testing that way supports multiple audio tracks.
>>> It's not a perfect setup because you have to end cuts on key-frames, not
>>> usually a problem for me though (you can start your cut wherever). Also,
>>> you can see the PTS for a given frame in avidemux. So in the rare-case I
>>> can manually tell ffmpeg where to cut a given segment. Generally, this is
>>> the workflow I use.
>>
>> This is basically telling avidemux to do a copy of video and audio and
>> cutting at start/end points. At least on avidemux 2 it asks what audio
>> track to use, and totally ignores other tracks.
>>
> And avidemux 3 wants the other audio tracks to be fed from external files.
>>
> 
>  From my testing avidemux(v2.6.8) will copy all tracks. No need to select
> which to copy. Then you can let ffmpeg deal with which tracks to
> transcode/keep, etc. Also, I might have forgotten to mention that I have
> avidemux set to use MKV muxer for output.

Trying avidemux 2.6.20 (my distro label it as avidemux3); initially says
"audio copy 0 tracks", and it is impossible to select the audio tracks
from the already loaded file:

On the audio menu there is a dialog with 4 audio lines. I enable track
one. First item is "add audio track" and automatically opens a file
dialog to enter the dialog. It refuses to simply take the audio from the
already loaded video file. So I can do nothing here.

I can select an start A point and an end point B, and the encoding would
go from A to B. Instead one can use Menu/Cut, and it deletes instantly
that section. I didn't know that trick! Thanks.

But the result has no audio at all.


Trying avidemux version 2.5.6 (my distro label it as avidemux2)

Says:  H.264 detected.
If the file is using B-frames as reference it can lead to a crash of
stuttering.
Avidemux can use another mode which is safe but YOU WILL LOSE FRAME ACCURACY
Do you want to use that mode?


I choose safe mode.

Now it says:

Multiple audio tracks.
The file you just loaded contains several audio tracks.
Go to Audio->Main Track to select the active one.



I can then select the "main" audio track. The secondary track has to be
selected from an external file, which means no way.


I try to select a section of the video, but at one point it goes to 100%
CPU on the four cores.

The same trick for removing sections works as in avidemux 3.


But... The result has jumpy video from the movie section, and audio from
the previous commercial section, ie, video and audio is not in sync.

I check it with "mediainfo" and there is only one audio track.



So avidemux is out, again :-(



>>> Good luck and let us know what you decide to use.
>>
>> Well, so far, nothing.
>>
>> I have to leave the original recordings untouched for years till I find
>> a solution.
>>
> 
> Just to throw another one in the mix: comskip (http://www.kaashoek.com/comsk
> ip/). I have been playing around with it. There is a SDL GUI that you can
> review/adjust the results with after analysis. In the GUI, you can step
> forward and back by single-frames. It supports different output formats
> including EDL and XML. Major down-side is that I have not figured out how
> to stop comskip from analyzing my file first (even telling it not to use
> any detection methods).

Ah.

Well, first stop is that my distro doesn't have it.

Let's see...

«Comskip is a free mpeg commercial detector. It is a windows console
application that reads a mpeg file and analyses the content based on a
large amount of configurable parameters. After analysis it generates a
file in various possible formats containing the location of the
commercials inside the mpeg file. The formats include input files for
Personal Video applications like SageTV or GBPVR, interactive video
editors (VideoRedo, Cuttermaran,Mpeg2Schnitt...) command line video
cutters (mpgtx, cuttermaran, mencoder) and video players (zoomplayer,
mplayer, ...). Comskip can read MPEG and h.264 video and MPEG2, AC3 and
AAC audio from PS , TS and dvr-ms files upto HD resolution (max
2000x1200) at 25fps (PAL) and 29.97fps (NTSC). The h.264 and WTV version
is still in beta test and available for donators. Comskip can NOT read
copy protected recordings.  »

Ah, Windows console application. I use Linux. Maybe it runs under wine.
[...] Well, it does. Not runs, walks, it takes a lonnnnng time searching
for commercials.

[...]

Long like hours. :-(

[...]

I've let it run something like four hours and it still hasn't finished.
I'm aborting it, I have to sleep.


-- 
Cheers / Saludos,

		Carlos E. R.
		(from 42.2 x86_64 "Malachite" at Telcontar)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: OpenPGP digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-user/attachments/20170620/108f9b65/attachment.sig>


More information about the ffmpeg-user mailing list