microsoft / Windows-appsample-coloringbook

UWP sample app demonstrating Inking, Surface Dial support, and printing
169 stars 71 forks source link

Pinch-to-zoom crashes app #5

Open diiq opened 5 years ago

diiq commented 5 years ago

Hi there! It seems like pinch-to-zoom crashes this example app.

Steps to reproduce:

Zooming in far enough crashes the app (you don't have to zoom very far — one un-pinch seems to be enough most times).

The exception's error message is "Cannot create CanvasImageSource sized [X BY Y]; MaximumBitmapSizeInPixels for this device is [X - 1]," where X and Y are, I assume, device-specific.

A maximum zoom makes sense, but the app should probably disallow zooming past that point, rather than crashing irrecoverably.

Even not having zoom at all might be better than a sample app that crashes...

Karl-Bridge-Microsoft commented 4 years ago

Thanks @diiq. I'm currently updating the sample, so maybe I can look after this too.

diiq commented 4 years ago

I was on a Surface Studio 2 when I encountered the crash, if that helps -- so the screen might have been bigger than the original developer expected.