title: Qt resize image with best quality
body: <p>Can anyone help me resize an image in qt without making the image pixelated.
  Here's my code. the result is not as good as the original quality..thanks...</p>
  
  <pre><code>QImage img(name);
  QPixmap pixmap;
  pixmap = pixmap.fromImage(img.scaled(width,height,Qt::IgnoreAspectRatio,Qt::FastTransformation));
  QFile file(folder+"/"+name);
  file.open(QIODevice::WriteOnly);
  pixmap.save(&amp;file, "jpeg",100);
  file.close();
  </code></pre>