Canvas repaints slowly when scaled

NEW
Unassigned

Status

()

Core
Graphics
10 years ago
8 years ago

People

(Reporter: Vladimir Slepnev, Unassigned)

Tracking

Trunk
x86
Windows XP
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(URL)

(Reporter)

Description

10 years ago
User-Agent:       Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.9) Gecko/20071025 Firefox/2.0.0.9
Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.9) Gecko/20071025 Firefox/2.0.0.9

If the "width" and "height" attributes of the canvas tag aren't equal to its actual width and height on screen, drawing becomes much slower. Machine is 3GHz Pentium, I draw 4 lines in fullscreen at every frame, framerate drops to single digits. Testcase attached.

Reproducible: Always

Steps to Reproduce:
Open the testcase from the URL field. Expand window to fullscreen. Move the mouse around. Click to switch slow/fast.

Updated

10 years ago
Status: UNCONFIRMED → NEW
Ever confirmed: true

Updated

10 years ago
Component: General → GFX
Product: Firefox → Core
QA Contact: general → general
Just took a guess on component, but pretty sure this is a core bug. Could be all gone on the trunk (pre-beta Firefox 3). Good to understand in any event.

/be
The width and height attributes correspond to the width and height of the image in the canvas (the size of the bitmap).

If the size on screen is different, the bitmap needs to be scaled on every draw operation (as with any image).

This is, of course, slower than just painting it without scaling.

For what it's worth, the testcase is just slow here no matter what I do, both in "slow" and "fast" mode.  ;)
(Assignee)

Updated

9 years ago
Product: Core → Core Graveyard

Updated

9 years ago
Component: GFX → GFX: Thebes
Product: Core Graveyard → Core
QA Contact: general → thebes
Version: unspecified → Trunk
You need to log in before you can comment on or make changes to this bug.