Chris Fillmore
04/27/2021, 1:21 AMAbstractComposeView
like below. The view is rendered to screen, but onDraw
is never called:
class CustomComposeView(...) : AbstractComposeView(...) {
// identical implementation to ComposeView
override fun onDraw(canvas: Canvas?) {
// This is never getting called
}
}
// elsewhere, added to Activity like so
activity.addContentView(customComposeView, layoutParams)
Should I expect onDraw to be called?
Are we discouraged from extending AbstractComposeView? Or is this generally supported?
I am doing this because I’m trying to draw a composition to an OpenGL texture. Essentially creating a kind of GlComposeView
. Thanks for any help!