Thiago
11/30/2020, 12:53 PMZach Klippenstein (he/him) [MOD]
11/30/2020, 1:56 PMZach Klippenstein (he/him) [MOD]
11/30/2020, 1:57 PMLaunchedEffect and awaitFrame in a loopThiago
11/30/2020, 2:14 PMJoost Klitsie
11/30/2020, 2:20 PMJoost Klitsie
11/30/2020, 2:20 PMZach Klippenstein (he/him) [MOD]
11/30/2020, 2:32 PMGood to know about 1:1Don’t quote me on that, and don’t rely on it 😜 I think that it’s usually 1:1 currently but I don’t believe that’s part of the contract so it’s not safe to rely on for stuff like this. If you are actually building real animations and not just exploring the tech, definitely use the actual animation apis.
Adam Powell
11/30/2020, 3:30 PMCanvas isn't run during composition, it's run during the drawing phase. It's correct that something might be drawn multiple times for a single frame in some potentially esoteric casesAdam Powell
11/30/2020, 3:31 PMCanvas should not invalidate that same drawing handler to produce a subsequent frameAdam Powell
11/30/2020, 3:32 PMLaunchedEffect and withFrameNanos (not the kotlinx.coroutines awaitFrame!) to run a loop that updates your state based on timeThiago
11/30/2020, 5:49 PMLaunchedEffect and withFrameNanos 😅. Constant remembers was a mistake after a refactor. I'll check them out.