TGA support for KDE

Dominik Seichter domseichter at web.de
Sun Jan 26 21:37:11 GMT 2003


Am Sonntag, 26. Januar 2003 15:37 schrieb Malte Starostik:
> On Sunday 26 January 2003 14:38, Waldo Bastian wrote:
> > On Sunday 26 January 2003 12:55, Dominik Seichter wrote:
> > > The code works in a separate application of mine very well, when
> > > registered with QImageIO::defineIOHandler( ... ). But it does not work
> > > at all when installed as a kimgio plugin, because KDE does not call the
> > > TGA plugin when I try to load an TGA file. Maybe my tga.kimgio is wrong
> > > or my changes to the makefile were incorrect.
> >
> > Your .kimgio file should define a Header entry that can be used to
> > identify a TGA file. This header entry is a regexp, see
> > qimageio.html#defineIOHandler for details. Non-ascii chars should be
> > encoded like this:
> >
> > 	Header=^\x01\x01\x01\x0C\x6A\x50
>
> FWIW, and make sure that if you have to match a 0-byte to use \x01 instead
> as Qt uses this to distinguish it from the string terminator.
Thanks for the tip, it works now for RLE compressed tga files, but 
uncompressed files are still not recogniced.

RLE compressed TGA files start with 0x00 0x00 0x0a and I use the following 
header to match them: ^\x01\x01\x0a
Uncommpressed TGA images start with 0x00 0x00 0x02, but I can't match them 
using the header ^\x01\x01\x02 . What is wrong with this reg expression?

CU Dom
-- 
************************************************************
Dominik Seichter - domseichter at web.de
Krename - http://www.krename.net
KBarcode - http://www.kbarcode.net
************************************************************





More information about the kde-core-devel mailing list