title: how to optimize image like Facebook and WhatApp does?
body: <p>I want to optimize the Image file size like whatsapp and facebook are doing. I have send 5MB Image on whatsapp, And received image has size of 80KB. Received image looks identical to the original ones but resolution is less than the original one.</p>
  
  <p>I tried almost all the source codes of android image compression available on stackoverflow but that doesn't work for me. And then i came across <a href="http://voidcanvas.com/whatsapp-like-image-compression-in-android/" rel="noreferrer">this link</a> to optimize the image, which is doing good work but still not getting the result like whatsapp.</p>
  
  <p>How can i achieve maximum image compression without degrading the quality of image, Same like whatsapp did? </p>
  
  <p>Answer with a source code will be very helpful.</p>
  
  <p>Thanks In advance.</p>