UWP, Mapsui 2.0 - beta 35, SkiaSharp
Map blanks out when returning to it from a spawned child page.
This was tested in Mapsui.Forms, but it may exist in other implementation styles.
I created a small sample app to reproduce the issue:
Thanks a lot. Did this work properly for you in earlier versions? Which version did you first see this?
My mistake on the report -- I made the sample app using beta35.
Yes, it worked properly in previous versions. It broke somewhere between beta28 and beta32. I'd narrow it down further, but VS isn't letting me pick NuGets inbetween those versions for some reason.
I was able to narrow down a little futher. Looks like it happened somewhere between beta28 and beta30.
Thanks, that helps a lot.
The sample makes it very easy to test.
beta.28 works properly
beta.29 crashes immediately because skiasharp was updated but the nuspec wasn't
beta.30 shows the problem.
So it is caused by the skiasharp upgrade to 1.68.1, which is unfortunate because it is not under our control.
What if you try it with the 1.68.2 previews?
Good idea.
There were also some other changes, so it could be something else. Here are some commits in between the beta.29 and beta.28 tag:
https://github.com/Mapsui/Mapsui/commits/master?after=6f9c95579e6f223553f66d4a5310a504520ded03+209
Here the release notes of beta.29
https://github.com/Mapsui/Mapsui/releases/tag/2.0.0-beta.29
Xamarin.Forms upgrade is also a suspect.
skiasharp 1.68.2 previews does not fix it.
Latest stable Xamarin.Forms 4.4.0.99etc does not fix it.
I created a minimal reproduction for skiasharp based on you sample, but with Mapsui removed. I hope you don't mind.
I submitted a skiasharp issue:
https://github.com/mono/SkiaSharp/issues/1155
I assume, that this is the same problem as #677 and some others. It seems, that SkiaSharp miss to call OnPaintSurface when it is again visible on the screen. Don't no, if Skia is mentioned about this event, but than don't understand, why this should only be the case in Mapsui.
Well I can reproduce it without Mapsui. Let's hear what they say.
The paint event is called. I can see that in the debugger. Just nothing shows. Might be related to threading.
In such cases I saw, that the GrContext is null. Perhaps this is the reason, why it is only seen on SKGLView?
ah, I should check if GrContext is null.
I don't mind at all. Priority #1 is solving problems. :) Hopefully Skia has some insight.
GrContext is not null.
@spaddlewit Could you explain a bit more here about your use case: https://github.com/mono/SkiaSharp/issues/1155
Hey folks, just a quick update. I think I fixed the issue, see https://github.com/mono/SkiaSharp/issues/1155#issuecomment-609988075
@spaddlewit This issue should be fixed with rc.3.
Appears to be fixed. Thank you so much!
Could you then please close the issue?
Closing..