1

I have a video clip that appears to be slightly corrupted. Does not play on VLC but works on Potplayer. I used FFprobe to get information on the video.

The problem appears to be with the start points of the video stream:

time_base=1/90000
start_pts=585050940
start_time=6500.566000
duration_ts=585050940
duration=6500.566000
bit_rate=3123218

I'm just wondering whether it is possible to manually edit the "start_pts" and "start_time" to 0? Is there any specific software to do this? Due to large size of video file, I couldn't load it in Notepad++.

Full ffprobe output shown below:

# ffprobe output

[streams.stream.0]
index=0
codec_name=h264
codec_long_name=H.264 / AVC / MPEG-4 AVC / MPEG-4 part 10
profile=unknown
codec_type=video
codec_time_base=1/60
codec_tag_string=avc1
codec_tag=0x31637661
width=1920
height=1080
coded_width=1920
coded_height=1080
closed_captions=0
has_b_frames=0
sample_aspect_ratio=N/A
display_aspect_ratio=N/A
pix_fmt=unknown
level=-99
color_range=unknown
color_space=unknown
color_transfer=unknown
color_primaries=unknown
chroma_location=unspecified
field_order=unknown
timecode=N/A
refs=1
is_avc=true
nal_length_size=4
id=N/A
r_frame_rate=30/1
avg_frame_rate=30/1
time_base=1/90000
start_pts=585050940
start_time=6500.566000
duration_ts=585050940
duration=6500.566000
bit_rate=3123218
max_bit_rate=N/A
bits_per_raw_sample=N/A
nb_frames=195017
nb_read_frames=N/A
nb_read_packets=N/A

[streams.stream.0.disposition]
default=1
dub=0
original=0
comment=0
lyrics=0
karaoke=0
forced=0
hearing_impaired=0
visual_impaired=0
clean_effects=0
attached_pic=0
timed_thumbnails=0

[streams.stream.0.tags]
language=und
handler_name=VideoHandler

[streams.stream.1]
index=1
codec_name=aac
codec_long_name=AAC (Advanced Audio Coding)
profile=LC
codec_type=audio
codec_time_base=1/48000
codec_tag_string=mp4a
codec_tag=0x6134706d
sample_fmt=fltp
sample_rate=48000
channels=2
channel_layout=stereo
bits_per_sample=0
id=N/A
r_frame_rate=0/0
avg_frame_rate=0/0
time_base=1/48000
start_pts=0
start_time=0.000000
duration_ts=312029184
duration=6500.608000
bit_rate=189376
max_bit_rate=189376
bits_per_raw_sample=N/A
nb_frames=304718
nb_read_frames=N/A
nb_read_packets=N/A

[streams.stream.1.disposition]
default=1
dub=0
original=0
comment=0
lyrics=0
karaoke=0
forced=0
hearing_impaired=0
visual_impaired=0
clean_effects=0
attached_pic=0
timed_thumbnails=0

[streams.stream.1.tags]
language=eng
handler_name=SoundHandler

[format]
filename=D\:\\Start\\test.mp4
nb_streams=2
nb_programs=0
format_name=mov,mp4,m4a,3gp,3g2,mj2
format_long_name=QuickTime / MOV
start_time=0.000000
duration=6500.608000
size=2703218140
bit_rate=3326726
probe_score=100

[format.tags]
major_brand=isom
minor_version=512
compatible_brands=isomiso2avc1mp41
David
  • 83
  • 6

1 Answers1

1

Not possible but not necessary either.

You can remux the file with timestamps corrected.

ffmpeg -probesize 4G -analyzeduration 10G -an -itsoffset -6500.566 -i test.mp4 -vn -i test.mp4 -c copy remuxed.mp4
Gyan
  • 85,394
  • 9
  • 169
  • 201
  • I tried what Gyan suggested, but get the following error: `[mov,mp4,m4a,3gp,3g2,mj2 @ 00000278a233a880] Could not find codec parameters for stream 0 (Video: h264 (avc1 / 0x31637661), none, 1920x1080, 2613 kb/s): unspecified pixel format Consider increasing the value for the 'analyzeduration' and 'probesize' options Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'test.mp4': Metadata: Duration: 02:00:04.78, start: 0.000000, bitrate: 2814 kb/s Stream #0:0(und): Video: h264 (avc1 / 0x31637661), none, 1920x1080, 2613 kb/s, 30 fps, 30 tbr, 90k tbn, 180k tbc (default)` – David Jun 27 '20 at 08:42
  • Add -report and rerun. Share report. – Gyan Jun 27 '20 at 09:48
  • FFmpeg Report: [link]https://drive.google.com/file/d/1unl-Bkl3F44G32Ol32rPR7VNk603S_Zj/view?usp=sharing – David Jun 27 '20 at 10:11
  • Similar error. See ffmpeg report [link]https://drive.google.com/file/d/10abVujcmZ2KBNDWmkqdyLyox7TVYB5Aa/view?usp=sharing – David Jun 27 '20 at 14:21
  • Videol file generated appears to still be corrupted. Video freezes when playback and audio is out of sync. See ffmpeg report [link] https://drive.google.com/file/d/161xxo4iLVNDLdKw7aOG7_Ev0MkSgyfuf/view?usp=sharing See ffprobe report for remuxed file [link] https://drive.google.com/file/d/1X2WpZpmK4GCnpw1XoG8EmxF0GpYvXPlK/view?usp=sharing – David Jun 28 '20 at 02:42
  • is there a way for extracting header information from a video? I need to extract some information such as motion vectors, macroblock size,... but I do not know how I can extract this information from a video. could you please help me with this issue? – david Jun 07 '21 at 09:41