How to render smooth Gradients with Android

SneWs's picture

If you're like me, you've probably noticed that when making gradients with Android, they might get rendered badly, it's not as smooth as it can be, especially when using the emulator.

To get nice and smooth gradients, you just need to add one line of code to you're Activity.

// Call this in you're onCreate() for ex.

The above code snippet will enable a much better and smoother look of you're gradient(s). But please be advised that this isn't a silver bullet, the downside is the following.


Subscribe to RSS - Tips