Last active
October 16, 2021 11:03
-
-
Save ch8n/bd42ef59098082aa62195016da0321e9 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Composable | |
fun CaptureBitmap(...){ | |
// we will use compose view as target to get bitmap | |
val composeView = ComposeView(...) | |
// put compose native view to compose ui using AndroidView | |
AndroidView( | |
factory = { | |
composeView.apply { | |
setContent { | |
.... put compose here | |
} | |
} | |
} | |
) | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment