Received: from mailgate002.isp.belgacom.be (mailgate002.isp.belgacom.be [195.238.6.87])
	by maildelivery001.isp.belgacom.be (Postfix) with ESMTP id DA61D5A8002
	for <joris.at.lebbeke@skynet.be>; Sat, 18 Aug 2007 07:16:57 +0200 (CEST)
Received: from r153.dmsolutions.ca (HELO duke.maptools.org) ([209.217.116.153])
  by in.mx.skynet.be with ESMTP; 18 Aug 2007 07:16:54 +0200
Received: from duke.maptools.org (duke.maptools.org [127.0.0.1])
	by duke.maptools.org (8.12.11/8.12.10) with ESMTP id l7HJuTSj012816;
	Fri, 17 Aug 2007 15:56:39 -0400
Received: from sirius.rasena (e179202098.adsl.alicedsl.de [85.179.202.98])
	by duke.maptools.org (8.12.11/8.12.10) with ESMTP id l7HJuRfY012813
	for <tiff@lists.maptools.org>; Fri, 17 Aug 2007 15:56:27 -0400
Received: from sirius.rasena (localhost [127.0.0.1])
	by sirius.rasena (8.13.8/8.13.8/SuSE Linux 0.8) with ESMTP id
	l7HJvQof008654; Fri, 17 Aug 2007 21:57:29 +0200
Received: from localhost (kuwe@localhost)
	by sirius.rasena (8.13.8/8.13.8/Submit) with ESMTP id l7HJvQqR008651;
	Fri, 17 Aug 2007 21:57:26 +0200
X-Authentication-Warning: sirius.rasena: kuwe owned process doing -bs
Date: Fri, 17 Aug 2007 21:57:26 +0200 (CEST)
From: Kai-Uwe Behrmann <ku.b@gmx.de>
X-X-Sender: kuwe@sirius.rasena
To: Christian Henning <chhenning@gmail.com>
Subject: Re: [Tiff] How to write a planar tiff file
In-Reply-To: <949801310708171210j4de26bc2x3bad1d429605b27a@mail.gmail.com>
Message-ID: <Pine.LNX.4.64.0708172155280.6565@sirius.rasena>
References: <949801310708171200t73fe2ea5q34947d3efc918844@mail.gmail.com>
	<466E156D-2F4E-43E6-B348-A31D70F0AA05@smartgames.ca>
	<949801310708171209o6b60d93cp88032fdbb2bba49d@mail.gmail.com>
	<949801310708171210j4de26bc2x3bad1d429605b27a@mail.gmail.com>
MIME-Version: 1.0
Content-Type: MULTIPART/MIXED;
	BOUNDARY="-1463786751-856936922-1187380646=:6565"
Cc: libtiff - Liste <tiff@lists.maptools.org>
X-BeenThere: tiff@lists.maptools.org
X-Mailman-Version: 2.1.4
Precedence: list
List-Id: TIFF and libtiff discussion <tiff.lists.maptools.org>
List-Unsubscribe: <http://lists.maptools.org/mailman/listinfo/tiff>,
	<mailto:tiff-request@lists.maptools.org?subject=unsubscribe>
List-Archive: <http://lists.maptools.org/mailman/private/tiff>
List-Post: <mailto:tiff@lists.maptools.org>
List-Help: <mailto:tiff-request@lists.maptools.org?subject=help>
List-Subscribe: <http://lists.maptools.org/mailman/listinfo/tiff>,
	<mailto:tiff-request@lists.maptools.org?subject=subscribe>
Sender: tiff-bounces@lists.maptools.org
Errors-To: tiff-bounces@lists.maptools.org
X-UIDL: 000000000023ceae.00002731
X-MSP-STORE: Sat, 18 Aug 2007 07:16:58 +0200
Status: RO

  This message is in MIME format.  The first part should be readable text,
  while the remaining parts are likely unreadable without MIME-aware tools.

---1463786751-856936922-1187380646=:6565
Content-Type: TEXT/PLAIN; charset=utf-8
Content-Transfer-Encoding: QUOTED-PRINTABLE

Can you set the photometric tag and post a small sample?=20
The data type should point to integer automatically.

Am 17.08.07, 15:10 -0400 schrieb Christian Henning:

> ---------- Forwarded message ----------
> From: Christian Henning <chhenning@gmail.com>
> Date: Aug 17, 2007 3:09 PM
> Subject: Re: [Tiff] How to write a planar tiff file
> To: Toby Thain <toby@smartgames.ca>
>=20
>=20
> On 8/17/07, Toby Thain <toby@smartgames.ca> wrote:
> >
> > On 17-Aug-07, at 4:00 PM, Christian Henning wrote:
> >
> > > Hi there, I'm having problems writing a planar image file. Can
> > > somebody spot the problem in the following code. It's the most basic
> > > writer I can think of.
> >
> > What kind of problem are you having?
>=20
> No reader can open the file. Though, I think it's my fault.
>=20
> >
> > --Toby
> >
> >
> > >
> > > int main()
> > > {
> > >    TIFF* file =3D TIFFOpen( "write_test.tif", "w" );
> > >
> > >    TIFFSetField( file, TIFFTAG_IMAGEWIDTH  , 100 );
> > >    TIFFSetField( file, TIFFTAG_IMAGELENGTH , 100 );
> > >    TIFFSetField( file, TIFFTAG_COMPRESSION, COMPRESSION_LZW );
> > >    TIFFSetField( file, TIFFTAG_PLANARCONFIG, PLANARCONFIG_SEPARATE );
> > >    TIFFSetField( file, TIFFTAG_BITSPERSAMPLE  , 8 );
> > >    TIFFSetField( file, TIFFTAG_SAMPLESPERPIXEL, 3 );
> > >
> > >
> > >    std::vector< unsigned char > row( 100 );
> > >
> > >    for( int c =3D 0; c < 3; ++c )
> > >    {
> > >       for( int y =3D 0; y < 100; ++y )
> > >       {
> > >          int size =3D TIFFWriteScanline( file
> > >                                      , &row.front()
> > >                                      , y
> > >                                      , c           );
> > >
> > >          io_error_if( size =3D=3D -1, "Write error." );
> > >       }
> > >    }
> > >
> > >    TIFFClose( file );
> > > }
> > >
> > >
> > > Thanks ahead,
> > > Christian
> > > _______________________________________________
> > > Tiff mailing list: Tiff@lists.maptools.org
> > > http://lists.maptools.org/mailman/listinfo/tiff
> > > http://www.remotesensing.org/libtiff/
> >
> >
> _______________________________________________
> Tiff mailing list: Tiff@lists.maptools.org
> http://lists.maptools.org/mailman/listinfo/tiff
> http://www.remotesensing.org/libtiff/
>=20

Mit freundlichen Gr=C3=BC=C3=9Fen
Kai-Uwe Behrmann
--
Programmierung f=C3=BCr Farbmanagement
www.behrmann.name + www.oyranos.org + www.cinepaint.org

---1463786751-856936922-1187380646=:6565
Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

_______________________________________________
Tiff mailing list: Tiff@lists.maptools.org
http://lists.maptools.org/mailman/listinfo/tiff
http://www.remotesensing.org/libtiff/
---1463786751-856936922-1187380646=:6565--
