[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    getting binary information of a QPixmap
From:       Pupeno <pupeno () kde ! org>
Date:       2003-10-29 12:45:59
[Download RAW message or body]

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Do you know what's the best way to get the binary data of a QPixmap (and build 
a QPixmap out of that binary data) (than saving the QPixmap to a file and 
opening directly and viceversa) ?
I tried it converting it to QImage (image) and then (I need to store it in a 
text file, that's why I encode it):
QCString imageBuffer(reinterpret_cast<char *>(image.bits()), 
image.numBytes());
QCString imageBufferEncoded = KCodecs::uuencode(imageBuffer);

and the resulting imageBufferEncoded may even be empty... even imageBuffer 
seems to be empty some times although numBytes() for my images is always the 
same.
Any idea how to do this succesfully ?

Thank you.
- -- 
Pupeno: pupeno@kde.org
http://www.kde.org
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.2 (GNU/Linux)

iD8DBQE/n7aJLr8z5XzmSDQRAsHeAKDCp7/GV397bX9nMfjiC25f/8nocwCgxjbK
RCl+U8eYcid6mUaZqTeJvfY=
=MPGi
-----END PGP SIGNATURE-----

 
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic