abrenoch / hyperion-android-grabber

Screen grabber for hyperion
MIT License
207 stars 36 forks source link

4K YouTube on Sony Bravia A1E drops frames #175

Open itsermo opened 3 years ago

itsermo commented 3 years ago

As title states, 1080p and below works well on my TV, but 4K and higher res content played on the built-in YouTube app chugs, and skips frames. Seems to be dropping well below 15 fps and it's unwatchable.

See specs for my TV here: https://www.sony.com/electronics/televisions/a1e-series/specifications

Are there any hotspots in the code that could be optimized? I tried setting the frame grabber to 30 fps, and then to see if it was I/O bound, I also tried sending only the average color as well, but it made no difference. So from this first check, it would appear that we are CPU-bound for 4K content on this TV?

Is there a function during frame grab that could be optimized, maybe by doing it with NEON instructions, or fiddling with any for loop that might be running on the pixel buffer (or using native vs. virtual machine compiling). I'm not well-versed in Android, but if anyone suspects CPU bottlenecks in the code, and can point me to them, I could maybe take a stab at optimization.

Romanchuk commented 2 years ago

I have TCL tv. 4k lags on 30 fps settings. Also leds are always green on 4k videos (doesn't matter source YouTube or kodi)