Hi, i share with my app a screenshot of view, full...
# compose
a
Hi, i share with my app a screenshot of view, full page.. so it works well but when i use and AndroidView i don’t see image or video inside AndroidView. Code in thread
Copy code
val view = LocalView.current
val handler = Handler(Looper.getMainLooper())
handler.postDelayed(Runnable {
    val bmp = Bitmap.createBitmap(
        view.width, view.height,
        Bitmap.Config.ARGB_8888
    ).applyCanvas {
        view.draw(this)
    }
    bmp.let {
        viewModel.shareFile(bmp)
    }
}, 500)
This code works in every screen but if i use and AndroidView for example to use ExoPlayer i don’t see the content of AndroidView
I use a Box and put AndroidView and a Text and bitmap has this text..
e
not a Kotlin or Compose issue. SurfaceView is not drawn like other views, it is composited on afterwards.
a
so i have to get a bitmap from SurfaceView and put in my screen and after create my bitmap
ok i used Pixel and it works