Avidemux Forum

Avidemux => MacOSX => Topic started by: reddevil on January 25, 2018, 11:17:10 AM

Title: Sometimes Video to short
Post by: reddevil on January 25, 2018, 11:17:10 AM
Hi,

I record with Enigma Satelitereceiver some TV Shows.
Output is a TS File.

I will encode this videos to X.264/AVC. In 99% it will be successful.
But sometimes I got an errormessage that the video will be to short and the save procedure is stopping.

Today I tried the same video with the latest nightly version for High Sierra.
I didn´t get an error message but the video is still to short.

Does anybody know, how to fix the problem?

THX
Title: Re: Sometimes Video to short
Post by: Jan Gruuthuse on January 25, 2018, 02:40:34 PM
Run through mkv (https://mkvtoolnix.download/downloads.html) sometimes would help. Is this a FTA transmission, Europe, channel? I could test record (OpenPLi 4, DVB-S2 HD Enigma2 Linux Satellite Receiver)
I've don't come across this issue lately. Use the latest nightly for your os: http://avidemux.org/nightly/

If this occurs  regularly: You don't any have signal breakage while recording? (Wind/Rain/ transponder update/ ...)
Title: Re: Sometimes Video to short
Post by: eumagga0x2a on January 25, 2018, 08:25:53 PM
Quote from: reddevil on January 25, 2018, 11:17:10 AM
Today I tried the same video with the latest nightly version for High Sierra.
I didn´t get an error message but the video is still to short.

Was the source video file indexed by an older version? In this case please manually delete the corresponding .idx2 file first.

The "too short" message is shown now only if an error happend in the muxer itself, but not if it occured somewhere in the chain demuxer --> decoder --> editor --> encoder --> muxer gate (and contrary to the earlier state, the message is shown even if a single packet could not be written, not only if this happend before 80% of the video has been saved).

QuoteDoes anybody know, how to fix the problem?

First of all, we must know what the problem is. If deleting index files doesn't allow the video to be saved correctly, the best thing to do would be to provide the TS file as a sample e.g. using WeTransfer. If the recording is too big or somewhat problematic, please launch Avidemux in terminal

/Applications/Avidemux_2.7.0.app/Contents/MacOS/Avidemux2.7 > ~/Desktop/admlog.txt

reproduce the issue, close Avidemux, compress and attach admlog.txt from desktop to your reply.
Title: Re: Sometimes Video to short
Post by: reddevil on January 25, 2018, 10:15:08 PM
Here is the requested admlog.txt file.
Same behavior after deleting index file.
Title: Re: Sometimes Video to short
Post by: eumagga0x2a on January 25, 2018, 11:22:55 PM
Thank you. The data in the stream must be damaged:

[adm_lavLogCallback] 22:07:55-347  [lavc] concealing 1600 DC, 1600 AC, 1600 MV errors in B frame

(probably due to transmission errors) and decoding could not be resumed because probably no undamaged I-frame was close enough (within 20 frames after the decoding failed for the first time).

As you seem to be able to seek to keyframes beyond the damaged spot in the stream, the best you could do is to set marker A to a keyframe just before 00:04:54 and marker B to the next one after that, to delete this part and then to try to save the remaining video.
Title: Re: Sometimes Video to short
Post by: reddevil on January 26, 2018, 08:09:59 AM
Is it possible to repair the file with a tool?
Title: Re: Sometimes Video to short
Post by: Jan Gruuthuse on January 26, 2018, 08:57:27 AM
Quote from: eumagga0x2a on January 25, 2018, 11:22:55 PM
As you seem to be able to seek to keyframes beyond the damaged spot in the stream, the best you could do is to set marker A to a keyframe just before 00:04:54 and marker B to the next one after that, to delete this part and then to try to save the remaining video.

Quote from: Jan Gruuthuse on January 25, 2018, 02:40:34 PM
Run through mkv (https://mkvtoolnix.download/downloads.html) sometimes would help.

If neither of above did work, there are video fragments lost in reception and during recording. The information is not there.

Look at your dish set-up, it is probably no longer aligned properly:
- Pole is no longer perpendicular
- Dish Alignment

check with installer or DIY http://www.dishpointer.com/

Title: Re: Sometimes Video to short
Post by: reddevil on January 26, 2018, 11:21:03 AM
First, Thanks all for your help.

QuoteAs you seem to be able to seek to keyframes beyond the damaged spot in the stream, the best you could do is to set marker A to a keyframe just before 00:04:54 and marker B to the next one after that, to delete this part and then to try to save the remaining video.

After deleting the desired frames, I was able to save the complete mkv file.
But unfortunately the players are not able to handle the file after round about 1:36 min.

I downloaded the mkvtoolnix, but it seems not to run on MAC OS High Sierra.
Title: Re: Sometimes Video to short
Post by: Jan Gruuthuse on January 26, 2018, 01:41:02 PM
you did try this one: https://www.fosshub.com/MKVToolNix.html?

If you did save the video file, you probably need to reload into avidemux and re-encode the video to be playable in other players.
Video Output: Mpeg4 AVC (x264) output
Output Format: MKV Muxer or whatever option you do require.
Title: Re: Sometimes Video to short
Post by: eumagga0x2a on January 26, 2018, 02:01:20 PM
QuoteAfter deleting the desired frames, I was able to save the complete mkv file.
But unfortunately the players are not able to handle the file after round about 1:36 min.

Which players? Can Avidemux play the entire saved video? What happens if you use the MP4 muxer instead of MKV?

QuoteI downloaded the mkvtoolnix, but it seems not to run on MAC OS High Sierra.

mkvtoolnix should be available via Homebrew. However, I didn't check whether it works.
Title: Re: Sometimes Video to short
Post by: reddevil on January 29, 2018, 01:53:53 PM
QuoteWhich players? Can Avidemux play the entire saved video? What happens if you use the MP4 muxer instead of MKV?

Players like VLC or DS Video on Apple TV4k had problems to play the video. But unfortunately even the original TS File couldn´t be played without problems.
So, if there is no possibility to repair the TS File I don't see any chance for AVIDEMUX to do an error free encoding.

So thanks to all for your advices.

In most cases (99%) everything works fine. So I don't´t want to spent to much time on it.