Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools
In directory usw-pr-cvs1:/tmp/cvs-serv7794/uk/ac/leeds/ccg/geotools
Modified Files:
LODFilter.java
Log Message:
Fixed small bug when useing viewer directly
Added more percentage levels to the list of levels at which new features appear
Index: LODFilter.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools/LODFilter.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -C2 -d -r1.4 -r1.5
*** LODFilter.java 2001/11/20 14:50:40 1.4
--- LODFilter.java 2001/11/20 18:01:27 1.5
***************
*** 29,36 ****
view=v;
}
! static final double levels[] = {100,150,200,400,1000,2000,4000};
public final boolean isVisible(int id){
lod = data.getValue(id);
! if(lod==0) return true;
if(scale!=null){
lod = (10-lod)*10;
--- 29,36 ----
view=v;
}
! static final double levels[] = {100,120,150,170,200,300,400,500,1000,2000,4000};
public final boolean isVisible(int id){
lod = data.getValue(id);
! if(lod<=0) return true;
if(scale!=null){
lod = (10-lod)*10;
***************
*** 41,46 ****
if(view!=null){
double perc = view.getZoomAsPercent();
! if(lod+1>levels.length) return perc>lod*1000.0;
! return perc > levels[(int)lod+1];
}
return false;
--- 41,47 ----
if(view!=null){
double perc = view.getZoomAsPercent();
! //System.out.println("lod "+lod+" per "+perc);
! if(lod>=levels.length) return perc>4000+lod*100.0;
! return perc > levels[(int)lod];
}
return false;
|