I already blogged about this, but I saw that some items could use some more explanation. Please read “Getting the displacement you need” first for the basic idea.
In short the principle is:
- you have a reference map, say A
- you apply a distortion effect to the reference map created a distorted version of A say A’
- you calculate the displacement map that could transform A into A’ by calculating the difference in pixel value between A and A’
Some important points before we start: