Canvas does not render scaled SVG image

Confirmed Issue #4624032 • Assigned to Kevin B.

Details

Created
Sep 17, 2015
Privacy
This issue is public.
Reports
Reported by 0 people

Sign in to watch or report this issue.

Steps to reproduce

URL:

Repro Steps:

Canvas drawImage() does not render the image if the image is cropped from it’s original size if the image is an SVG. (It works for non SVG images).

Say if the SVG image is of size 41x51, then the following code does not work:

var canvas = document.getElementById(‘canvas’);
var image = …
ctx.drawImage(image, 0, 0, 42, 51, 0, 0, 41, 51);

Note that the 4th argument is 42 instead of 41. (Anything other than 41 doesn’t work).

Please see the plunkr at: http://plnkr.co/edit/kEMS7G?p=preview

Expected Results:

SVG is supposed to render

Actual Results:

Dev Channel specific:

No

Attachments

0 attachments

    Comments and activity

    • Microsoft Edge Team

      Changed Assigned To to “Mara P.”

      Changed Assigned To to “Rossen A.”

      Changed Assigned To from “Rossen A.” to “Kevin B.”

      Changed Status to “Confirmed”

    You need to sign in to your Microsoft account to add a comment.

    Sign in