title: Mosaic Grid gallery with dynamic sized images
body: <p>I have just received the following design for a project, for an image grid gallery, with dynamic width &amp; height images (user submitted images). (Screenshot at the end of post)</p>
  
  <p>I have tried <a href="http://masonry.desandro.com/">jQuery Masonry</a>, <a href="http://tympanus.net/codrops/2011/08/30/automatic-image-montage/">Tympanus Automatic Image Montage</a> and <a href="http://css-tricks.com/seamless-responsive-photo-grid/">CSS-Tricks Seemless Responsive Photo Grid</a>, but each has their limitation.</p>
  
  <ul>
  <li>Jquery Masonry allows for both width and height to be dynamic, however there are gaps generated</li>
  <li>The latter 2 scripts, generate very nice grids, but with the problem that either width or height must be static</li>
  </ul>
  
  <p><strong>EDIT:</strong> i came across, <a href="http://isotope.metafizzy.co/index.html">Isotope</a>, which is almost perfect and i will probably end up using it, unless there's something that fixes my needs exactly. Therefore my question still remains the same...</p>
  
  <p>Is there any javascript (preferably jQuery) script that can generate a completely dynamic mosaic (in respect to image size), like the one in the screenshot below?</p>
  
  <p>Thanks for any help</p>
  
  <hr>
  
  <p><img src="https://i.stack.imgur.com/39NiL.jpg" alt="Gallery"></p>