Hi,
Can anyone help me on the following please, thanks in advance:
Common sense and some experimentation shows that if you need to just scale and translate (and not rotate) an image, the order of operations should not be important. So scaling an image 200% and then translating it 10% in x-axis would give the same output as translating it 10% in x-axis and then scaling it 200%. You can do some thought experiment or use Photoshop or even Paint to verify this.
Now check the following. This is how a Matrix would represent these two operations. Here we do a scaling following by a translation (themiddle one is a 2x2 scaling matrix, and thenext one is the translation matrix):
[xy]*[m 0] + [a b] = [mx + amy + b]
[0 m]
And on the other hand, we change the order:
[xy]+ [a b]*[m 0]= [mx + mamy + mb]
[0 m]
See the change! Can anyone tell me if I am doing anything wrong here, or if order of operations is really important and the common sense is missing something.
Shujaat