How to wrap a photo around an object online automatically?

Hi! my client wants to wrap a photo around the user selected object like, mug, T shirt etc once upload the image online automatically. To get more clear please go through the following link just for reference

http://photographxunlimited.lifepics…lt.aspx?cat=21

will you please provide me some relevant tutorial links?

Hope someone comeup with some solution.

Thanks in advance.