This might be a silly question... but something I'...
# compose-android
c
This might be a silly question... but something I'd use to do in the view system (like pre lollipop or something) would be to put a CircularProgressBar on the screen and if it stutters then you know you'd be doing something on the main thread. It was a trivial way to test for jank. This was later changed in views to render on the renderThread but you could disable the renderThread in the manifest or something. Is there a way to do that in compose? i.e. I just want to put a circular progress bar on the screen and see if some of my background code is causing jank.
z
StrictMode? 😃
y
Maybe wire up JankStats as a State and display that? Turn the frame metrics into something visible?
j
b
You could also use the Profile HWUI rendering setting in developer options, it draws a graph on your screen to show jank https://developer.android.com/topic/performance/rendering/inspect-gpu-rendering
2
t
HWUI for ever also help finding things like https://issuetracker.google.com/issues/297231233