View difference between Paste ID: 7NwFArQD and X4Vfp3LF
SHOW: | | - or go back to the newest paste.
1-
#include <iomanip>
1+
2-
#include <iostream>
2+
3
int main(int argc, char *argv[])
4
{        
5
    QImage src("../GIL_with_Qt/images_00/lena/lena.jpg");
6
    src = src.convertToFormat(QImage::Format_Indexed8);
7
    QImage dst(src.size(), src.format());
8
    
9
    dst.save("E:/lena/lena_Format_Indexed8.jpg"); //this line will cause the program crash
10
11
    return 0;
12
}