Skip to content

Instantly share code, notes, and snippets.

View yschimke's full-sized avatar

Yuri Schimke yschimke

View GitHub Profile
@yschimke
yschimke / CaptureComposable.kt
Created August 17, 2024 18:24 — forked from iamcalledrob/CaptureComposable.kt
Android headless composable capture
import android.app.Presentation
import android.content.Context
import android.graphics.Bitmap
import android.graphics.Picture
import android.graphics.SurfaceTexture
import android.hardware.display.DisplayManager
import android.view.Display
import android.view.Surface
import android.view.ViewGroup
import androidx.compose.foundation.layout.Box