[whatwg] Canvas and transforms
Ian Hickson
ian at hixie.ch
Fri May 19 01:03:56 PDT 2006
On Fri, 30 Dec 2005, Erik Arvidsson wrote:
>
> I might have missed something but why isn't there a generic transform
> method for the CanvasRederingContext2D. Currently there are scale,
> rotate and translate. Adding a generic transform might make a few things
> easier.
>
> void translate(in float m11, in float m12, in float m21, in float m22);
> void translate(in float m11, in float m12, in float m21, in float m22, in
> float dx, in float dy);
>
> where the arguments are the numbers in the transformation matrix
>
> m11 m12 dx
> ( m21 m22 dy )
> 0 0 1
>
> dx and dy are 0 when left out
On Thu, 5 Jan 2006, Dean Jackson wrote:
>
> s/translate/transform/
> and I don't think it's worth having the first method.
Added transform() and setTransform(). The first multiplies the current
transform with a new one. setTransform resets it first.
--
Ian Hickson U+1047E )\._.,--....,'``. fL
http://ln.hixie.ch/ U+263A /, _.. \ _\ ;`._ ,.
Things that are impossible just take longer. `._.-(,_..'--(,_..'`-.;.'
More information about the whatwg
mailing list