Mp4-Video playpack too slow/stuttering

Report any Hollywood bugs here
Post Reply
User avatar
fingus
Posts: 161
Joined: Fri Sep 16, 2011 9:53 am

Mp4-Video playpack too slow/stuttering

Post by fingus »

Here on Windows 10 i recognized a bug.

When replaying FullHD MP4-Videos with Hollywood it does not have the original framerate (tested with 30 or 60fps Videos) and on 60fps videos its very hard stuttering.

Code: Select all

@REQUIRE "avcodec"
@VIDEO 1, "xb1i.mp4"
@DISPLAY { width = #NATIVE, height = #NATIVE, Mode = "fullscreen"}
PlayVideo(1, 0, 0)
Wait(10, #SECONDS)
End
Here you can download the video to test:

https://nas.schapke.org/drive/d/f/559975598527658245

obiwan73
Posts: 6
Joined: Sun Jun 14, 2020 9:49 am

Re: Mp4-Video playpack too slow/stuttering

Post by obiwan73 »

I have me it's slow also test on Windows and MAC

User avatar
airsoftsoftwair
Posts: 4366
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Mp4-Video playpack too slow/stuttering

Post by airsoftsoftwair »

That's a feature, not a bug :) Hollywood currently doesn't have any hardware acceleration (except on OS4) for the video renderer so a 60fps video in Full HD is just too much to handle without hardware acceleration, even for modern CPUs.

User avatar
fingus
Posts: 161
Joined: Fri Sep 16, 2011 9:53 am

Re: Mp4-Video playpack too slow/stuttering

Post by fingus »

airsoftsoftwair wrote:
Sat Jun 20, 2020 1:41 pm
That's a feature, not a bug :) Hollywood currently doesn't have any hardware acceleration (except on OS4) for the video renderer so a 60fps video in Full HD is just too much to handle without hardware acceleration, even for modern CPUs.
It´s a pity. Maybe or hopefully you can implement Hardware Acceleration for Videoplayback in the Future?

The Background is:
I did write a Slideshow for the Company i work for that shows new offers, Time and Date, Weather Conditions for the next days in our Showroom.
It was planned to add some Commercial-Videos of the offered Notebooks from the Manufactures. I had to reject this, because most of the videos run in a slideshow.

User avatar
airsoftsoftwair
Posts: 4366
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Mp4-Video playpack too slow/stuttering

Post by airsoftsoftwair »

fingus wrote:
Mon Jun 22, 2020 11:48 am
It´s a pity. Maybe or hopefully you can implement Hardware Acceleration for Videoplayback in the Future?
Yes, I'm planning to add a new video renderer based on Microsoft's Media Foundation API. This should be able to take full advantage of hardware acceleration.

Hardware-accelerated video playback is available on macOS already. So if you have a Mac 60fps FullHD should play fine on dedicated systems but you must make sure to use the OS video renderer and not Hollywood's unaccelerated inbuilt video renderer.

On Windows, things are a bit different. Besides its inbuilt unaccelerated video renderer Hollywood also supports video playback through DirectShow. This supports hardware acceleration but only for very old formats. However, there might be a 3rd party MP4 codec for DirectShow which you could try. I'm not sure if this exists, though. In the future I'm planning to support Microsoft's new Media Foundation API on Windows which should solve all your problems because it provides hardware-accelerated video playback.

User avatar
airsoftsoftwair
Posts: 4366
Joined: Fri Feb 12, 2010 2:33 pm
Location: Germany
Contact:

Re: Mp4-Video playpack too slow/stuttering

Post by airsoftsoftwair »

Code: Select all

- New [Windows]: Added support for Microsoft's Media Foundation framework; this allows scripts to play MP4
  and some other video formats with full hardware acceleration in decoding, drawing, and scaling; because
  of this it is much faster with MP4 than Hollywood's AVCodec plugin and can easily be used for Full HD
  60fps playback; to make Hollywood use this video backend just pass "native" in the "Loader" argument of
  OpenVideo() or @VIDEO; note that Media Foundation needs at least Windows 7 

Post Reply