Current version

v1.10.4 (stable)

Navigation

Main page
Archived news
Downloads
Documentation
   Capture
   Compiling
   Processing
   Crashes
Features
Filters
Plugin SDK
Knowledge base
Contact info
Forum
 
Other projects
   Altirra

Search

Archives

01 Dec - 31 Dec 2013
01 Oct - 31 Oct 2013
01 Aug - 31 Aug 2013
01 May - 31 May 2013
01 Mar - 31 Mar 2013
01 Feb - 29 Feb 2013
01 Dec - 31 Dec 2012
01 Nov - 30 Nov 2012
01 Oct - 31 Oct 2012
01 Sep - 30 Sep 2012
01 Aug - 31 Aug 2012
01 June - 30 June 2012
01 May - 31 May 2012
01 Apr - 30 Apr 2012
01 Dec - 31 Dec 2011
01 Nov - 30 Nov 2011
01 Oct - 31 Oct 2011
01 Sep - 30 Sep 2011
01 Aug - 31 Aug 2011
01 Jul - 31 Jul 2011
01 June - 30 June 2011
01 May - 31 May 2011
01 Apr - 30 Apr 2011
01 Mar - 31 Mar 2011
01 Feb - 29 Feb 2011
01 Jan - 31 Jan 2011
01 Dec - 31 Dec 2010
01 Nov - 30 Nov 2010
01 Oct - 31 Oct 2010
01 Sep - 30 Sep 2010
01 Aug - 31 Aug 2010
01 Jul - 31 Jul 2010
01 June - 30 June 2010
01 May - 31 May 2010
01 Apr - 30 Apr 2010
01 Mar - 31 Mar 2010
01 Feb - 29 Feb 2010
01 Jan - 31 Jan 2010
01 Dec - 31 Dec 2009
01 Nov - 30 Nov 2009
01 Oct - 31 Oct 2009
01 Sep - 30 Sep 2009
01 Aug - 31 Aug 2009
01 Jul - 31 Jul 2009
01 June - 30 June 2009
01 May - 31 May 2009
01 Apr - 30 Apr 2009
01 Mar - 31 Mar 2009
01 Feb - 29 Feb 2009
01 Jan - 31 Jan 2009
01 Dec - 31 Dec 2008
01 Nov - 30 Nov 2008
01 Oct - 31 Oct 2008
01 Sep - 30 Sep 2008
01 Aug - 31 Aug 2008
01 Jul - 31 Jul 2008
01 June - 30 June 2008
01 May - 31 May 2008
01 Apr - 30 Apr 2008
01 Mar - 31 Mar 2008
01 Feb - 29 Feb 2008
01 Jan - 31 Jan 2008
01 Dec - 31 Dec 2007
01 Nov - 30 Nov 2007
01 Oct - 31 Oct 2007
01 Sep - 30 Sep 2007
01 Aug - 31 Aug 2007
01 Jul - 31 Jul 2007
01 June - 30 June 2007
01 May - 31 May 2007
01 Apr - 30 Apr 2007
01 Mar - 31 Mar 2007
01 Feb - 29 Feb 2007
01 Jan - 31 Jan 2007
01 Dec - 31 Dec 2006
01 Nov - 30 Nov 2006
01 Oct - 31 Oct 2006
01 Sep - 30 Sep 2006
01 Aug - 31 Aug 2006
01 Jul - 31 Jul 2006
01 June - 30 June 2006
01 May - 31 May 2006
01 Apr - 30 Apr 2006
01 Mar - 31 Mar 2006
01 Feb - 29 Feb 2006
01 Jan - 31 Jan 2006
01 Dec - 31 Dec 2005
01 Nov - 30 Nov 2005
01 Oct - 31 Oct 2005
01 Sep - 30 Sep 2005
01 Aug - 31 Aug 2005
01 Jul - 31 Jul 2005
01 June - 30 June 2005
01 May - 31 May 2005
01 Apr - 30 Apr 2005
01 Mar - 31 Mar 2005
01 Feb - 29 Feb 2005
01 Jan - 31 Jan 2005
01 Dec - 31 Dec 2004
01 Nov - 30 Nov 2004
01 Oct - 31 Oct 2004
01 Sep - 30 Sep 2004
01 Aug - 31 Aug 2004

Stuff

Powered by Pivot  
XML: RSS feed 
XML: Atom feed 

§ TARGA compatibility problem

Public service announcement:

If you are writing TARGA image files with run-length encoding, you should be aware that according to the official Truevision specification, it is not legal in the TARGA format to produce a run that spans scanlines. The TARGA decoder in current versions of VirtualDub strictly validates the RLE data and will flag files with RLE decoding errors if runs spanning scanlines are detected. Unfortunately, many image processing applications do not enforce this restriction and will accept such invalid files, and there are some programs out there that generate them. As much as I hate to do this, I'll probably be tweaking the TARGA decoder in the next version to allow runs that span scanlines, and probably without the evil warning that I usually do (since it's hard to do so with image import).

So, if you're making a TARGA encoder, please make sure you are not generating invalid RLE runs, and if you're making a TARGA decoder, be aware that you're going to see those in the wild, despite what the spec says.

 

Comments

Comments posted:


I wish some of these older formats would become extinct. I don't see any valid reason for the existance of the TARGA format, the same capabilities are included in other formats (PNG/TIFF/etc...).

Blight - 18 04 06 - 14:13


Yes, but those formats are harder to generate, and an order of magnitude harder to read. This is a major issue if, for some reason, it is impractical to bring in libpng/libtiff.

PNG uses Deflate as its compression algorithm, which is non-trivial to write a compressor for, and which requires 32K of memory for the sliding window to decompress. It actually takes more code and much more memory to implement PNG read/write support than to implement JPEG read/write, which only requires a pittance of temporary memory for a few blocks worth of image.

TIFF had the annoyance of using LZW and also suffers from tag disease: it's easy to write because it can hold anything (including JPEG), but it's horrendous to read for the same reasons.

TARGA at least has the advantage of being almost as easy to read and write as BMP, but it has RLE support for truecolor, as well as explicit alpha channel support. Anyone can hack together a TARGA writer in a couple hours at most. If you have bitmaps that RLE well, like masks, and you need very fast decompression, TGA is a better choice than PNG.

Phaeron - 19 04 06 - 02:10


FYI, you can compress PNGs with a smaller zlib window, which will reduce the amount of memory needed to decompress. pngcrush -w will do this.

Glenn Maynard - 19 04 06 - 08:38


After diligent lecture of the above,
as well as the the articles "TGA", "PNG" and "Grafikformate" of the german Wikipedia,
after arguing with my colleague about my assumed outdatedness of TIF and TGA,
after testing a .tif>.png batch conversion with IrfanView (with PNGOUT-PlugIn AND without),
not finding any Alpha Channels in PNGs saved and/or opened with Photoshop,
i am forced to correct my opinion of graphic formats and compression a bit
and might add my humble opinion to this concern as follows:

-The greatest pity is the very very poor implementation and configurability of PNG-capabilities within the obove mentioned software. Also, the compression of .png lasts too long.
-Unfortunately the common "Export" and "Properties" dialogues do not offer enough transparence about the actual header-data that's contained within or to be written into TIFs and PNGs.
-All in all i'm so very thankful for every single tiny hour som,eone spends in development of importers and exporters. How much of a difference this makes!
Apparently it is impractical for Phaeron to "share" import filters with other Developers.

Hopefully, however, one day we'll be able to drag PNGs and TIFs into VirtualDub as well.

Greets from Cologne, Germany
blausand

blausand (link) - 16 08 06 - 14:42

Comment form


Please keep comments on-topic for this entry. If you have unrelated comments about VirtualDub, the forum is a better place to post them.
Name:  
Remember personal info?

Email (Optional):
Your email address is only revealed to the blog owner and is not shown to the public.
URL (Optional):
Comment: /

An authentication dialog may appear when you click Post Comment. Simply type in "post" as the user and "now" as the password. I have had to do this to stop automated comment spam.



Small print: All html tags except <b> and <i> will be removed from your comment. You can make links by just typing the url or mail-address.