You can subscribe to this list here.
| 2001 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
(39) |
Dec
(70) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2002 |
Jan
(52) |
Feb
(168) |
Mar
(248) |
Apr
(143) |
May
(418) |
Jun
(558) |
Jul
(702) |
Aug
(311) |
Sep
(141) |
Oct
(350) |
Nov
(172) |
Dec
(182) |
| 2003 |
Jan
(320) |
Feb
(362) |
Mar
(356) |
Apr
(218) |
May
(447) |
Jun
(203) |
Jul
(745) |
Aug
(494) |
Sep
(175) |
Oct
(422) |
Nov
(554) |
Dec
(162) |
| 2004 |
Jan
(217) |
Feb
(353) |
Mar
(228) |
Apr
(407) |
May
(211) |
Jun
(270) |
Jul
(264) |
Aug
(198) |
Sep
(268) |
Oct
(227) |
Nov
(118) |
Dec
(47) |
| 2005 |
Jan
(207) |
Feb
(243) |
Mar
(297) |
Apr
(197) |
May
(281) |
Jun
(166) |
Jul
(164) |
Aug
(92) |
Sep
(155) |
Oct
(196) |
Nov
(189) |
Dec
(114) |
| 2006 |
Jan
(129) |
Feb
(219) |
Mar
(274) |
Apr
(213) |
May
(245) |
Jun
(220) |
Jul
(376) |
Aug
(347) |
Sep
(179) |
Oct
(493) |
Nov
(448) |
Dec
(339) |
| 2007 |
Jan
(304) |
Feb
(273) |
Mar
(237) |
Apr
(186) |
May
(215) |
Jun
(320) |
Jul
(229) |
Aug
(313) |
Sep
(331) |
Oct
(279) |
Nov
(347) |
Dec
(266) |
| 2008 |
Jan
(332) |
Feb
(280) |
Mar
(203) |
Apr
(277) |
May
(301) |
Jun
(356) |
Jul
(292) |
Aug
(203) |
Sep
(277) |
Oct
(142) |
Nov
(210) |
Dec
(239) |
| 2009 |
Jan
(250) |
Feb
(193) |
Mar
(174) |
Apr
(183) |
May
(342) |
Jun
(230) |
Jul
(292) |
Aug
(161) |
Sep
(204) |
Oct
(280) |
Nov
(281) |
Dec
(175) |
| 2010 |
Jan
(113) |
Feb
(106) |
Mar
(199) |
Apr
(166) |
May
(298) |
Jun
(147) |
Jul
(175) |
Aug
(192) |
Sep
(71) |
Oct
(79) |
Nov
(58) |
Dec
(55) |
| 2011 |
Jan
(83) |
Feb
(169) |
Mar
(142) |
Apr
(207) |
May
(311) |
Jun
(183) |
Jul
(218) |
Aug
(190) |
Sep
(158) |
Oct
(197) |
Nov
(93) |
Dec
(74) |
| 2012 |
Jan
(92) |
Feb
(50) |
Mar
(64) |
Apr
(45) |
May
(100) |
Jun
(70) |
Jul
(3) |
Aug
(1) |
Sep
(2) |
Oct
(5) |
Nov
(7) |
Dec
(4) |
| 2013 |
Jan
(6) |
Feb
(2) |
Mar
(2) |
Apr
(4) |
May
(3) |
Jun
|
Jul
(2) |
Aug
|
Sep
|
Oct
(1) |
Nov
(1) |
Dec
|
| 2014 |
Jan
(2) |
Feb
(2) |
Mar
(2) |
Apr
(3) |
May
(3) |
Jun
(1) |
Jul
|
Aug
(4) |
Sep
|
Oct
(1) |
Nov
(1) |
Dec
|
| 2015 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
(1) |
Sep
|
Oct
|
Nov
(1) |
Dec
(1) |
| 2016 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(1) |
Jun
(1) |
Jul
|
Aug
(3) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2017 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: Ian T. <ian...@us...> - 2001-12-21 11:46:51
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc
In directory usw-pr-cvs1:/tmp/cvs-serv18728/uk/ac/leeds/ccg/ogc
Modified Files:
RemoteOGC.java
Log Message:
added some code to getImageStream to handle the connection timing out.
Index: RemoteOGC.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc/RemoteOGC.java,v
retrieving revision 1.17
retrieving revision 1.18
diff -w -C2 -d -r1.17 -r1.18
*** RemoteOGC.java 2001/12/20 15:27:23 1.17
--- RemoteOGC.java 2001/12/21 11:46:47 1.18
***************
*** 211,215 ****
--- 211,221 ----
instr = remoteConnection.getInputStream();
} catch (IOException e) {
+ try{
+ initConnection();
+ int res = remoteConnection.sendRequest(url);;
+ instr = remoteConnection.getInputStream();
+ }catch(IOException ex) {
instr=null;
+ }
} // end of try-catch
return instr;
***************
*** 379,382 ****
--- 385,391 ----
*
* $Log$
+ * Revision 1.18 2001/12/21 11:46:47 ianturton
+ * added some code to getImageStream to handle the connection timing out.
+ *
* Revision 1.17 2001/12/20 15:27:23 ianturton
* various fixes and small mods to make WMSExample actually run. Can now
|
|
From: Ian T. <ian...@us...> - 2001-12-20 15:28:00
|
Update of /cvsroot/geotools/geotools/src/utils
In directory usw-pr-cvs1:/tmp/cvs-serv22811/utils
Modified Files:
WMSExample.java
Log Message:
various fixes and small mods to make WMSExample actually run. Can now
display an image if you remember to choose gif or jpg as output. Still
crashes if you zoom in.
Index: WMSExample.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/utils/WMSExample.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -w -C2 -d -r1.13 -r1.14
*** WMSExample.java 2001/11/21 13:48:19 1.13
--- WMSExample.java 2001/12/20 15:27:57 1.14
***************
*** 30,33 ****
--- 30,34 ----
String[] serverList = {
"file:capabilities_1_1_0.xml",
+ "http://www.ccg.leeds.ac.uk/cgi-bin/wms",
"http://usl.cubewerx.com/gfst/cubeserv/cubeserv.cgi",
"http://usl.cubewerx.com/cubestor/cubeserv/cubeserv.cgi",
***************
*** 46,49 ****
--- 47,51 ----
String[] serverNames = {
"file:capabilities_1_1_0.xml",
+ "www.ccg.leeds.ac.uk",
"usl.cubewerx.com 1",
"usl.cubewerx.com 2",
***************
*** 210,215 ****
}
! if (remoteWMS==null) {
! deb("Creating WMSLayer...");
// Create the 'interface' to WMS server and trigger getCapabilities
// To do: SRS and version should be extracted from the
--- 212,217 ----
}
! if (remoteWMS==null||layer==null) {
! deb("Creating WMSLayer..."+url.toString());
// Create the 'interface' to WMS server and trigger getCapabilities
// To do: SRS and version should be extracted from the
***************
*** 223,227 ****
--- 225,231 ----
// Get all available layers on WMS - can take long time
+ System.out.println("requested external layers");
ext_layers = remoteWMS.getExternalLayers();
+ System.out.println("finished request external layers "+ext_layers);
if(ext_layers != null && ext_layers.size() > 0) {
layerList.removeAll();
***************
*** 232,236 ****
}
// Get formats available on WMS
! java.util.ArrayList formats = remoteWMS.getAvailableFormats("GetMap");
if(formats != null && formats.size() > 0) {
formatList.removeAll();
--- 236,243 ----
}
// Get formats available on WMS
! java.util.ArrayList formats;
! formats = remoteWMS.getAvailableFormats("GetMap");
! if(formats==null||formats.size()==0)
! formats = remoteWMS.getAvailableFormats("Map");
if(formats != null && formats.size() > 0) {
formatList.removeAll();
***************
*** 254,263 ****
String layers="";
! // To do: Need to set extent to the aggregate extent of the
! // layers.
! GeoRectangle extent=new GeoRectangle(0,0,80,80);
String[] selectedLayers = layerList.getSelectedItems();
for(int i =0;i<selectedLayers.length;i++){
layers=layers.concat(selectedLayers[i]);
if (i<selectedLayers.length-1) {
--- 261,271 ----
String layers="";
! GeoRectangle extent=new GeoRectangle();
String[] selectedLayers = layerList.getSelectedItems();
+ int[] selectedIndexes = layerList.getSelectedIndexes();
for(int i =0;i<selectedLayers.length;i++){
+ ExternalWMSLayer ewmsl = (ExternalWMSLayer)ext_layers.get(selectedIndexes[i]);
+ extent.add(ewmsl.getBounds());
layers=layers.concat(selectedLayers[i]);
if (i<selectedLayers.length-1) {
***************
*** 265,281 ****
}
}
! WMSLayer wmsLayer=new WMSLayer(
remoteWMS,
layers,
"", // style
extent,
! OGCConstants.GIF,
true,
"0xFFFFFF",
"INIMAGE");
! Theme wmsTheme= new Theme(wmsLayer);
! view.addTheme(wmsTheme);
! view.setMapExtent(extent);
}
}
--- 273,302 ----
}
}
+ int i = formatList.getSelectedIndex();
+ WMSFormat imgType;
+ if(i== -1){
+ System.out.println("No Image format Selected - chosing gif");
+ imgType =new WMSFormat("image/gif");
+ }else{
+ imgType=new WMSFormat(formatList.getItem(i));
+ //int k = imgType.lastIndexOf("/");
+ //imgType = imgType.substring(k+1);
+ }
! layer=new WMSLayer(
remoteWMS,
layers,
"", // style
extent,
! imgType.getFormatInt(),
true,
"0xFFFFFF",
"INIMAGE");
! }
! if(th==null){
! th = new Theme(layer);
! view.addTheme(th);
! }else{
! th.setLayer(layer);
}
}
***************
*** 321,331 ****
imgType ="image/gif";
}else{
! imgType=formatList.getItem(i);
//int k = imgType.lastIndexOf("/");
//imgType = imgType.substring(k+1);
}
if(layer==null){ // new map
! layer=remoteWMS.getWMSLayer(layers,new
! WMSFormat(imgType),b.x,b.y,b.width,b.height);
System.out.println("layer "+layer);
if(th==null){
--- 342,351 ----
imgType ="image/gif";
}else{
! imgType=new WMSFormat(formatList.getItem(i));
//int k = imgType.lastIndexOf("/");
//imgType = imgType.substring(k+1);
}
if(layer==null){ // new map
! layer=remoteWMS.getWMSLayer(layers,imgType,b.x,b.y,b.width,b.height);
System.out.println("layer "+layer);
if(th==null){
***************
*** 449,452 ****
--- 469,477 ----
*
* $Log$
+ * Revision 1.14 2001/12/20 15:27:57 ianturton
+ * various fixes and small mods to make WMSExample actually run. Can now
+ * display an image if you remember to choose gif or jpg as output. Still
+ * crashes if you zoom in.
+ *
* Revision 1.13 2001/11/21 13:48:19 kobit
* Added support for creating ImageLayer with InputStream as image data source and full support for downaloding map data from WMS with jprotocols package
|
|
From: Ian T. <ian...@us...> - 2001-12-20 15:28:00
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/raster
In directory usw-pr-cvs1:/tmp/cvs-serv22811/uk/ac/leeds/ccg/raster
Modified Files:
ImageLayer.java
Log Message:
various fixes and small mods to make WMSExample actually run. Can now
display an image if you remember to choose gif or jpg as output. Still
crashes if you zoom in.
Index: ImageLayer.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/raster/ImageLayer.java,v
retrieving revision 1.33
retrieving revision 1.34
diff -w -C2 -d -r1.33 -r1.34
*** ImageLayer.java 2001/12/11 11:35:01 1.33
--- ImageLayer.java 2001/12/20 15:27:57 1.34
***************
*** 32,36 ****
private GeoRectangle bbox = null;
private int myID = 1;
! private final static boolean DEBUG=false;
private Canvas obs = new Canvas();
private MediaTracker tracker=new MediaTracker(obs);
--- 32,36 ----
private GeoRectangle bbox = null;
private int myID = 1;
! private final static boolean DEBUG=true;
private Canvas obs = new Canvas();
private MediaTracker tracker=new MediaTracker(obs);
***************
*** 333,336 ****
--- 333,337 ----
} // end of if (src != null)
if (src_stream != null) {
+ System.out.println("going with stream ");
byte[] img_data = getImageData(src_stream);
// here we can put condition for creating
***************
*** 358,361 ****
--- 359,366 ----
int state=tracker.statusID(myID,true);
if(DEBUG)System.out.println("finished load status "+state);
+ if(state==tracker.COMPLETE)System.out.println("Il: Complete");
+ if(state==tracker.ABORTED)System.out.println("Il: ABORTED");
+ if(state==tracker.ERRORED)System.out.println("Il: ERRORED");
+ if(state==tracker.LOADING)System.out.println("Il: LOADING");
if((state&tracker.COMPLETE) == tracker.COMPLETE){
int height = image.getHeight(obs);
***************
*** 381,384 ****
--- 386,390 ----
if ((pg.getStatus() & ImageObserver.ABORT) != 0) {
System.err.println("IL-->image fetch aborted or errored, status="+pg.getStatus());
+ setStatus(Layer.ABORTED);
return ;
}
***************
*** 392,395 ****
--- 398,403 ----
if(DEBUG)System.out.println("IL ("+this+")-->Image Aborted ");
}else {
+ Exception e = new Exception();
+ e.printStackTrace();
setStatus(Layer.ERRORED);
if(DEBUG)System.out.println("IL ("+this+")-->Image Error ");
***************
*** 411,414 ****
--- 419,427 ----
*
* $Log$
+ * Revision 1.34 2001/12/20 15:27:57 ianturton
+ * various fixes and small mods to make WMSExample actually run. Can now
+ * display an image if you remember to choose gif or jpg as output. Still
+ * crashes if you zoom in.
+ *
* Revision 1.33 2001/12/11 11:35:01 ianturton
* improved painting of cliped images.
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc
In directory usw-pr-cvs1:/tmp/cvs-serv22510
Modified Files:
OGCCapabilities.java OGCConstants.java RemoteConnection.java
RemoteOGC.java WMSFormat.java WMSLayer.java
Log Message:
various fixes and small mods to make WMSExample actually run. Can now
display an image if you remember to choose gif or jpg as output. Still
crashes if you zoom in.
Index: OGCCapabilities.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc/OGCCapabilities.java,v
retrieving revision 1.13
retrieving revision 1.14
diff -w -C2 -d -r1.13 -r1.14
*** OGCCapabilities.java 2001/11/19 10:03:33 1.13
--- OGCCapabilities.java 2001/12/20 15:27:23 1.14
***************
*** 46,50 ****
* service on <code>WMSServer</code> and local client displaing
* geo data on the screen.
! * <p/> Probably the most importand and often used service
* is <code>OGCWebMapService</code>. According to OGC implementation
* specification ver. 1.1.0 every Web Map Server should make
--- 46,50 ----
* service on <code>WMSServer</code> and local client displaing
* geo data on the screen.
! * <p/> Probably the most important and often used service
* is <code>OGCWebMapService</code>. According to OGC implementation
* specification ver. 1.1.0 every Web Map Server should make
***************
*** 73,77 ****
*/
public OGCCapabilities(InputStream is)
! throws IOException, SAXException
{
parseCapabilities(is);
--- 73,77 ----
*/
public OGCCapabilities(InputStream is)
! throws IOException, SAXException, Exception
{
parseCapabilities(is);
***************
*** 99,109 ****
* @param is an <code>InputStream</code> where from method should read capability data.
*/
! public void parseCapabilities(InputStream is)
{
/* I am not sure if "is" should be checked that it is not equal null */
if(is != null) {
CapabilitiesParser parser = new CapabilitiesParser();
! try {
doc = parser.parse(is);
is.close();
try {
--- 99,110 ----
* @param is an <code>InputStream</code> where from method should read capability data.
*/
! public void parseCapabilities(InputStream is) throws Exception
{
/* I am not sure if "is" should be checked that it is not equal null */
if(is != null) {
CapabilitiesParser parser = new CapabilitiesParser();
! //try {
doc = parser.parse(is);
+ System.out.println("Finished reading/parsing capabilities");
is.close();
try {
***************
*** 114,120 ****
capa_version = null;
}
! } catch (Exception e) {
! e.printStackTrace();
! }
}
}
--- 115,122 ----
capa_version = null;
}
! //} catch (Exception e) {
! //prln("error in OGCCapabilities");
! //e.printStackTrace();
! //}
}
}
***************
*** 158,168 ****
if(doc != null) {
NodeList nl = doc.getElementsByTagName(OGCXMLConstants.TAG_LAYER);
if(nl.getLength() > 0) {
ArrayList layers = new ArrayList();
for(int i = 0; i < nl.getLength(); i++) {
Node node = nl.item(i);
if(node.getNodeType() == Node.ELEMENT_NODE) {
String attr_value = ((Element)node).getAttribute(OGCXMLConstants.ATT_QUERYABLE);
! if(attr_value != null && attr_value.equals("1")) {
String lay_name = null, lay_title = null, lay_abstr = null;
--- 160,173 ----
if(doc != null) {
NodeList nl = doc.getElementsByTagName(OGCXMLConstants.TAG_LAYER);
+ System.out.println("OGC Cap: "+nl.getLength()+" layers");
if(nl.getLength() > 0) {
ArrayList layers = new ArrayList();
for(int i = 0; i < nl.getLength(); i++) {
Node node = nl.item(i);
+ System.out.println(""+i+" "+node+" "+node.getNodeType());
if(node.getNodeType() == Node.ELEMENT_NODE) {
String attr_value = ((Element)node).getAttribute(OGCXMLConstants.ATT_QUERYABLE);
! System.out.println("\t"+attr_value);
! //if(attr_value != null && attr_value.equals("1")) {
String lay_name = null, lay_title = null, lay_abstr = null;
***************
*** 175,180 ****
--- 180,187 ----
lay_title = getSubtagText(node, OGCXMLConstants.TAG_TITLE);
lay_abstr = getSubtagText(node, OGCXMLConstants.TAG_ABSTRACT);
+ System.out.println("\t"+lay_name+" "+lay_title+" "+lay_abstr);
Node sub_node = getFirstSubnodeByTagName(node, OGCXMLConstants.TAG_LAT_LON_BB);
try {
+ System.out.println("ll_maxx:"+((Element)sub_node).getAttribute(OGCXMLConstants.ATT_MAXX));
ll_maxx =
Double.parseDouble(((Element)sub_node).getAttribute(OGCXMLConstants.ATT_MAXX));
***************
*** 211,221 ****
ext_wms_lay.setLayerLegend(leg_h, leg_w, leg_format, leg_resource);
layers.add(ext_wms_lay);
- }
}
}
}
return layers;
}
}
return null;
}
--- 218,232 ----
ext_wms_lay.setLayerLegend(leg_h, leg_w, leg_format, leg_resource);
layers.add(ext_wms_lay);
}
+ //}
+ }else{
+ System.out.println("not a Node.ELEMENT_NODE");
}
}
return layers;
}
+ System.out.println("No layers found");
}
+ System.out.println("OGC Cap - Doc == null");
return null;
}
***************
*** 231,234 ****
--- 242,246 ----
{
if(doc != null) {
+ System.out.println("Asking for "+service_type+" formats");
NodeList nl = doc.getElementsByTagName(service_type);
if(nl.getLength() > 0) {
***************
*** 252,255 ****
--- 264,268 ----
return formats;
}
+ System.out.println("No format nodes");
}
return null;
***************
*** 341,344 ****
--- 354,358 ----
public static String capabilitiesQuery(String version)
{
+ System.err.println("Version string request "+version);
if(version.equals("1.1.0"))
return OGCConstants.PAR_V110_VERSION+"="+OGCConstants.VERSION_V110+
***************
*** 408,411 ****
--- 422,426 ----
{
parser.parse(uri);
+ System.out.println("Cap Parsed");
return parser.getDocument();
}
***************
*** 477,480 ****
--- 492,500 ----
*
* $Log$
+ * Revision 1.14 2001/12/20 15:27:23 ianturton
+ * various fixes and small mods to make WMSExample actually run. Can now
+ * display an image if you remember to choose gif or jpg as output. Still
+ * crashes if you zoom in.
+ *
* Revision 1.13 2001/11/19 10:03:33 kobit
* *** empty log message ***
Index: OGCConstants.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc/OGCConstants.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -w -C2 -d -r1.10 -r1.11
*** OGCConstants.java 2001/10/24 09:40:18 1.10
--- OGCConstants.java 2001/12/20 15:27:23 1.11
***************
*** 134,138 ****
"image/gif",
"image/jpeg",
! "image/x-png",
"image/tiff",
"image/???",
--- 134,138 ----
"image/gif",
"image/jpeg",
! "image/png",
"image/tiff",
"image/???",
***************
*** 167,170 ****
--- 167,175 ----
*
* $Log$
+ * Revision 1.11 2001/12/20 15:27:23 ianturton
+ * various fixes and small mods to make WMSExample actually run. Can now
+ * display an image if you remember to choose gif or jpg as output. Still
+ * crashes if you zoom in.
+ *
* Revision 1.10 2001/10/24 09:40:18 kobit
* Added LOG cvs keyword to the end of file
Index: RemoteConnection.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc/RemoteConnection.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -w -C2 -d -r1.9 -r1.10
*** RemoteConnection.java 2001/12/11 12:26:58 1.9
--- RemoteConnection.java 2001/12/20 15:27:23 1.10
***************
*** 104,109 ****
--- 104,111 ----
{
url = uri;
+ prln("initConn:1 "+connection+" "+uri.toString());
connection = ProtocolFactory.createProtocol(uri, DEBUG);
connection.setStreamReadTimeout(60*1000);
+ prln("initConn:2 "+connection+" "+uri.toString());
}
***************
*** 111,124 ****
throws IOException, MalformedURLException
{
if(server.indexOf('?') == -1)
url = new URI(server+"?"+query);
else
url = new URI(server+"&"+query);
! return sendRequest(new URL("http://"+url.toString()));
}
public int sendRequest(URL url) throws IOException
{
! prln("URL="+url.toString());
if (connection == null) {
initConnection(new URI(url));
--- 113,128 ----
throws IOException, MalformedURLException
{
+ prln("send qu:1 "+server+" "+query);
if(server.indexOf('?') == -1)
url = new URI(server+"?"+query);
else
url = new URI(server+"&"+query);
! prln("send qu:2 "+url.toString());
! return sendRequest(new URL(url.toString()));
}
public int sendRequest(URL url) throws IOException
{
! prln("send req: URL="+url.toString());
if (connection == null) {
initConnection(new URI(url));
***************
*** 127,130 ****
--- 131,135 ----
connection.setURI(new URI(url));
} // end of else of if (connection == null)
+ System.out.println("end of sendReq "+connection);
return identifyResponse(connection);
}
***************
*** 204,207 ****
--- 209,217 ----
*
* $Log$
+ * Revision 1.10 2001/12/20 15:27:23 ianturton
+ * various fixes and small mods to make WMSExample actually run. Can now
+ * display an image if you remember to choose gif or jpg as output. Still
+ * crashes if you zoom in.
+ *
* Revision 1.9 2001/12/11 12:26:58 ianturton
* fixed malformed url in send query.
Index: RemoteOGC.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc/RemoteOGC.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -w -C2 -d -r1.16 -r1.17
*** RemoteOGC.java 2001/11/21 13:48:19 1.16
--- RemoteOGC.java 2001/12/20 15:27:23 1.17
***************
*** 78,81 ****
--- 78,82 ----
this.proxy = proxy;
// Trigger GETCAPABILITIES to get SRS and version.
+ capabilities=null;
}
***************
*** 92,95 ****
--- 93,97 ----
this.proxy = null;
// Trigger GETCAPABILITIES to get SRS and version.
+ capabilities=null;
}
***************
*** 229,232 ****
--- 231,235 ----
if(capabilities == null)
getCapabilities();
+ if(capabilities == null) return null;
return capabilities.getAvailableFormats(service_type);
***************
*** 292,295 ****
--- 295,299 ----
} catch(Exception e) {
prln("Help - unexpected exception "+e+" in send Query");
+ prln("server "+server.toString());
e.printStackTrace();
}
***************
*** 302,305 ****
--- 306,311 ----
case RemoteConnection.CONTENT_CAPABILITIES :
case RemoteConnection.CONTENT_UNKNOWN :
+ case RemoteConnection.CONTENT_HTML : /* apache returns this for
+ HEAD requests on xml files - Ian*/
try {
/* Create capabilities objecr and parse data */
***************
*** 336,341 ****
case RemoteConnection.CONTENT_SE :
break;
- case RemoteConnection.CONTENT_HTML :
- break;
default :
/* It should never happen!! */
--- 342,345 ----
***************
*** 375,378 ****
--- 379,387 ----
*
* $Log$
+ * Revision 1.17 2001/12/20 15:27:23 ianturton
+ * various fixes and small mods to make WMSExample actually run. Can now
+ * display an image if you remember to choose gif or jpg as output. Still
+ * crashes if you zoom in.
+ *
* Revision 1.16 2001/11/21 13:48:19 kobit
* Added support for creating ImageLayer with InputStream as image data source and full support for downaloding map data from WMS with jprotocols package
Index: WMSFormat.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc/WMSFormat.java,v
retrieving revision 1.4
retrieving revision 1.5
diff -w -C2 -d -r1.4 -r1.5
*** WMSFormat.java 2001/10/24 09:40:18 1.4
--- WMSFormat.java 2001/12/20 15:27:23 1.5
***************
*** 67,71 ****
iFormat = 0;
sFormat = format;
! for(int i = 1; i < OGCConstants.MAP_FORMATS.length; i++)
if(OGCConstants.MAP_FORMATS[i].equals(sFormat)) {
iFormat = i;
--- 67,71 ----
iFormat = 0;
sFormat = format;
! for(int i = 1; i < OGCConstants.MAP_FORMATS.length; i++){
if(OGCConstants.MAP_FORMATS[i].equals(sFormat)) {
iFormat = i;
***************
*** 73,77 ****
--- 73,91 ----
}
}
+ if(iFormat!=0) return;
+ for(int i = 1; i < OGCConstants.MAP_FORMATS.length; i++){
+ String type = OGCConstants.MAP_FORMATS[i];
+ int in = type.indexOf('/');
+ if(in==-1) continue;
+ String form = type.substring(in+1);
+ if(form.equalsIgnoreCase(sFormat)) {
+ iFormat = i;
+ sFormat = type;
+ break;
+ }
+ }
+ }
+
public void setFormat(int format)
{
***************
*** 96,100 ****
public String getFormatStr()
{
! return sFormat;
}
--- 110,114 ----
public String getFormatStr()
{
! return OGCConstants.MAP_FORMATS[iFormat];
}
***************
*** 116,119 ****
--- 130,138 ----
*
* $Log$
+ * Revision 1.5 2001/12/20 15:27:23 ianturton
+ * various fixes and small mods to make WMSExample actually run. Can now
+ * display an image if you remember to choose gif or jpg as output. Still
+ * crashes if you zoom in.
+ *
* Revision 1.4 2001/10/24 09:40:18 kobit
* Added LOG cvs keyword to the end of file
Index: WMSLayer.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc/WMSLayer.java,v
retrieving revision 1.26
retrieving revision 1.27
diff -w -C2 -d -r1.26 -r1.27
*** WMSLayer.java 2001/11/21 13:48:19 1.26
--- WMSLayer.java 2001/12/20 15:27:23 1.27
***************
*** 142,145 ****
--- 142,146 ----
} // end of if (imageData != null)
else {
+ System.out.println("instr seems to be null in WMSLayer.buildLayer");
return null;
} // end of if (imageData != null)else
***************
*** 164,167 ****
--- 165,173 ----
*
* $Log$
+ * Revision 1.27 2001/12/20 15:27:23 ianturton
+ * various fixes and small mods to make WMSExample actually run. Can now
+ * display an image if you remember to choose gif or jpg as output. Still
+ * crashes if you zoom in.
+ *
* Revision 1.26 2001/11/21 13:48:19 kobit
* Added support for creating ImageLayer with InputStream as image data source and full support for downaloding map data from WMS with jprotocols package
|
|
From: Liu Z. <li...@us...> - 2001-12-20 02:06:13
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/widgets
In directory usw-pr-cvs1:/tmp/cvs-serv3920
Modified Files:
ColorPickLabel.java
Log Message:
update label's text when color changed
Index: ColorPickLabel.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/widgets/ColorPickLabel.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -w -C2 -d -r1.5 -r1.6
*** ColorPickLabel.java 2001/04/04 08:54:38 1.5
--- ColorPickLabel.java 2001/12/20 02:06:10 1.6
***************
*** 26,29 ****
--- 26,31 ----
{
setBackground(propValue);
+ setText("["+propValue.getRed()+","+propValue.getGreen()+","+propValue.getBlue()+"]");
+ if(DEBUG)System.out.println("CoPL>Color set to ["+propValue.getRed()+","+propValue.getGreen()+","+propValue.getBlue()+"]");
changes.firePropertyChange("pickColor", getPickColor(), propValue);
}
|
|
From: Liu Z. <li...@us...> - 2001-12-20 02:00:55
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/widgets
In directory usw-pr-cvs1:/tmp/cvs-serv2972
Modified Files:
ColorPicker.java
Log Message:
remove the bug that return minimum color value as 10 instead of 0
Index: ColorPicker.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/widgets/ColorPicker.java,v
retrieving revision 1.1.1.1
retrieving revision 1.2
diff -w -C2 -d -r1.1.1.1 -r1.2
*** ColorPicker.java 2000/04/14 09:18:51 1.1.1.1
--- ColorPicker.java 2001/12/20 02:00:53 1.2
***************
*** 19,25 ****
rgb = new Scrollbar[3];
for(int i=0;i<3;i++){
! rgb[i] = new Scrollbar();
! rgb[i].setMaximum(255);
! rgb[i].setMinimum(0);
rgb[i].addAdjustmentListener(this);
sliders.add(rgb[i]);
--- 19,25 ----
rgb = new Scrollbar[3];
for(int i=0;i<3;i++){
! rgb[i] = new Scrollbar(Scrollbar.VERTICAL, 0, 10, 0, 265);
! //rgb[i].setMaximum(255);
! //rgb[i].setMinimum(0);
rgb[i].addAdjustmentListener(this);
sliders.add(rgb[i]);
|
|
From: Liu Z. <li...@us...> - 2001-12-20 01:56:34
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools
In directory usw-pr-cvs1:/tmp/cvs-serv2244
Modified Files:
MonoShader.java
Log Message:
notify shaderChangedListeners when setMonoColor, if not silent mode
Index: MonoShader.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools/MonoShader.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -w -C2 -d -r1.5 -r1.6
*** MonoShader.java 2001/04/04 08:54:38 1.5
--- MonoShader.java 2001/12/20 01:56:29 1.6
***************
*** 63,67 ****
--- 63,73 ----
public void setMonoColor(Color col){
+ setMonoColor(col, false);
+ }
+
+ public void setMonoColor(Color col, boolean silent){
c=col;
+ if (!silent)
+ notifyShaderChangedListeners();
}
|
|
From: Ian T. <ian...@us...> - 2001-12-19 15:16:22
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools
In directory usw-pr-cvs1:/tmp/cvs-serv15864/uk/ac/leeds/ccg/geotools
Modified Files:
SimpleLayer.java
Log Message:
improved debug code and added debug variable
Index: SimpleLayer.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools/SimpleLayer.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -w -C2 -d -r1.7 -r1.8
*** SimpleLayer.java 2001/11/21 13:48:19 1.7
--- SimpleLayer.java 2001/12/19 15:16:20 1.8
***************
*** 11,14 ****
--- 11,15 ----
Vector listeners = new Vector();
protected String name = "Unknown";
+ static final boolean DEBUG=false;
public void removeLayerChangedListener(LayerChangedListener lcl)
***************
*** 39,46 ****
}
public void setStatus(int stat){
! System.out.println(this+" status changed to "+stat);
if(status != Layer.COMPLETED&&stat==Layer.COMPLETED){
status=stat;
! System.out.println("Notifing listeners of change");
notifyLayerChangedListeners(LayerChangedEvent.GEOGRAPHY);
} else {
--- 40,68 ----
}
public void setStatus(int stat){
! if(DEBUG){
! System.out.print(this+" status changed to "+stat);
! switch(stat){
! case Layer.COMPLETED:
! System.out.println(" (COMPLETED)");
! break;
! case Layer.LOADING:
! System.out.println(" (LOADING)");
! break;
! case Layer.PENDING:
! System.out.println(" (PENDING)");
! break;
! case Layer.ERRORED:
! System.out.println(" (ERRORED)");
! break;
! case Layer.ABORTED:
! System.out.println(" (ABORTED)");
! break;
! default:
! System.out.println(" BROKEN - HELP");
! }
! }
if(status != Layer.COMPLETED&&stat==Layer.COMPLETED){
status=stat;
! if(DEBUG)System.out.println("Notifing listeners of change");
notifyLayerChangedListeners(LayerChangedEvent.GEOGRAPHY);
} else {
|
|
From: Liu Z. <li...@us...> - 2001-12-14 01:56:37
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools
In directory usw-pr-cvs1:/tmp/cvs-serv3292
Modified Files:
Viewer.java
Log Message:
fixed bugs with removeTheme(), which did not update the themeStack and relavant listeners
Index: Viewer.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools/Viewer.java,v
retrieving revision 1.37
retrieving revision 1.38
diff -w -C2 -d -r1.37 -r1.38
*** Viewer.java 2001/11/23 18:51:46 1.37
--- Viewer.java 2001/12/14 01:56:34 1.38
***************
*** 326,329 ****
--- 326,333 ----
if(staticThemes.contains(t)){
staticThemes.removeElement(t);
+ removeHighlightPositionChangedListener(t);
+ removeSelectionPositionChangedListener(t);
+ removeSelectionRegionChangedListener(t);
+ themeStack.removeTheme(t);
themeCount--;
updateStaticBuffer();
|
|
From: Ian T. <ian...@us...> - 2001-12-11 12:27:02
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc
In directory usw-pr-cvs1:/tmp/cvs-serv28043/uk/ac/leeds/ccg/ogc
Modified Files:
RemoteConnection.java
Log Message:
fixed malformed url in send query.
Index: RemoteConnection.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/ogc/RemoteConnection.java,v
retrieving revision 1.8
retrieving revision 1.9
diff -w -C2 -d -r1.8 -r1.9
*** RemoteConnection.java 2001/11/20 17:01:45 1.8
--- RemoteConnection.java 2001/12/11 12:26:58 1.9
***************
*** 115,119 ****
else
url = new URI(server+"&"+query);
! return sendRequest(new URL(url.toString()));
}
--- 115,119 ----
else
url = new URI(server+"&"+query);
! return sendRequest(new URL("http://"+url.toString()));
}
***************
*** 204,207 ****
--- 204,210 ----
*
* $Log$
+ * Revision 1.9 2001/12/11 12:26:58 ianturton
+ * fixed malformed url in send query.
+ *
* Revision 1.8 2001/11/20 17:01:45 kobit
* Added byte[] getContentData() support
|
|
From: Ian T. <ian...@us...> - 2001-12-11 11:59:03
|
Update of /cvsroot/geotools/geotools/src/demonstrations In directory usw-pr-cvs1:/tmp/cvs-serv21887/demonstrations Modified Files: ImageExample.html Log Message: added comments on the need for jars Index: ImageExample.html =================================================================== RCS file: /cvsroot/geotools/geotools/src/demonstrations/ImageExample.html,v retrieving revision 1.5 retrieving revision 1.6 diff -w -C2 -d -r1.5 -r1.6 *** ImageExample.html 2001/12/11 11:43:33 1.5 --- ImageExample.html 2001/12/11 11:59:00 1.6 *************** *** 17,21 **** </P> <P><<A HREF="ImageExample.java">source</A>></P> ! <p>The applet requires two parameters, the first 'image' points to the relative location of the image to display, whils the second 'bounds' gives the spatial extent of the image.<br> <P><CODE><APPLET ARCHIVE="jars/collections.jar,jars/JimiCore.jar,jars/geotools.jar" CODE="ImageExample.class" WIDTH=430 HEIGHT=270><BR> <PARAM NAME="image" VALUE="maps/worldview.gif"><BR> --- 17,24 ---- </P> <P><<A HREF="ImageExample.java">source</A>></P> ! <p>The applet requires two parameters, the first 'image' points to the relative location of the image to display, while the second 'bounds' gives the spatial extent of the image.<br> ! <p><strong>Note:</strong> You only need to include jars/JimiCore.jar ! <strong>if</strong> you need to read and display images of types other than ! gif and jpeg. <P><CODE><APPLET ARCHIVE="jars/collections.jar,jars/JimiCore.jar,jars/geotools.jar" CODE="ImageExample.class" WIDTH=430 HEIGHT=270><BR> <PARAM NAME="image" VALUE="maps/worldview.gif"><BR> |
|
From: Ian T. <ian...@us...> - 2001-12-11 11:43:36
|
Update of /cvsroot/geotools/geotools/src/demonstrations In directory usw-pr-cvs1:/tmp/cvs-serv15790/demonstrations Modified Files: ImageExample.html Log Message: changed to use png Index: ImageExample.html =================================================================== RCS file: /cvsroot/geotools/geotools/src/demonstrations/ImageExample.html,v retrieving revision 1.4 retrieving revision 1.5 diff -w -C2 -d -r1.4 -r1.5 *** ImageExample.html 2001/12/03 21:43:29 1.4 --- ImageExample.html 2001/12/11 11:43:33 1.5 *************** *** 11,15 **** <H2>A basic map which uses an image to build a map layer.</H2> <P><APPLET ARCHIVE="jars/JimiCore.jar,jars/support.jar,jars/geotools.jar,jars/collections.jar" CODE="ImageExample.class" WIDTH="470" HEIGHT="170" ALIGN="BOTTOM"> ! <PARAM NAME="image" VALUE="maps/worldview.gif"> <param name="bounds" value="-180,-90,360,180"> </APPLET> --- 11,16 ---- <H2>A basic map which uses an image to build a map layer.</H2> <P><APPLET ARCHIVE="jars/JimiCore.jar,jars/support.jar,jars/geotools.jar,jars/collections.jar" CODE="ImageExample.class" WIDTH="470" HEIGHT="170" ALIGN="BOTTOM"> ! <-- change png to gif if you are testing that aspect of the code> ! <PARAM NAME="image" VALUE="maps/worldview.png"> <param name="bounds" value="-180,-90,360,180"> </APPLET> |
|
From: Ian T. <ian...@us...> - 2001-12-11 11:42:27
|
Update of /cvsroot/geotools/geotools/src/demonstrations/maps
In directory usw-pr-cvs1:/tmp/cvs-serv15125/demonstrations/maps
Added Files:
worldview.png
Log Message:
a png version of the gif
--- NEW FILE: worldview.png ---
PNG
°NÅöSnU7Iñ_uZ3¶3#õ_ݳW;ØWôÿ ºH/N3ÀCÛ£ÿÌCï=¯
2´§CpRòè¿lµ
˳ÇZתÞÌK[:S%z!Á¤[ý]:ztC#ªô>Ýrü
+4z!V$yÓñ嵿ZJUÂîø&º¨Ðè¸HèVM,¤ø&*ÿ¹büÌu(`ë|ÃñÚÄs*4
¤èd-¡c³A²M«&Æ&¤,ÆCrº+pÊ.8Eé¾îÚhÌïÔ;7,O<m
XÁ(þ*ØNªuEõ;F#Vhc;ôÎÖÂñj%3&|ý^Ûש¡Ó,|,#Ý£1b¶¾Bz×C «-Ý0.\Íëù9YY(
÷?Ü´Å>z~0Ywß^ÑøýÕùX; *p-GþÚiÅаGêþ ñJÊKiS&ÅÚ1µÚ|
ßv&<¢ÌKRýìÊZ :2v\jK¨µvðǦVðÌBØä½geO JO¡Zb'V¨Ñw×Ë.å/+ºæön"ä>dÉ](ª¤aø±uôîïT-oìgý¼"/øýj)æ"Õèê¥
ù± «ZÓt
kÖ,0éÆU¢´ôhÉ¢EÍI¢£ëîÑ1Ìõnäqc÷£èüº<6ý¹(o
¹Æ[ùí}tèûD«@1£
è YTëº6¬8®9$ÅËYhììz9Ï£
+Ù5Zë `«í¹K:ÿ}7áêöVMÔí¼ðí¹¤kê6æbØÙ«·ÒW*t¾ï])/;0KXEÙÆXPEî½FhØ¢!#%©pÒZ
B©3RúûX1u;²WtÑ(sÖ
¶
¶XÓ±íåTkdÔ*ýfç¢ÿÀR5Â/"AâíüOæéãn6~®ÔÍQ8ÆD$ËIqÛRìMk¸Æyiµm.µà±RkKþç&ØZ<¾½`o¶nË2åkRDß/g£1s±b=4Mùòì ÕnLAv1sÑsÆtÇoØDc£Ü¢ Ûý÷ñy&½!"y×~õ>Äuì]§xlîÙf¢U°¥%±NQH·Æ¿ï»Û?)NêEãÀ"P|Ûþ"·¼gº{&Éã©°m¡fiÛڤʬç¡â]ô®
8´ÊCw(Ü®ET³ô8Ú
BâÄ[ÙÙ\'Ü¢¿PlÓ8É.ûµrºâo[«´´²íï?f~Ë:/b=#d¤G/~;}Ëò»±YÏA£¶ª°ìiøurNæÖøþÍ@+¶Â \Fí2EÁÐlaêZc.e>Î$&¹0]4ÍP9m±qtá$EÒ<\mÆu^wtSh¥0>âm{HÁݱ§ÁkFw¤»k~Ѷ/(øþ4SH,
évðø¦p<
ÆèÔí@òõÐr5Îb_øìÌ\(ÁÛÛUÙx<'§{»fç .kþÖ¡3DoK´±Ç)ô#LÉ®Ô8îSæxô¡aÔO'{²£ëøÍ:uh=
XB.»×Kñn]CÃ<©±¾òXvïMkûÏ*P¢è;°µo:NËfÅ@Æ.Ñz:å+Xá¦CØa[«ÿ$Zñ@ö¶"!tZ¡a®!:û»^¬hcv\ê9èlBBÖ_£Ôf¸³u«gõÊÙtȾée-#èØý1³]ñîÅàóD¥óÑåeôïÔ=õ@PßL Ãz¹þZ¤ï èy
ÁoËÍN#¢ß¿k¤*ù-Ûdzt9Öchz².þçÀ2¶9Ý?®h3YÀ¢W<D
â]¹"v_¶Õbo>
ÆúüG_?þS¾<:¯æiôk×®6ShþÇuçw8léW[ÍMWC+ óê&u_¯h}ýz+Óèýút }¡¿½ó)a®
~Ë_¾×öZR?ÝöÒ¿ú¿W:ûéjh«®æ|6_^
míWôW4»v¯%u~=©?\
¯¥"ì7êÞ¦M{ÇlüÇÔÚw=a÷©÷ÓE§ï<Ë| =Þ§¶~üfôIé)t2þŲòÛaþ)ç»§ÐGÝ7(G¼ÐƸýÉêíÌ?.:©çV]Ð@ö0;ÿÐ
5o]·×$榮¿u¶ÍMO?ñ^¡OÙàÛ¯Ñ㥻1ï|
±êÜÿâÔÉîbF¨ÒûKV}è¥V¬u]¿í"^èÓÍ/k]«_î}1ÔÅíL
_ú @w_@úòhÿ=0g±âJèë_ÑãwVö
|
|
From: Ian T. <ian...@us...> - 2001-12-11 11:35:05
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/raster
In directory usw-pr-cvs1:/tmp/cvs-serv11930/uk/ac/leeds/ccg/raster
Modified Files:
ImageLayer.java
Log Message:
improved painting of cliped images.
Index: ImageLayer.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/raster/ImageLayer.java,v
retrieving revision 1.32
retrieving revision 1.33
diff -w -C2 -d -r1.32 -r1.33
*** ImageLayer.java 2001/12/11 10:35:00 1.32
--- ImageLayer.java 2001/12/11 11:35:01 1.33
***************
*** 32,36 ****
private GeoRectangle bbox = null;
private int myID = 1;
! private final static boolean DEBUG=true;
private Canvas obs = new Canvas();
private MediaTracker tracker=new MediaTracker(obs);
--- 32,36 ----
private GeoRectangle bbox = null;
private int myID = 1;
! private final static boolean DEBUG=false;
private Canvas obs = new Canvas();
private MediaTracker tracker=new MediaTracker(obs);
***************
*** 40,43 ****
--- 40,45 ----
private Thread thread;
private MemoryImageSource source;
+ private int [] imdata;
+ private int imwidth;
public ImageLayer(URL source,GeoRectangle bounds){
***************
*** 221,225 ****
}
int[] data = new int[(height*width)];
! PixelGrabber pg = new PixelGrabber(
this.image,
x,
--- 223,236 ----
}
int[] data = new int[(height*width)];
! if(DEBUG)System.out.println("copy "+x+" "+y);
! if(DEBUG)System.out.println("copy "+imdata.length+" "+data.length);
! if(DEBUG)System.out.println("copy "+(y*imwidth+x)+" "+((y+height)*imwidth+x));
! if(((y+height)*imwidth+x)>imdata.length)height--;
! for(int i=0;i<height;i++){
!
! //if(DEBUG)System.out.println(""+((y+i)*imwidth+x)+","+(i*width)+","+(width));
! System.arraycopy(imdata,(y+i)*imwidth+x,data,i*width,width);
! }
! /*PixelGrabber pg = new PixelGrabber(
this.image,
x,
***************
*** 241,244 ****
--- 252,256 ----
return ;
}
+ */
source = new MemoryImageSource(width,height,data,0,width);
Image image2 = obs.createImage(source);
***************
*** 349,353 ****
int height = image.getHeight(obs);
int width = image.getWidth(obs);
! int[] data = new int[(height*width)];
PixelGrabber pg = new PixelGrabber(
this.image,
--- 361,366 ----
int height = image.getHeight(obs);
int width = image.getWidth(obs);
! imwidth=width;
! imdata = new int[(height*width)];
PixelGrabber pg = new PixelGrabber(
this.image,
***************
*** 356,360 ****
width,
height,
! data,
0,
width);
--- 369,373 ----
width,
height,
! imdata,
0,
width);
***************
*** 370,374 ****
return ;
}
! source = new MemoryImageSource(width,height,data,0,width);
image = obs.createImage(source);
if(DEBUG)System.out.println("IL ("+this+")-->Image Ready ");
--- 383,387 ----
return ;
}
! source = new MemoryImageSource(width,height,imdata,0,width);
image = obs.createImage(source);
if(DEBUG)System.out.println("IL ("+this+")-->Image Ready ");
***************
*** 398,401 ****
--- 411,417 ----
*
* $Log$
+ * Revision 1.33 2001/12/11 11:35:01 ianturton
+ * improved painting of cliped images.
+ *
* Revision 1.32 2001/12/11 10:35:00 ianturton
* readded support of png/tiff images
|
|
From: Ian T. <ian...@us...> - 2001-12-11 10:35:03
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/raster In directory usw-pr-cvs1:/tmp/cvs-serv31334/uk/ac/leeds/ccg/raster Modified Files: ImageLayer.java Log Message: readded support of png/tiff images Index: ImageLayer.java =================================================================== RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/raster/ImageLayer.java,v retrieving revision 1.31 retrieving revision 1.32 diff -w -C2 -d -r1.31 -r1.32 *** ImageLayer.java 2001/12/10 16:13:57 1.31 --- ImageLayer.java 2001/12/11 10:35:00 1.32 *************** *** 5,10 **** import uk.ac.leeds.ccg.geotools.*; import java.net.*; import java.awt.image.*; ! //import com.sun.jimi.core.*; import java.awt.*; --- 5,11 ---- import uk.ac.leeds.ccg.geotools.*; import java.net.*; + import java.io.*; import java.awt.image.*; ! import com.sun.jimi.core.*; import java.awt.*; *************** *** 31,35 **** private GeoRectangle bbox = null; private int myID = 1; ! private final static boolean DEBUG=false; private Canvas obs = new Canvas(); private MediaTracker tracker=new MediaTracker(obs); --- 32,36 ---- private GeoRectangle bbox = null; private int myID = 1; ! private final static boolean DEBUG=true; private Canvas obs = new Canvas(); private MediaTracker tracker=new MediaTracker(obs); *************** *** 275,290 **** // Start getting the image. If the image is .gif or .jpg then // use default java tools otherwise use Jimi class ! //String type=""; ! //try{ ! // URLConnection con = this.src.openConnection(); ! // type = con.getContentType(); ! //}catch(java.io.IOException ioe){ ! // System.err.println("IL--> problem opening connection"); ! //} ! //if((type!=null) && type.startsWith("image")){ ! Toolkit tk = Toolkit.getDefaultToolkit(); ! // if(type.trim().endsWith("gif") ! // || type.trim().endsWith("jpeg")){ ! // If a previous image was being tracked, then remove it. if(tracker!=null){ --- 276,280 ---- // Start getting the image. If the image is .gif or .jpg then // use default java tools otherwise use Jimi class ! String type=""; // If a previous image was being tracked, then remove it. if(tracker!=null){ *************** *** 293,299 **** --- 283,322 ---- this.image=null; } + URLConnection con; + Toolkit tk = Toolkit.getDefaultToolkit(); if (src != null) { + try{ + con = this.src.openConnection(); + type = con.getContentType(); + }catch(java.io.IOException ioe){ + System.err.println("IL--> problem opening connection"); + return; + } + + if((type!=null) && type.startsWith("image")){ + if(type.trim().endsWith("gif") + || type.trim().endsWith("jpeg")){ this.image = tk.getImage(this.src); if(DEBUG)System.out.println("New fetch ?"); + }else{ + this.image = Jimi.getImage(this.src,type); + } + }else{ + if(type.startsWith("text")){ + try{ + String line; + BufferedReader in = new BufferedReader(new InputStreamReader(con.getInputStream())); + while((line=in.readLine())!=null){ + System.err.println("IL("+this+"):"+line); + setStatus(Layer.ERRORED); + } + return; + }catch(IOException e){ + System.err.println("IL("+this+"):"+e); + setStatus(Layer.ERRORED); + return; + } + } + } } // end of if (src != null) if (src_stream != null) { *************** *** 305,311 **** - // }else{ - // this.image = Jimi.getImage(this.src,type); - // } // if(DEBUG)System.out.println( // "IL--> Image Width="+this.image.getWidth(obs)); --- 328,331 ---- *************** *** 378,384 **** * * $Log$ ! * Revision 1.31 2001/12/10 16:13:57 ianturton ! * added an internal buffer for the image source - this saves image reloads ! * when pixelgrabber is called. Don't ask me why this should be but it is! * * Revision 1.30 2001/12/07 11:01:33 ianturton --- 398,403 ---- * * $Log$ ! * Revision 1.32 2001/12/11 10:35:00 ianturton ! * readded support of png/tiff images * * Revision 1.30 2001/12/07 11:01:33 ianturton |
|
From: Ian T. <ian...@us...> - 2001-12-10 16:14:01
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/raster
In directory usw-pr-cvs1:/tmp/cvs-serv14282/uk/ac/leeds/ccg/raster
Modified Files:
ImageLayer.java
Log Message:
added an internal buffer for the image source - this saves image reloads
when pixelgrabber is called. Don't ask me why this should be but it is!
Index: ImageLayer.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/raster/ImageLayer.java,v
retrieving revision 1.30
retrieving revision 1.31
diff -w -C2 -d -r1.30 -r1.31
*** ImageLayer.java 2001/12/07 11:01:33 1.30
--- ImageLayer.java 2001/12/10 16:13:57 1.31
***************
*** 38,43 ****
--- 38,45 ----
protected java.io.InputStream src_stream = null;
private Thread thread;
+ private MemoryImageSource source;
public ImageLayer(URL source,GeoRectangle bounds){
+ if(DEBUG)System.out.println("IL-("+this+") constructor - source bounds");
if(DEBUG)System.out.println("---->uk.ac.leeds.ccg.raster.ImageLayer constructed. Will identify itself as IL-->");
changeImage(source,bounds);
***************
*** 50,53 ****
--- 52,56 ----
public ImageLayer(Image image,GeoRectangle bounds){
+ if(DEBUG)System.out.println("IL-("+this+") constructor - Image bounds");
bbox = bounds;
this.image = image;
***************
*** 61,64 ****
--- 64,68 ----
/** Change the image and extent for the layer. */
public void changeImage(URL source,GeoRectangle bounds){
+ if(DEBUG)System.out.println("IL-("+this+") changeImage(source,bounds)");
this.src = source;
this.src_stream = null;
***************
*** 76,79 ****
--- 80,84 ----
public void changeImage(GeoRectangle bounds)
{
+ if(DEBUG)System.out.println("IL-("+this+") changeImage(Bounds)");
this.bbox=bounds;
setStatus(Layer.LOADING);
***************
*** 85,88 ****
--- 90,94 ----
/** Change the image and but not the extent. */
public void changeImage(URL source){
+ if(DEBUG)System.out.println("IL-("+this+") changeImage(source)");
changeImage(source, this.bbox);
}
***************
*** 176,180 ****
gh,
null);
! if(DEBUG)System.out.println("IL ("+this+") -->3 drawn="+drawn);
}
} else{ // clipping required
--- 182,186 ----
gh,
null);
! if(DEBUG)System.out.println("IL ("+this+") -->3 drawn="+drawn+" "+this.image);
}
} else{ // clipping required
***************
*** 186,190 ****
}
//complex clip case
- MemoryImageSource source;
cellSizeX = me.width/this.image.getWidth(obs);
cellSizeY = me.height/this.image.getHeight(obs);
--- 192,195 ----
***************
*** 224,228 ****
0,
width);
! //if(DEBUG)System.out.println("IL-->about to grab");
try {
pg.grabPixels();
--- 229,233 ----
0,
width);
! if(DEBUG)System.out.println("IL-->about to grab");
try {
pg.grabPixels();
***************
*** 238,242 ****
Image image2 = obs.createImage(source);
drawn=g.drawImage(image2,origin[0],origin[1]-gh,gw,gh,obs);
! if(DEBUG)System.out.println("IL ("+this+") -->5.1 drawn="+drawn);
image2=null;
}
--- 243,247 ----
Image image2 = obs.createImage(source);
drawn=g.drawImage(image2,origin[0],origin[1]-gh,gw,gh,obs);
! if(DEBUG)System.out.println("IL ("+this+") -->5.1 drawn="+drawn+" "+this.image);
image2=null;
}
***************
*** 284,287 ****
--- 289,293 ----
// If a previous image was being tracked, then remove it.
if(tracker!=null){
+ if(DEBUG)System.out.println("Clearing old image");
tracker.removeImage(this.image);
this.image=null;
***************
*** 289,292 ****
--- 295,299 ----
if (src != null) {
this.image = tk.getImage(this.src);
+ if(DEBUG)System.out.println("New fetch ?");
} // end of if (src != null)
if (src_stream != null) {
***************
*** 303,307 ****
// if(DEBUG)System.out.println(
// "IL--> Image Width="+this.image.getWidth(obs));
!
tracker.addImage(this.image,++myID);
try {
--- 310,314 ----
// if(DEBUG)System.out.println(
// "IL--> Image Width="+this.image.getWidth(obs));
! if(DEBUG)System.out.println("adding image to tracker "+myID);
tracker.addImage(this.image,++myID);
try {
***************
*** 309,321 ****
while((tracker.statusID(myID,true)&tracker.LOADING)!=0){
if(getStatus()==Layer.ABORTED){
tracker.removeImage(this.image,myID);
break;
}
tracker.waitForID(myID,500);
! //if(DEBUG)System.out.println("IL ("+this+")-->status loop, status="+tracker.statusID(myID,true)+" myID="+myID);
}
int state=tracker.statusID(myID,true);
if((state&tracker.COMPLETE) == tracker.COMPLETE){
if(DEBUG)System.out.println("IL ("+this+")-->Image Ready ");
setStatus(Layer.COMPLETED);
--- 316,355 ----
while((tracker.statusID(myID,true)&tracker.LOADING)!=0){
if(getStatus()==Layer.ABORTED){
+ if(DEBUG)System.out.println("Abort - removing image");
tracker.removeImage(this.image,myID);
break;
}
tracker.waitForID(myID,500);
! if(DEBUG)System.out.println("IL ("+this+")-->status loop, status="+tracker.statusID(myID,true)+" myID="+myID);
}
int state=tracker.statusID(myID,true);
+ if(DEBUG)System.out.println("finished load status "+state);
if((state&tracker.COMPLETE) == tracker.COMPLETE){
+ int height = image.getHeight(obs);
+ int width = image.getWidth(obs);
+ int[] data = new int[(height*width)];
+ PixelGrabber pg = new PixelGrabber(
+ this.image,
+ 0,
+ 0,
+ width,
+ height,
+ data,
+ 0,
+ width);
+ if(DEBUG)System.out.println("IL-->about to grab");
+ try {
+ pg.grabPixels();
+ } catch (InterruptedException e) {
+ System.err.println("IL-->interrupted waiting for pixels!");
+ return;
+ }
+ if ((pg.getStatus() & ImageObserver.ABORT) != 0) {
+ System.err.println("IL-->image fetch aborted or errored, status="+pg.getStatus());
+ return ;
+ }
+ source = new MemoryImageSource(width,height,data,0,width);
+ image = obs.createImage(source);
if(DEBUG)System.out.println("IL ("+this+")-->Image Ready ");
setStatus(Layer.COMPLETED);
***************
*** 344,347 ****
--- 378,385 ----
*
* $Log$
+ * Revision 1.31 2001/12/10 16:13:57 ianturton
+ * added an internal buffer for the image source - this saves image reloads
+ * when pixelgrabber is called. Don't ask me why this should be but it is!
+ *
* Revision 1.30 2001/12/07 11:01:33 ianturton
* Removed unnecessary calls for updates in paint method
|
|
From: James M. <jma...@us...> - 2001-12-09 21:19:49
|
Update of /cvsroot/geotools/geotools/src/utils In directory usw-pr-cvs1:/tmp/cvs-serv29736/utils Modified Files: ShapeViewer.bat Log Message: increased default memory allowance Index: ShapeViewer.bat =================================================================== RCS file: /cvsroot/geotools/geotools/src/utils/ShapeViewer.bat,v retrieving revision 1.1 retrieving revision 1.2 diff -w -C2 -d -r1.1 -r1.2 *** ShapeViewer.bat 2001/06/15 13:04:38 1.1 --- ShapeViewer.bat 2001/12/09 21:19:47 1.2 *************** *** 4,7 **** echo (C)Center for Computational Geography under the GPL ! start javaw -cp jars\geotools.jar;jars\collections.jar;jars\support.jar;. ShapeViewer %1 echo on --- 4,7 ---- echo (C)Center for Computational Geography under the GPL ! start java -Xmx128mb -cp jars\geotools.jar;jars\collections.jar;jars\support.jar;. ShapeViewer %1 echo on |
|
From: James M. <jma...@us...> - 2001-12-09 21:18:06
|
Update of /cvsroot/geotools/geotools/src/utils In directory usw-pr-cvs1:/tmp/cvs-serv29317 Modified Files: ShapeViewer.java Log Message: added file dialog for when no shapefile is specifed in the commandline Index: ShapeViewer.java =================================================================== RCS file: /cvsroot/geotools/geotools/src/utils/ShapeViewer.java,v retrieving revision 1.2 retrieving revision 1.3 diff -w -C2 -d -r1.2 -r1.3 *** ShapeViewer.java 2001/06/15 13:09:14 1.2 --- ShapeViewer.java 2001/12/09 21:18:03 1.3 *************** *** 7,10 **** --- 7,12 ---- import java.net.*; + import java.io.*; + import java.awt.*; import uk.ac.leeds.ccg.geotools.*; import uk.ac.leeds.ccg.widgets.*; *************** *** 63,79 **** System.out.println("(C)Center for Computational Geography under the GPL"); System.out.println(); ! if(args.length<1){ ! System.err.println("Usage:ShapeView shapefile"); ! System.exit(1); } String base=args[0]; //String out = args[1]; System.out.println("reading "+base); ! URL url = new URL("file:///"+System.getProperty("user.dir")+"/"+base); ShapeViewer viewer = new ShapeViewer(url); viewer.setSize(500,500); viewer.show(); ! } --- 65,89 ---- System.out.println("(C)Center for Computational Geography under the GPL"); System.out.println(); ! URL url; if(args.length<1){ ! Frame f=new Frame(); ! FileDialog fd = new FileDialog(f); ! fd.setMode(FileDialog.LOAD); ! fd.setTitle("Select a shapefile"); ! fd.show(); ! url = new URL("file:///"+fd.getDirectory()+"/"+fd.getFile()); } + else{ String base=args[0]; //String out = args[1]; System.out.println("reading "+base); ! url = new URL("file:///"+System.getProperty("user.dir")+"/"+base); ! } ShapeViewer viewer = new ShapeViewer(url); + System.out.println("Constructed"); viewer.setSize(500,500); + viewer.setTitle(url.toString()); viewer.show(); ! System.out.println("Done"); } |
|
From: James M. <jma...@us...> - 2001-12-09 18:19:30
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools
In directory usw-pr-cvs1:/tmp/cvs-serv12454/uk/ac/leeds/ccg/geotools
Modified Files:
Quadtree.java
Log Message:
switched off debug
Index: Quadtree.java
===================================================================
RCS file: /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools/Quadtree.java,v
retrieving revision 1.6
retrieving revision 1.7
diff -w -C2 -d -r1.6 -r1.7
*** Quadtree.java 2001/11/19 18:17:07 1.6
--- Quadtree.java 2001/12/09 18:19:27 1.7
***************
*** 8,12 ****
public class Quadtree {
! private final static boolean DEBUG=true;
boolean top = false,clean=true;
int count=0;
--- 8,12 ----
public class Quadtree {
! private final static boolean DEBUG=false;
boolean top = false,clean=true;
int count=0;
|
|
From: James M. <jma...@us...> - 2001-12-09 18:14:03
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools In directory usw-pr-cvs1:/tmp/cvs-serv11399/uk/ac/leeds/ccg/geotools Removed Files: Test.java Log Message: test code should not be in the geotools package --- Test.java DELETED --- |
|
From: James M. <jma...@us...> - 2001-12-09 18:11:51
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools In directory usw-pr-cvs1:/tmp/cvs-serv11091/uk/ac/leeds/ccg/geotools Removed Files: SimpleDataField.java Log Message: never used --- SimpleDataField.java DELETED --- |
|
From: James M. <jma...@us...> - 2001-12-09 18:06:47
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools In directory usw-pr-cvs1:/tmp/cvs-serv9973/uk/ac/leeds/ccg/geotools Removed Files: DataField.java Log Message: never used --- DataField.java DELETED --- |
|
From: James M. <jma...@us...> - 2001-12-09 17:30:55
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools In directory usw-pr-cvs1:/tmp/cvs-serv2115/uk/ac/leeds/ccg/geotools Removed Files: BasicShapefileViewer.java Log Message: Demos should not be in the geotools package --- BasicShapefileViewer.java DELETED --- |
|
From: James M. <jma...@us...> - 2001-12-09 17:03:39
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools In directory usw-pr-cvs1:/tmp/cvs-serv27845/uk/ac/leeds/ccg/geotools Removed Files: AttributeShader.java Log Message: No longer supported shader type. --- AttributeShader.java DELETED --- |
|
From: James M. <jma...@us...> - 2001-12-09 16:57:09
|
Update of /cvsroot/geotools/geotools/src/uk/ac/leeds/ccg/geotools In directory usw-pr-cvs1:/tmp/cvs-serv26110/uk/ac/leeds/ccg/geotools Removed Files: AdvancedShadedShapefileViewer.java Log Message: in the wrong place, and out of date anyway --- AdvancedShadedShapefileViewer.java DELETED --- |