qctools icon indicating copy to clipboard operation
qctools copied to clipboard

Video playback performance: Regression from 0.6 to 0.7?

Open pjotrek-b opened this issue 9 years ago • 5 comments

I've noticed that playing back a video (FFV1, PAL SD) that ran smoothly in v0.6 now runs slower than realtime in v0.7.x.

Additionally, I've compared CPU usage of different players for the same file. It seems that QCTools is using way more CPU to render videos. Playback in QCTools was done with "Left=Normal" and "Right=No Display".

For comparison: (100% = Both physical cores + Hyperthreading. 50% = Only physical cores)

  • VirtualDub (1.9.11) / ffdshow-tryouts: ~17%
  • VLC (2.1.0): ~20 %
  • QCTools 0.6: ~60%
  • QCTools 0.7: ~50% (*)

(*) It's using less CPU, but the video runs below realtime now :(

Testvideo: 1 Min. FFV1/PCM/AVI - Source: VHS

System:

  • OS: Windows7 / 64bit
  • CPU: i3-2100 @ 3.1GHz (DualCore)

pjotrek-b avatar Jul 14 '15 16:07 pjotrek-b

verified, there is an inaccuracy in the timing of the frame presentations in the 0.7 releases. Also tested a 10 second file at 100 fps and it played the entire thing back in 3 seconds.

dericed avatar Nov 17 '15 18:11 dericed

I closed https://github.com/bavc/qctools/issues/48 and https://github.com/bavc/qctools/issues/33 as all 3 tickets seem to refer to the same issue which can be consolidated here.

dericed avatar Nov 17 '15 18:11 dericed

Here's a method to reproduce the issue. Make test files via:

ffmpeg -f lavfi -i testsrc=n=3:r=300 -c:v ffv1 -t 10 300fps.mkv
ffmpeg -f lavfi -i testsrc=n=3:r=30 -c:v ffv1 -t 10 30fps.mkv
ffmpeg -f lavfi -i testsrc=n=3:r=3 -c:v ffv1 -t 10 3fps.mkv

All samples should take 10 seconds (-t 10) to play. From a rough test:

  • 3fps.mkv takes 6 seconds to play
  • 30fps.mkv takes 60 seconds to play
  • 300fps.mkv - not patient enough to test

dericed avatar Oct 04 '16 22:10 dericed

@pjotrek-b, please re-test with latest build. https://mediaarea.net/download/snapshots/binary/qctools/

dericed avatar Nov 16 '16 16:11 dericed

To update on the stats above in the current build:

  • 3fps.mkv takes 2 seconds to play
  • 30fps.mkv takes 9 seconds to play
  • 300fps.mkv - not patient enough to test, but in 100 seconds it played 0.557 seconds of it or 167 frames.

so in other words:

  • 3fps.mkv, 2 seconds to play 30 frames, ~15 frames/sec
  • 30fps.mkv, 9 seconds to play 300 frames, ~33.33 frames/sec
  • 300fps.mkv, 100 seconds to plays 167 frames, ~1.67 frames per seocnd

¯\(ツ)

dericed avatar Mar 21 '18 15:03 dericed

This has probably been resolved for a long time, but now all samples play in 10 seconds as expected regardless of framerate.

dericed avatar Sep 02 '23 19:09 dericed