gitmyhub

Blurry

Java ★ 5.7k updated 3y ago

Blurry is an easy blur library for Android

Blurry is a small Android library that makes it straightforward to add blur effects to views and images inside a mobile app. Blurring is a visual technique often used for frosted-glass backgrounds, privacy masks, or aesthetic overlays, and doing it from scratch on Android requires quite a bit of boilerplate code. Blurry handles that plumbing so developers can apply the effect in one or two lines.

The library has two main modes. In overlay mode, it blurs everything inside a view container and renders the blur on top of it, which is useful for background blur effects. In capture mode, it takes a screenshot of a specific view or accepts an existing image and writes the blurred result into an image view of your choice.

Several parameters can be adjusted: the blur radius (how strong the blur is), a down-sampling factor (trading quality for speed), an optional color tint layered on top of the blur, and whether the operation runs in the background to avoid blocking the main screen. Overlay mode also supports a short animation so the blur fades in over a specified number of milliseconds rather than appearing instantly.

The README is brief and primarily shows code examples in Kotlin and Java. Installation is through Maven Central with a single dependency line. The library requires Android 5.0 or newer. It is open-source under the Apache 2.0 license.