Hello,
I have try to find the answer, but didn't have found one. I have a small problem to write NULL character to a file, the problem is that the character is not write.
Could somebody help me ?
I have tried with QDataStream but It's add many NULL char that I don't want.
Thanks.
This is the code that I use :
Qt Code:
return; QRgb* rgb = (QRgb*)image.scanLine(0); for (int x = 0; x < image.width(); x++) { int AlphaValue = qAlpha(rgb[x]); int RedValue = qRed(rgb[x]); int GreenValue = qGreen(rgb[x]); int BlueValue = qBlue(rgb[x]); file.write(qPrintable(AlphaAscii)); //file.write((const char *)AlphaAscii.toAscii()); } file.close();To copy to clipboard, switch view to plain text mode
Bookmarks