One of the main reasons to use Drupal is to minimize how much custom code needs to be maintained for a website. Every unique problem can be decomposed into the same problems that everyone has.
The Imgfly module delivers on-the-fly images for responsive layouts with minimum configuration. The module uses a javascript code that determines the width of the parent element that holds the image and thus requests an image that will be dynamically generated to requested size. For optimal performance you need to have a reverse proxy caching mechanism on your site like Varnish or Squid to cache and deliver the dynamically generated images.
Features
Images are generated dynamically (on-the-fly).
Images are delivered in precisely the right size required unlike other responsive image modules that deliver slightly larger images and scales them down to fit.
Image sizes can be controlled by CSS on the parent elements containing the image element.
Minimal configuration required with Image presets unlike other modules that require you to create many presets for each size format you wish to deliver.
Width and height parameters are part of the image URL so you can use this to programatically call any image in any size format desired.
Lazy loading of images is now possible in the beta2 version.
Requirements
Highly recommended to use a reverse proxy caching mechanism like Varnish or Squid.
This module goes to great lengths to implement generic-purpose loading of the site's pages via Ajax, with the possibility to create region(s) that will be exempt from such loading. A concrete example of using this functionality is putting a persistent audio player on your website that would continue playing as the user browses the pages.