[OpenMap Users] any tips : Performance

From: Simon Bowen <sbowen@gammaprojects.com>
Date: Thu May 06 2004 - 06:49:15 EDT

Sorry if this a bit of a stupid question....
 
Can anyone give me any pointers in how to speed up the code below.
The 2 main bottle necks are proj.forward(lat[i],lon[i],pt); and return new
Area(new Polygon(x,y,len));
 
 
Would proj.forwardRaw speed things up? I tried to use proj.forwardRaw but
the results were a bit strange?
 
Area getArea(Projection proj)
{
          Point pt=new Point();
          for(int i=0;i<len;i++) {
            proj.forward(lat[i],lon[i],pt);
            x[i]=pt.x;
            y[i]=pt.y;
          }
          return new Area(new Polygon(x,y,len));
}
 
Thanks
 
Simon

--
[To unsubscribe to this list send an email to "majdart@bbn.com"
with the following text in the BODY of the message "unsubscribe openmap-users"]
Received on Thu May 6 06:50:54 2004

This archive was generated by hypermail 2.1.8 : Thu May 12 2005 - 07:18:38 EDT