Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support eventual deprecation #2

Open
cscott opened this issue Jan 28, 2013 · 3 comments
Open

Support eventual deprecation #2

cscott opened this issue Jan 28, 2013 · 3 comments

Comments

@cscott
Copy link

cscott commented Jan 28, 2013

As far as I understand it, the backing data for the canvas is slated to eventually be "auto-retinified" via the getImageDataHD etc methods (see http://www.whatwg.org/specs/web-apps/current-work/multipage/the-canvas-element.html#dom-context-2d-getimagedatahd ).

Ideally this component should future-proof the canvas and not do the "scale by 2x" hack if the *HD() methods are present on the canvas. (It might also want to wrap getImageData and other methods so that the *HD version is called iff present.)

@tj
Copy link
Member

tj commented Jun 5, 2013

I don't really get what they're going for, I dont see how HDPI displays have anything to do with bitmaps really, seems odd but maybe im missing something

@cscott
Copy link
Author

cscott commented Jun 5, 2013

@visionmedia the question is how many actual pixels are in your bitmap. The web spec says that the dimensions of your canvas are "css pixels", which don't have a fixed relationship to real pixels any more in this brave new world of HDPI displays. So the idea is that the canvas will allocate as many "real pixels" as necessary to make your bitmap look good at the given size in CSS pixels. This makes most uses of canvas automagically appear sharper. But some users will need to get at the actual literal backing store...

@tj
Copy link
Member

tj commented Jun 6, 2013

yeah I suppose that would be more efficient than what we're doing here haha. interestingly Safari does not seem to define those but it does already go ahead with the rest

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants