<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=US-ASCII">
<META NAME="Generator" CONTENT="MS Exchange Server version 5.5.2653.12">
<TITLE>GDALWARP / GDAL_TRANSLATE / ECW Questions</TITLE>
</HEAD>
<BODY>

<P><FONT SIZE=2 FACE="Arial">Howdy,</FONT>
</P>

<P><FONT SIZE=2 FACE="Arial">Since I may be approaching my task in the wrong way, let me let you all know what I am trying to do...</FONT>
</P>

<P><FONT SIZE=2 FACE="Arial">My desired result is a set of ECW formatted image files for use in mapserver in the following projection:</FONT>
</P>

<P>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">proj=aea</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">lat_1=29.500000000 #SP1</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">lat_2=45.500000000 #SP2</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">lat_0=23.000000000 #REF LAT</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">lon_0=-96.000000000 #CENTRAL MERIDIAN</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">x_0=0.000 #FALSE EAST</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">y_0=0.000 # FALSE NORTH</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">datum=NAD83</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">ellps=GRS80</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">no_defs</FONT>
</P>

<P><FONT SIZE=2 FACE="Arial">I have 2 options for input files. </FONT>
</P>

<P><FONT SIZE=2 FACE="Arial">The first option is .bil files with .hdr's in the following projection:</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">proj=utm</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">ellps=GRS80</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">zone=14 (or 13 or 15)</FONT>
<BR><FONT SIZE=2 FACE="Arial">&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; north</FONT>
<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <FONT SIZE=2 FACE="Arial">no_defs</FONT>
</P>

<P><FONT SIZE=2 FACE="Arial">The second option is .tif files with .tfw's already projected like my desired output.</FONT>
</P>

<P><FONT SIZE=2 FACE="Arial">I have no trouble using gdal_translate to convert from either .tif or .bil to .ecw.</FONT>
</P>

<P><FONT SIZE=2 FACE="Arial">The problem that I have is that the images projected in Albers have black around parts of the edges. As I intend to display them side by side in Mapserver I need to use the OFFSITE argument to hide this black. When the images are in .tif format this works fine, but once they are .ecw only part of the outside is masked - I'm guessing because the black is not all completely black after conversion to .ecw.</FONT></P>

<P><FONT SIZE=2 FACE="Arial">Is there a way to handle this?</FONT>
</P>
<BR>

<P><FONT SIZE=2 FACE="Arial">Also, when I use gdalwarp to project to Gtiff with the -co &quot;TFW=YES&quot; option no TFW is created.</FONT>
</P>

<P><FONT SIZE=2 FACE="Arial">Example:</FONT>
<BR><FONT SIZE=2 FACE="Arial">E:\IMAGES\DataIn&gt;gdalwarp -s_srs .\utm14.proj4 -t_srs .\albok.proj4 -of GTiff -co &quot;TFW=YES&quot; 34097h21.bil e:\images\dataout\34097h21.tif</FONT></P>

<P><FONT SIZE=2 FACE="Arial">Creating output file is that 6626P x 7890L.</FONT>
<BR><FONT SIZE=2 FACE="Arial">:0...10...20...30...40...50...60...70...80...90...100 - done.</FONT>
</P>
<BR>

<P><FONT SIZE=2 FACE="Arial">I am using the gdal_translate and gdalwarp on Win2K - build 1.1.8.</FONT>
</P>
<BR>

<P><FONT SIZE=2 FACE="Arial">Thanks for all your help and sorry if this is rambling or confusing...</FONT>
</P>

<P><FONT SIZE=2 FACE="Arial">David Lowther</FONT>
<BR><FONT SIZE=2 FACE="Arial">Software Engineer</FONT>
<BR><FONT SIZE=2 FACE="Arial">GEO Information Systems</FONT>
<BR><FONT SIZE=2 FACE="Arial">University of Oklahoma</FONT>
<BR><FONT SIZE=2 FACE="Arial">dlowther@ou.edu</FONT>
<BR><FONT SIZE=2 FACE="Arial">(405) 325-3131</FONT>
<BR><A HREF="http://www.geo.ou.edu"><U><FONT COLOR="#0000FF" SIZE=2 FACE="Arial">http://www.geo.ou.edu</FONT></U></A>
</P>
<BR>
<BR>

</BODY>
</HTML>