Difference between translation and transform in canvas


I am not experienced in this subject and iam a very new bee in html5. As per my understanding, we will use transform in a translation scenario.

Lets go to mathematics matrix representation:

say we have 1,tx,ty,1 in a 2×2 matrix. tx =2,ty=4. if we translate that matrix..it changes from 1,2,4,1 to 1,4,2,1.

So x & y coordinates have been changed which impacts on visual representation like object starts from x=4 and y=2 position.Previously object is in x=2 and y=4 position.

For better understanding see the image below:


Source: http://blog.carbonfive.com/2011/03/31/taming-2d-transforms/

Lets make it simple like this for now…


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s