Return-Path: <tiff-bounces@remotesensing.org>
Received: from xserve.flids.com (adsl-065-083-169-202.sip.mco.bellsouth.net [65.83.169.202])
        by inmx012.isp.belgacom.be (8.12.11/8.12.11/Skynet-IN-2.32) with ESMTP id j57IhmKa032252
        for <joris.at.lebbeke@skynet.be>; Tue, 7 Jun 2005 20:43:51 +0200
        (envelope-from <tiff-bounces@remotesensing.org>)
Received: from adsl-065-083-169-202.sip.mco.bellsouth.net (localhost [127.0.0.1])
	by xserve.flids.com (Postfix) with ESMTP
	id DD94E25F1663; Tue,  7 Jun 2005 14:43:31 -0400 (EDT)
X-Original-To: tiff@remotesensing.org
Delivered-To: tiff@remotesensing.org
Received: from scooby.simplesystems.org (scooby.simplesystems.org
	[65.66.246.67])
	by xserve.flids.com (Postfix) with ESMTP id 7895125F1653
	for <tiff@remotesensing.org>; Tue,  7 Jun 2005 14:43:30 -0400 (EDT)
Received: from blade.simplesystems.org (blade.simplesystems.org [65.66.246.74])
	by scooby.simplesystems.org (8.12.10+Sun/8.12.10) with ESMTP id
	j57IhTAi029138
	for <tiff@remotesensing.org>; Tue, 7 Jun 2005 13:43:29 -0500 (CDT)
Date: Tue, 7 Jun 2005 13:43:29 -0500 (CDT)
From: Bob Friesenhahn <bfriesen@simple.dallas.tx.us>
X-X-Sender: bfriesen@blade.simplesystems.org
To: Tiff List <tiff@remotesensing.org>
Message-ID: <Pine.SOC.4.60.0506071333130.12047@blade.simplesystems.org>
MIME-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed
Subject: [Tiff] Group4 compression & alpha channel
X-BeenThere: tiff@remotesensing.org
X-Mailman-Version: 2.1.2
Precedence: list
List-Id: TIFF and libtiff discussion  <tiff.remotesensing.org>
List-Unsubscribe: <http://xserve.flids.com/mailman/listinfo/tiff>,
	<mailto:tiff-request@remotesensing.org?subject=unsubscribe>
List-Archive: <http://xserve.flids.com/pipermail/tiff>
List-Post: <mailto:tiff@remotesensing.org>
List-Help: <mailto:tiff-request@remotesensing.org?subject=help>
List-Subscribe: <http://xserve.flids.com/mailman/listinfo/tiff>,
	<mailto:tiff-request@remotesensing.org?subject=subscribe>
Sender: tiff-bounces@remotesensing.org
Errors-To: tiff-bounces@remotesensing.org
X-UIDL: 000000000023ceae.00000355
X-MSP-STORE: Tue, 07 Jun 2005 20:43:59 +0200
Status:   

It has been observed that when GraphicsMagick writes a min-is-black 
TIFF image with Group4 compression and an alpha channel (as an extra 
sample) that the right half of the image is lost.  The image 
description is:

TIFF Directory at offset 0x0
   Image Width: 207 Image Length: 167
   Bits/Sample: 1
   Sample Format: unsigned integer
   Compression Scheme: CCITT Group 4
   Photometric Interpretation: min-is-white
   Extra Samples: 1<unspecified>
   FillOrder: msb-to-lsb
   Orientation: row 0 top, col 0 lhs
   Samples/Pixel: 2
   Rows/Strip: 167
   Planar Configuration: single image plane
   DocumentName: muki.tif
   Software: GraphicsMagick 1.2 unreleased Q16 
http://www.GraphicsMagick.org/

I strongly suspect that this loss of data is due to libtiff but have 
not done a thorough investigation yet to make absolutely sure.  The 
same occurs when using FAX compression.

By simply not requesting Group4 or FAX compression, the file is saved 
and read ok.  This works:

TIFF Directory at offset 0x0
   Image Width: 207 Image Length: 167
   Bits/Sample: 1
   Sample Format: unsigned integer
   Compression Scheme: None
   Photometric Interpretation: min-is-black
   Extra Samples: 1<unspecified>
   FillOrder: msb-to-lsb
   Orientation: row 0 top, col 0 lhs
   Samples/Pixel: 2
   Rows/Strip: 157
   Planar Configuration: single image plane
   DocumentName: muki.tif
   Software: GraphicsMagick 1.2 unreleased Q16 
http://www.GraphicsMagick.org/

Are there any known issues in libtiff with this scenario?

Bob
======================================
Bob Friesenhahn
bfriesen@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer,    http://www.GraphicsMagick.org/
_______________________________________________
Tiff mailing list: Tiff@remotesensing.org
http://xserve.flids.com/mailman/listinfo/tiff
http://www.remotesensing.org/libtiff/
