toDataURL
/ fromDataURL
scaling with device pixel ratios > 1
#63
Labels
kind: support
Asking for support with something or a specific use case
scope: upstream
Issue in upstream dependency
solution: already possible
This is already possible / this feature already exists
solution: duplicate
solution: intended behavior
This is not a bug and is expected behavior
When serializing the canvas data with
toDataURL
and then again de-serializing the same data withfromDataURL
, the canvas content is not scaled correctly on device with a device pixel ratio larger than 1. The drawing is duplicated in the top left corner, scaled down:Here is a repro sandbox: https://codesandbox.io/s/elated-cookies-50yg2?file=/src/App.js
Try it on a device with pixel ratio 1, works fine, but on a retina screen or iphone you can observe the effect above. You can even use the iPhone emulator in chrome desktop.
The text was updated successfully, but these errors were encountered: