<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1106" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT face=Arial size=2>Hi</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>I've implemented a shapefile reader in Python as a 
vtkProgrammableSource&nbsp;which I'm planning&nbsp;to redo in C++&nbsp;as a 
vtkPolyDataSource sometime over the&nbsp;Easter break. Problem is I only have 
files of type 1,3 and 5 (point, polyline and polygon)&nbsp;so currently I 
only&nbsp;have methods to reliably&nbsp;read these types. If anyone has 
multipatch shapefiles or shapefiles containing&nbsp;Z and/or optional&nbsp;M 
(measurement) data that I can use for development and testing PLEASE, PLEASE 
send me some (ie. anything other than vanilla point,&nbsp;polyline and 
polygon).</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>I'm going to make the reader freely available - 
I'll put in the vtk copyright etc. so if it's up to scratch (or can be made so) 
and the folk at VTK want to include it,&nbsp;I'll be more than 
happy.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>For any potential-users 
/&nbsp;interested-parties&nbsp;here's my thinking so far ...&nbsp;</FONT></DIV>
<DIV><FONT face=Arial size=2>uses separate&nbsp;method to read&nbsp;each main 
type (point, polyline, polygon,&nbsp;multipart - chosen after parsing the 
header)&nbsp;-hopefully if the format is extended (or as I get new types for the 
first time) it&nbsp;lessens impact on&nbsp;existing code.&nbsp;If present, 
Z&nbsp;data will be included in the points (otherwise Z = 0.0),&nbsp;M data as 
scalars in point-data. The id (record number) will be included as scalars in 
cell-data (facilitating look-ups into attribute-data&nbsp;on picking etc.). 
Polygons will require tessellation - I'm currently favouring the GLU built-in 
tessellator as it can handle the multipart polygons as is. For flexibility I 
think importing of attribute-data should be a separate issue - merging with 
attribute-data can&nbsp;take part&nbsp;down-stream if required.&nbsp;I was 
thinking&nbsp;a dBase reader could be provided later as a vtkDataObjectSource 
for those who don't want to connect to a database. Same goes for the shx 
indexing files - can provide reader later if need arises (provides position in 
shapefile of shape record&nbsp;based on&nbsp;id).</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Any suggestions&nbsp;or disagreements&nbsp;most 
welcome.</FONT></DIV>
<DIV><FONT face=Arial size=2>Also, if there already is a reader and I've missed 
it, I'd rather feel stupid now than later.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Regards</FONT></DIV>
<DIV><FONT face=Arial size=2>Malcolm Drummond<BR>GeoVision 
cc</FONT></DIV></BODY></HTML>