Screen brightness on Android

Hi,

How can I control screen brightness on Android via Unity script?

For example: I want to darken the screen when no input was given for a certain time but I don’t want it to go to pitch black.

You can control Android (and iOS) screen brightness using Dimmer: Dimmer | Integration | Unity Asset Store

One of our apps needed to brighten up the screen when it needed attention after sitting idle for a while, and I figured I wasn’t the only one who could use this functionality so I built Dimmer. You can use it to darken the screen too, of course. And it doesn’t require any extra permissions.

Hope you find it useful.

Check out

RenderSettings.ambientLight

You can programmatically set it with dark colors when idle, and bright colors when you are not.