theothernt / AerialViews

A screensaver for Android TV devices including Nvidia Shield, Fire TV, and Chromecast with Google TV. Inspired by Apple TV's video screensaver.
GNU General Public License v3.0
469 stars 35 forks source link

HDR playback and framerate match issues #22

Closed Hotboy1987 closed 1 year ago

Hotboy1987 commented 3 years ago

HDR

I like your program very much

I use your program on two andriod devices and same Tv samsung 2021 qled q70a hdr 10

1- mibox s : when I use hdr apple Aerial videos it keeps give me black screen

2- nvidia shield : when I use hdr apple Aerial videos it plays but without activated hdr feature so colors are washed , despite of when I play same videos on any media player on nvidia shield hdr activated and color works well with no problem

SDR Apple Aerial Videos works great on mibox and nvidia shield

Framrate match

when screensaver start during I am pausing a video from player that support framrate match like plex or nova ,, it keeps play on the same framrate of the video ,, it is mostly 24 fps because most movies are 24 fps ,, and when that happen video keeps judder ,, If you can find a way to prevent that it will be great

theothernt commented 3 years ago

I'll address the HDR-related questions first.

For HDR to work, you need a few things a) a HDR capable TV b) HDR playback device and c) HDR video. That seems simple enough but the problem is that there are different standards,. So different TVs, Android TV devices and videos don't always work together.

I think you're running into a few problems...

  1. Your new Samsung TV supports HDR but not Dolby Vision
  2. If you're seeing a black screen when trying to play HDR videos on tour Mi Box it likely means they didn't license the Dolby Vision codec. You can confirm this by looking in Settings > Capabilities for "dolby-digital.decoder". My guess is that Nvidia Shield has it but the Mi Box does not
  3. Apple's videos use Dolby Vision and not HDR10

So Dolby Digital support is required in everything for it to work. Otherwise, you'll have to stick with SDR.

In regards to frame-rate match, I wrote about it in another issue but basically it's not a standard Android feature yet - it's experimental on the Nvidia Shield and Fire TV devices so it will require more research.

Hotboy1987 commented 3 years ago

it seems that I have to wait for android tv 12 to use your app ,, because my main used app are nova and it supports framerate match , when screensaver start during I am pausing a video it keeps play on the same framrate of the video ,, it is mostly 24 fps because most movies are 24 fps ,, and when that happen video keeps judder ,, if you can force your app to play on 60 fps it will be great and make it usable now

theothernt commented 3 years ago

it seems that I have to wait for android tv 12 to use your app ,, because my main used app are nova and it supports framerate match , when screensaver start during I am pausing a video it keeps play on the same framrate of the video ,, it is mostly 24 fps because most movies are 24 fps ,, and when that happen video keeps judder ,, if you can force your app to play on 60 fps it will be great and make it usable now

And I think part of the issue is that apps that use framerate match (in its current experimental state) can cause problems with other apps like this.

My guess is that Nova doesn't disable framerate match when paused/suspended so this issue might be fixed by a) reporting this issue to Nova as well and b) I can try adding some framerate match test code in future?

Hotboy1987 commented 3 years ago

if nova disable framerate match when paused then it have to rematch frame rate every time I pause the video and this make screen blank for second ,, I think the right is too make your app to force screen to play on 60 fps

or

we have to wait for android tv 12 that will support frame rate match on the whole system like apple does

theothernt commented 2 years ago

It looks like I can implement this without too much trouble, but you will have to enable it specifically.

This is how I think it'll work (also please know that I can't test this myself, only guess!)

  1. Nova starts playback, movie is 24fps, Nova requests 24fps from TV
  2. If TV accepts, screen flash black briefly (or shows some info to suggest mode change) and movie plays
  3. You pause movie and leave it paused for set amount of time so screensaver activates
  4. Aerial starts, gets video fps (usually 30) and requests mode from TV - playback starts regardless
  5. When screensaver is interrupted, Nova re-starts playback, re-requests 24fps, another brief black screen, then playback continues...
Hotboy1987 commented 2 years ago

Very good one if you can make it ,, it will be perfect ,, all I want that your program check that tv on right fps when start

youri-- commented 2 years ago

@Hotboy1987 For your Shield, have you tried app Refresh Rate ? You can configure it on a per-app basis. So if you only configure it for Aerial Views (set its default refresh rate at app start to 59.940 Hz probably), it should fix your problem I think.

theothernt commented 2 years ago

A small update. It does look like Android 12 will bring in broad support for a) frame rate matching and b) VRR for TV and devices that support it. This might be the better and easier option for me.

The player I use, ExoPlayer, now supports this feature in Android 12 - ie. if you're watching a movie at 24fps then pause it, when Aerial Views launches, the player will see that the Apple video is 30fps and request a refresh rate change. There will also be a system setting for this which Aerial View will follow.

So kinda good news, but it'll be a few more months I'm afraid.

Hotboy1987 commented 2 years ago

Waiting for this update ,, thx for your effort

On Fri, 25 Mar 2022, 5:43 pm Neil Turner, @.***> wrote:

A small update. It does look like Android 12 will bring in broad support for a) frame rate matching and b) VRR for TV and devices that support it. This might be the better and easier option for me.

The player I use, ExoPlayer, now supports this feature in Android 12 - ie. if you're watching a movie at 24fps then pause it, when Aerial Views launches, the player will see that the Apple video is 30fps and request a refresh rate change. There will also be a system setting for this which Aerial View will follow.

So kinda good news, but it'll be a few more months I'm afraid.

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1079153831, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ35KH55IT5TNUT6QX6LVBXNIHANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

theothernt commented 1 year ago

Just a small update, more devices have Android 12 now including both Chromecast with Google TV (HD and 4K) - so I'll look at adding the 'frame rate switching' in the next update or two.

I currently have no way to test it myself, so I may issue a beta or two on here first.

hunterzero99 commented 1 year ago

Let me know when you have a beta, I'll be available for testing. I am kind of curious how it's going to play out if the app changes the frame rate from a paused video that had frame rate matching, how the OS will react when it goes back and unpauses the video at a different frame rate. I guess in theory the OS should set it back with no issue, but we will see 🙈

theothernt commented 1 year ago

My current guess is that the screen will flash black briefly when the refresh rate changes.

I'll see if I can put together a beta in the next couple of weeks.

Also, just to say this again - it requires an Android TV or device running Android 12 - so the Google TV or Sony TVs (maybe others too?)

Hotboy1987 commented 1 year ago

Yeah that's happen to me when screensaver starts when I am using nova player that's support auto refresh rate

On Thu, 1 Dec 2022, 3:47 am Neil Turner, @.***> wrote:

My current guess is that the screen will flash black briefly when the refresh rate changes.

I'll see if I can put together a beta in the next couple of weeks.

Also, just to say this again - it requires an Android TV or device running Android 12 - so the Google TV or Sony TVs (maybe others too?)

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1333033948, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ3YYUWWMOCX3WOOTT63WK77S5ANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

theothernt commented 1 year ago

I had a bit of free time so I've put together a test version of the app: (link removed)

Do let me know how you get on @hunterzero99 and @Hotboy1987 ...

Hotboy1987 commented 1 year ago

Sure man ,, I will test it today and let you know

On Fri, 2 Dec 2022, 5:51 am Neil Turner, @.***> wrote:

I had a bit of free time so I've put together a test version of the app: Aerial Views 1.3.3 beta 1 https://www.dropbox.com/s/i8gzlnegk0gpak6/aerial-views-1.3.3-beta1.apk?dl=0

Do let me know how you get on @hunterzero99 https://github.com/hunterzero99 and @Hotboy1987 https://github.com/Hotboy1987 ...

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1334727735, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ3YSXM5AY2RFD6FQ6TDWLFW2LANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

Hotboy1987 commented 1 year ago

But can I test it ?? I don't have android 12 on my device nvidia shield pro 2019

On Fri, 2 Dec 2022, 12:55 pm mohamed farouk, @.***> wrote:

Sure man ,, I will test it today and let you know

On Fri, 2 Dec 2022, 5:51 am Neil Turner, @.***> wrote:

I had a bit of free time so I've put together a test version of the app: Aerial Views 1.3.3 beta 1 https://www.dropbox.com/s/i8gzlnegk0gpak6/aerial-views-1.3.3-beta1.apk?dl=0

Do let me know how you get on @hunterzero99 https://github.com/hunterzero99 and @Hotboy1987 https://github.com/Hotboy1987 ...

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1334727735, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ3YSXM5AY2RFD6FQ6TDWLFW2LANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

theothernt commented 1 year ago

For the moment it's Android 12 only but I'll try and add support for 11 or less in the next beta.

Hotboy1987 commented 1 year ago

Waiting for you

On Fri, 2 Dec 2022, 2:04 pm Neil Turner, @.***> wrote:

For the moment it's Android 12 only but I'll try and add support for 11 or less in the next beta.

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1335140553, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ3YPLBS4KUL2QUZ3IDTWLHQUXANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

hunterzero99 commented 1 year ago

I tested out the beta you posted, my HDMI receiver shows that Aerial Views is giving a 60 fps signal instead of 29.97 (or 30 fps). I've tested on SmartYouTube and Plex switching from a 23.97 fps video to Aerial, it does work switching from the 23.97 fps to 60 fps for Aerial when paused, then it switches back to 23.97 fps when Aerial closes.

theothernt commented 1 year ago

I think that's the correct behaviour. When playing 30fps content, a TV will be at a min. refresh rate of 60hz - there is no 30hz mode as far as I'm aware.

For 24fps content, even older TV have a 24hz mode and I think newer TVs might switch to 48hz as they have additional processing modes (eg. black frame insertion)

So, from your point of view, does video playback look correct and smooth - both in Aerial Views and when you return to Plex, SmartTube, etc ?

hunterzero99 commented 1 year ago

Yes, playback looks correct and smooth when switching back and forth. Nice work!

theothernt commented 1 year ago

Ok, here is a new beta which should change frame rate under Android 11 or lower: (link removed)

Hotboy1987 commented 1 year ago

I try your beta and it seems that it doesn't work ,, I paused nova app on video when I use refresh app to adjust the frame rate video ,, but when screensaver starts it show loading title and then it cancel and get back to the app and start video

On Wed, 7 Dec 2022, 10:51 am Neil Turner, @.***> wrote:

Ok, here is a new beta which should change frame rate under Android 11 or lower: Aerial Views v1.3.3 beta 2 https://www.dropbox.com/s/8jfd7foiu52bu1c/aerial-views-1.3.3-beta2.apk?dl=0

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1340602219, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ32TTILQGWNVNE2OCPLWMBF2XANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

theothernt commented 1 year ago

I try your beta and it seems that it doesn't work ,, I paused nova app on video when I use refresh app to adjust the frame rate video ,, but when screensaver starts it show loading title and then it cancel and get back to the app and start video

Thanks for testing that beta. It seems like it's crashing, but I think I know the cause. I'll try and get another beta out soon.

EDIT: I got the crash report, so that confirms what I have to fix.

Eagle00Eye commented 1 year ago

I would be interested in beta testing the Android 11 version on my Shield TV Pro 2019 when you have another ready to test.

Been dying for frame rate match. I easily notice judder in my 4K Drone Landscape videos I got from YouTube.

theothernt commented 1 year ago

I would be interested in beta testing the Android 11 version on my Shield TV Pro 2019 when you have another ready to test.

There was a crash bug in that last beta as I can't test the feature at the moment.

I should have a new build in the next few days which may fix the issue.

theothernt commented 1 year ago

Sorry about the delay, here is a new build to test: (link removed)

This build should fix the crash on Android 11 (or less) devices but it probably won't change the frame rate.

If this build a) doesn't crash but also b) doesn't change the frame rate, I have another fix which should work.

Hotboy1987 commented 1 year ago

Great job man ,, I try this one and it works perfectly ,, I try it with nova player and nplayer and I use refresh rate app to auto adjust frame rate ,, and when I pause video and screensaver starts now it adjust frame rate to 30 fps and it stay like that so next video on screensaver now not blinking like before ,, you made my day ,, thx man

On Sat, 4 Feb 2023, 4:20 pm Neil Turner, @.***> wrote:

Sorry about the delay, here is a new build to test: Aerial Views v1.3.3 beta 3 https://www.dropbox.com/s/5vudjcfwtey4522/aerial-views-1.3.3-beta3.apk?dl=0

This build should fix the crash on Android 11 (or less) devices but it probably won't change the frame rate.

If this build a) doesn't crash but also b) doesn't change the frame rate, I have another fix which should work.

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1416764645, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ3ZRSIHXYVEDPF7XZH3WVZQRTANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

Eagle00Eye commented 1 year ago

I have installed this beta. Fantastic work. I have about 90 4K Landscape Drone videos and so far so good. I have started the screensaver and rotated through my videos. I haven't noticed any judder from incorrect framerate.

I do have one questions. Once the screensaver is running. And it switches to a new video. If that video has a different frame rate, does this version also change to the new videos framerate? Or does it only change on the first initial video and is then locked to that framerate on subsequent videos?

All in all fantastic work. I think all of my landscape videos are 24 frames. Which is why I was asking the question. In case I ever get 30 or 60 fps videos.

theothernt commented 1 year ago

That's fantastic to hear @Hotboy1987 and @Eagle00Eye

Can you both confirm what devices you're using and what version of Android they are running?

How it works - every time a video starts playing, I try to get the frame rate, then check if the window/screen is running at that refresh rate and change it if needed.

When will it be released - the next major update is v1.4.0 which is due soon so I hope to add these changes to v1.4.1 but that might be a month or two away. In the meantime, feel free to keep running the v1.3.3 beta if it fits your needs!

Eagle00Eye commented 1 year ago

I have a Shield TV Pro 2019 running 9.1.1(33.2.0.157)

And thanks so much for your continued work on this project. Frame rate match for me was what it needed to really show off my Theatre room setup when I have guests over.

Hotboy1987 commented 1 year ago

I have nvidia shield pro 2019 with latest firmware

On Sun, 5 Feb 2023, 12:03 pm Eagle00Eye, @.***> wrote:

I have a Shield TV Pro 2019 running 9.1.1(33.2.0.157)

And thanks so much for your continued work on this project. Frame rate match for me was what it needed to really show off my Theatre room setup when I have guests over.

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1417301250, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ37RLZHEKRXYZGSRGG3WV53HDANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

theothernt commented 1 year ago

Thanks to you both for all the testing and patience!

So, frame rate switching works on Android 9 and Android 11 👍🏻

Eagle00Eye commented 1 year ago

Shield Android 9.1.1 is actually Android 11. It's just a weird naming convention.

We both have the same shield running the same firmware.

theothernt commented 1 year ago

Shield Android 9.1.1 is actually Android 11. It's just a weird naming convention.

We both have the same shield running the same firmware.

Ahh! thanks, so Android 11 so far then.

Hotboy1987 commented 1 year ago

Yeah that's right android 11

On Sun, 5 Feb 2023, 2:08 pm Neil Turner, @.***> wrote:

Shield Android 9.1.1 is actually Android 11. It's just a weird naming convention.

We both have the same shield running the same firmware.

Ahh! thanks, so Android 11 so far then.

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1417640464, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ37V2Z5G5PQLTAVBXG3WV6J2HANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

Hotboy1987 commented 1 year ago

I don't know why ,, but it return to blinking again when I pause video on nova player

On Sun, 5 Feb 2023, 2:33 pm mohamed farouk, @.***> wrote:

Yeah that's right android 11

On Sun, 5 Feb 2023, 2:08 pm Neil Turner, @.***> wrote:

Shield Android 9.1.1 is actually Android 11. It's just a weird naming convention.

We both have the same shield running the same firmware.

Ahh! thanks, so Android 11 so far then.

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1417640464, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ37V2Z5G5PQLTAVBXG3WV6J2HANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

theothernt commented 1 year ago

I don't know why ,, but it return to blinking again when I pause video on nova player

Can you give me a little more detail on what's happening?

Hotboy1987 commented 1 year ago

Same as before ,, when I pause video on app with frame rate match and screensaver starts with every video on screensaver after it starts it blank for second to adjust frame rate

On Mon, 6 Feb 2023, 10:27 pm Neil Turner, @.***> wrote:

I don't know why ,, but it return to blinking again when I pause video on nova player

Can you give me a little more detail on what's happening?

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1419705541, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ34J3PVZORJKLSE6MALWWFNDNANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

theothernt commented 1 year ago

Same as before ,, when I pause video on app with frame rate match and screensaver starts with every video on screensaver after it starts it blank for second to adjust frame rate

I'll look into a fix for that issue - I assume all the videos are 30fps (ie the Apple vids) ?

Hotboy1987 commented 1 year ago

Yes, that's right.

On Tue, 7 Feb 2023, 11:01 am Neil Turner, @.***> wrote:

Same as before ,, when I pause video on app with frame rate match and screensaver starts with every video on screensaver after it starts it blank for second to adjust frame rate

I'll look into a fix for that issue - I assume all the videos are 30fps (ie the Apple vids) ?

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1420420103, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ34SVI3X7JKAG7HDOYDWWIFPZANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

Hotboy1987 commented 1 year ago

To be honest, it sometimes happens and sometimes it doesn't. I don't know based on what,, but the circumstances are the same in both cases

On Tue, 7 Feb 2023, 12:18 pm mohamed farouk, @.***> wrote:

Yes, that's right.

On Tue, 7 Feb 2023, 11:01 am Neil Turner, @.***> wrote:

Same as before ,, when I pause video on app with frame rate match and screensaver starts with every video on screensaver after it starts it blank for second to adjust frame rate

I'll look into a fix for that issue - I assume all the videos are 30fps (ie the Apple vids) ?

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1420420103, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ34SVI3X7JKAG7HDOYDWWIFPZANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>

theothernt commented 1 year ago

To be honest, it sometimes happens and sometimes it doesn't. I don't know based on what,, but the circumstances are the same in both cases

That is odd. I checked the code and it does check if a refresh rate change is needed first. For example, if all your videos are 30fps, then it should change the display to 60hz only once.

theothernt commented 1 year ago

As v1.4.0 has just been released, I've made an updated beta: (link removed)

Nothing new in this beta, it's just 1.4.0 with the test refresh-rate changing code added.

Do let me know if you notice any odd behaviour or issues as ExoPlayer has been updated a couple of times since the previous betas.

Eagle00Eye commented 1 year ago

Thanks. I will install it tomorrow and let you know if there is a difference from the previous beta.

nadsy commented 1 year ago

Thanks for letting me help test run this.

Atm on Shield Pro each video is playing at 60hz when I look via my Samsung qn90b settings.

Is this correct behaviour or should it be switching to for example 30hz to match apple tv aerial views video

theothernt commented 1 year ago

Atm on Shield Pro each video is playing at 60hz when I look via my Samsung qn90b settings.

Is this correct behaviour or should it be switching to for example 30hz to match apple tv aerial views video

Yes, that's correct behaviour.

It's about requesting a refresh rate which is a multiple of the frame rate, as 24hz and 30hz are too low - modern TV panels can handle 120hz, for example.

To test the feature you'll have to watch a movie at 24fps, the TV should switch into a refresh rate which is a multiple of that eg. 120hz. If the screensaver runs, it'll request 60hz for the Apple videos which run at 30fps.

theothernt commented 1 year ago

Here is the beta version which includes the option to enable auto refresh rate matching.

Look in Settings > Appearance

If there are no issues with this version, it should appear on GitHub, Play Store, etc in a few weeks.

(link removed)

theothernt commented 1 year ago

Has anyone had a chance to try the v.1.4.1 beta 1? 😅

Hotboy1987 commented 1 year ago

Yes I use it

I use frame rate match app to match frame rate when I play any videos from nplayer and nova

And with this new version of AerialViews I turn frame rate feature on , on it

And it work very well when I pause video when I use nova player ,, but it keep blanking with every screensaver when I pause video when I use nplayer

I have nvidia shield pro 2019

On Sun, 26 Mar 2023, 7:30 pm Neil Turner, @.***> wrote:

Has anyone had a chance to try the v.1.4.1 beta 1? 😅

— Reply to this email directly, view it on GitHub https://github.com/theothernt/AerialViews/issues/22#issuecomment-1484165639, or unsubscribe https://github.com/notifications/unsubscribe-auth/AU5YJ3ZJJ2FDGMLZOGKTBITW6CDM7ANCNFSM5EK5YS2A . You are receiving this because you were mentioned.Message ID: @.***>