cashapp / paparazzi

Render your Android screens without a physical device or emulator
https://cashapp.github.io/paparazzi/
Apache License 2.0
2.23k stars 211 forks source link

Fix predraw callbacks on every frame #1380

Closed gamepro65 closed 2 months ago

gamepro65 commented 2 months ago

Noticed onPreDraw stopped getting callbacks for subsequent frames in an animation. Previously RenderSessionImpl manually called AttachInfo_Accessor.dispatchOnPreDraw(viewRoot); however that logic has been removed in favor of ThrededRenderer handling it.

Poking around AS I noticed their subsequent onPreDraw callbacks get invoked because they go down a different render code path using FLAG_KEY_DISABLE_BITMAP_CACHING

Looking at RenderTask we can see they set it.