In the last days I made some tests to serve different images based on the browsing device and I found a nice Ruby Gem: responsive-images

Here you can see my test project (using CarrierWave)

And my recipe: