explaingit

camerakit/blurkit-android

3,762JavaAudience · developerComplexity · 2/5LicenseSetup · easy

TLDR

An Android library that adds real-time frosted-glass blur effects to any area of your app screen, controlled through a simple XML layout component and backed by performance-optimized bitmap processing.

Mindmap

mindmap
  root((BlurKit))
    What it does
      Real-time blur effects
      Frosted glass for Android
    Components
      BlurLayout XML view
      BlurKit class API
      fastBlur method
    Performance
      Downscale optimization
      Configurable frame rate
    Setup
      Gradle dependency
      MIT licensed
Click or tap to explore — scroll the page freely

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

Things people build with this

USE CASE 1

Add a frosted-glass blur panel behind a bottom sheet or popup in your Android app

USE CASE 2

Apply real-time background blur to a floating overlay or action menu

USE CASE 3

Blur a static bitmap or view programmatically for image processing features in your app

Tech stack

JavaAndroid

Getting it running

Difficulty · easy Time to first run · 30min
Use freely for any purpose, including commercial projects, as long as you keep the copyright notice.

In plain English

BlurKit is an Android library that makes it easy to add real-time blur effects to parts of your app's screen. It works similarly to the frosted glass effect common on iOS, where a floating panel shows a blurred version of whatever is behind it. BlurKit brings that same kind of live background blurring to Android apps. The main component is BlurLayout, a view you add to your XML layout file just like a button or image. Once wired up in your Activity code, it continuously captures and blurs whatever content sits behind it in real time. You control how strongly things are blurred with a radius setting, and you control the frame rate. If the content behind the blur rarely changes, you can set the frame rate to zero and manually refresh only when needed, which saves battery and CPU time. Performance is a stated priority. The README includes benchmark numbers comparing BlurKit against a generic blurring approach. BlurKit retrieves and blurs a 300 by 100 dp region in about 1 to 2 milliseconds per step, compared to 8 to 50 milliseconds for the unoptimized approach. This is achieved by downscaling the captured bitmap before blurring it, since blurring a smaller image and scaling it back up is much faster than blurring at full resolution and produces visually similar results. Beyond the layout component, the library also exposes a BlurKit class you can use directly to blur any View or Bitmap by passing it a radius value. A fastBlur method adds the downscale optimization for view blurring specifically. Setup requires adding one line to your app's build.gradle dependencies block. The library is MIT licensed and is a companion project to CameraKit, another Android library from the same team. The README lists a few planned features that were not yet complete at the time of writing, including support for SurfaceView and use inside dialog windows.

Copy-paste prompts

Prompt 1
Show me how to add BlurLayout from blurkit-android to my XML layout file and configure the blur radius and frame rate in my Activity code
Prompt 2
I want a frosted-glass bottom sheet in my Android app. Using blurkit-android, how do I make the background blur update in real time as content behind it changes?
Prompt 3
How do I use blurkit-android's fastBlur method to blur a Bitmap directly without using a BlurLayout in my view hierarchy?
Prompt 4
Help me minimize battery drain from blurkit-android by setting the frame rate to zero and triggering manual refreshes only when my UI updates
Open on GitHub → Explain another repo

← camerakit on gitmyhub — every repo by this author, as a profile.

Verify against the repo before relying on details.