Replies: 4 comments
-
The canvas is rendered using an underlying WebView. |
Beta Was this translation helpful? Give feedback.
-
Ok but is there a way to create 2 canvases in the same webview to enable
double-buffering? That might solve the flickering problems we encounter
when making animations with this library.
…On Sat, 26 Jun 2021, 22:10 Iddan Aaronsohn, ***@***.***> wrote:
The canvas is rendered using an underlying WebView.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#220 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAJRIAOIGGQXD7H77655S6TTUYXZ5ANCNFSM47GDQ5IA>
.
|
Beta Was this translation helpful? Give feedback.
-
Currently no, how do you imagine the solution to work like? |
Beta Was this translation helpful? Give feedback.
-
From the top of my head I'd say that there are 2 possible approaches:
The result would be roughly the same. The component exposing the 2nd canvas would require the user to do the double-buffering (nowadays that's often done by the browsers) while the one hiding it away would require the user to add 2 lines of code to their project (one enabling the feature and one to tell the buffer canvas to move their content to the main one). I don't know if it is annoying to implement on your side but if you notice that this approach fixes flickering animations, I think it would be a great addition to the library. Let me know :) |
Beta Was this translation helpful? Give feedback.
-
I am trying to fix some awful flickering issues and normally one would create a
tempCanvas
to do all the drawing and then copy it to the real one.I tried to hack something like that together but I am getting weird results. Is it even possible to do this?
Normally one would do this (from: https://stackoverflow.com/a/10357038/1214469):
Beta Was this translation helpful? Give feedback.
All reactions