Opened 9 years ago

Closed 9 years ago

Last modified 9 years ago

#4766 closed defect (fixed)

Regression: Viewing avisynth files in ffplay is extremely laggy (A/V desync)

Reported by: nixx Owned by:
Priority: important Component: avformat
Version: git-master Keywords: avs regression
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

I have been using ffplay to preview Avisynth scripts before and it has worked reasonable well for a while, but I recently updated my ffmpeg executables and now the playback is extremely laggy, but only when the script has audio.

However, if I use

ffmpeg -f avisynth -i test.avs -c copy test.avi

and play the avi file, there is no lag whatsoever.

Even an extremely simple script like

DirectShowSource("test.mp4")

exhibits this behavior.

To reproduce, install Avisynth (http://avisynth.nl/index.php/Main_Page#Official_builds, make sure you install the same arch as your ffmpeg executables) and run

ffplay -f avisynth test.avs

Like I said, any avs script has this issue, but I will attach a test file nonetheless.

Attachments (1)

Avisynth test files.zip (380.8 KB ) - added by nixx 9 years ago.

Download all attachments as: .zip

Change History (12)

by nixx, 9 years ago

Attachment: Avisynth test files.zip added

comment:1 by Carl Eugen Hoyos, 9 years ago

Keywords: avs regression added
Priority: normalimportant

Is the issue not reproducible with the following command?

$ ffmpeg -f avisynth -i test.avs -qscale 2 out.avi

comment:2 by nixx, 9 years ago

ffmpeg still encodes avs files just fine, it's only ffplay that seems to have any issues.

comment:3 by Carl Eugen Hoyos, 9 years ago

Please run "git bisect" to find the change introducing the issue.

comment:4 by nixx, 9 years ago

Unfortunately I do not have a development environment capable of compiling ffmpeg, so I can't give you any exact information regarding when the bug was introduced.

All I know is that the months old build I was using did not have this problem.

comment:5 by Marton Balint, 9 years ago

Well I suspect b1f78632c681f32c4901a85aa7ee72bf9ca6fece, altough I don't quite see why.

Could you try the zeranoe builds from 20150805 ?

comment:6 by nixx, 9 years ago

The build I was using was from 20150803, so I don't think that would be it.

You made me take a closer look at the zeranoe page and notice the previous builds link though, so I will see if I can find where it starts happening.

comment:7 by nixx, 9 years ago

After testing different zeranoe builds, it seems like this bug was introduced between 33c752be513d09d9dd498beac02c39522d671888 (20140919) and 3fe962940f1e8fd2f1881c0cee646bd0e52ab204 (20140924).

Last edited 9 years ago by nixx (previous) (diff)

comment:9 by Marton Balint, 9 years ago

It seems avisynth is not setting codec packet timebase.

I have sent a patch to ffmpeg-devel which should fix this.

comment:10 by Carl Eugen Hoyos, 9 years ago

Component: ffplayavformat
Resolution: fixed
Status: newclosed

Fixed by Marton Balint in 8009a1f1fdce16a59ea911e2b768e56ec4c8e344
Thank you for the report!

comment:11 by nixx, 9 years ago

I can confirm that it's fixed now. Thank you all for the quick responses.

Note: See TracTickets for help on using tickets.