Im Looking to lower the Resolution of Qpixmap cropped that is then saved a png
QPixmap original(imgPath); // read in the image that was selected from tree
QPixmap cropped = original.copy(cropRectInt); // make copy of image that is cropped to the size of the rect
//***Convert cropped to lower res here***//
QFile file("5.png");
cropped.save(&file, "PNG"); // save for testing
QByteArray byteArray;
QBuffer buffer(&byteArray);
cropped.save(&buffer, "PNG");
QString imgBase64 = QString::fromLatin1(byteArray.toBase64().data());