colloqi / piSignage

Digital Signage Player Software for Raspberry Pi, more details at
http://pisignage.com
589 stars 252 forks source link

Frame rate 1080p video choppy #188

Open klibansky opened 2 years ago

klibansky commented 2 years ago

Hi there, is there a specific file/codec spec that I need to use in order to get super fluid videos? I now have a 1080p 20 second video file and I'm looking for a player that can do endless gapless looping video playback. At the moment the video files is playing choppy and not sharp. I'm running on a Raspberry Pi 4.

AbhijithBn commented 2 years ago

Hi,

We do support Gapless and Endless video support on Raspberry Pi 4 having player version 4.x.x ( latest version being 4.7.4 ).

This will allow you to play a series of videos without any gap in loop.

Please let us know if you face any issues. I request you to attach the videos in the same thread if you still see choppy videos.

klibansky commented 2 years ago

Hi @AbhijithBn, I tested this and still no luck. I have a 4K monitor connected at the moment. The video is 1080p.

I tested with VLC, which gives me a choppy playback full screen and a large gap when the video restarts.

https://user-images.githubusercontent.com/100637/178963729-5b2738eb-99b4-4e42-b1c4-372fab8ec800.mov

Then I tested with MPV with 0 second gap which gives me a 1:1 video scale (1080p) and a nicely smooth video playback but a large gap when the video restarts.

https://user-images.githubusercontent.com/100637/178963743-146009e3-7e70-4b17-908b-b734fef403f7.mov

What should the codec/settings be for the best result?

AbhijithBn commented 2 years ago

Hi @klibansky

We usually see a jittery video if the bitrate of the video is high. Video playback is best when bitrate is around 4-5Mbps and file format is mp4 with h264 codec.

Can you please share the source video and player version so that I can test it at my end and give you the best solution?

klibansky commented 2 years ago

I encoded a video in h264 4k at constant bit rate 5Mbps with vlc setting and still huge gap and very choppy video. At the beginning of the video you see the jump cut when the asset restarts.

https://user-images.githubusercontent.com/100637/178976701-03bf7a39-48ee-450d-b0d3-38dd825ae5ad.mov

How should I share the video? Player version: 4.7.4/473_11_script_2022-06-11

AbhijithBn commented 2 years ago

Hi @klibansky We have worked on the above issue and this will be available to use in Release 4.7.5

1) We have fixed VLC video player to play gapless videos by using a file-caching flag. 2) If you have a playlist having a single video then it will be played in loop without any gaps/cuts. 3) If you have a playlist having multiple video assets, then the playlist will be played in loop with no gaps/cuts between videos. 2) However there will be a slight delay (2-3sec) in starting VLC for the first time or after a deploy is done. 3) We do not suggest MPV video player for continuous playback since it has not been optimised for Raspberry Pi yet.

klibansky commented 2 years ago

Thats great @AbhijithBn! I updated the player to the latest version and I can confirm that there the video is playing/looping gapless. Super!

There is still a frame rate problem however. You can see it very clearly on the large screen. I tried to take a video of it and it looks a bit less choppy on my video but I can assure you it doesn't look smooth.

https://user-images.githubusercontent.com/100637/182364963-b92f60a2-9f08-4576-a87a-a3b22a32414b.mov

Should I use different encoding settings?

klibansky commented 2 years ago

I'm sorry to bump this issue but I am trying to get a setup running to synchronize a number of Nfts looping on multiple screens at full resolution (4k). 1080p would be sufficient but on a 75" screen it still looks choppy. Like its for running on 30fps.

AbhijithBn commented 2 years ago

Hi @klibansky Apologies for the late response.

Here are our findings upon testing.


Here are our observations with playing videos in VLC Media Player on Raspberry Pi 4

1) 1080p Videos settings should be as follows

2) 4K Videos settings should be as follows:


Note:

Here are some reference screenshots from Handbrake to encode your video

Screenshot 2022-08-26 at 5 43 39 PM Screenshot 2022-08-26 at 5 43 50 PM Screenshot 2022-08-26 at 5 44 01 PM

Tips for checking the codec of the 4K video

  1. Navigate to the directory having the 4K video in terminal.
  2. Execute the following command:
    ffprobe <video-of-mkv-format> ( example: ffprobe pixels.mkv )
  3. You should get an output similar to this Screenshot 2022-08-26 at 6 13 26 PM

As you can see in the highlighted section, the video should have HEVC (main)

Samuel12321 commented 1 year ago

Is server support for 4k videos resolved yet?