gis

Algorithm for finding nearby points?

Given a set of several million points with x,y coordinates, what is the algorithm of choice for quickly finding the top 1000 nearest points from a location? "Quickly" here means about 100ms on a home computer. Brute force would mean doing millions of multiplications and then sorting them. While even a simple Python app could do that in ...

Is there a way to get graphic text to scale in ArcMap?

I'm using this code to create text in ArcMap. But I can't seem to get it to scale like annotation text when you zoom in. Does anyone know how to do this? //'First setup a color. We'll use RGB red IRgbColor pRGBcolor = new RgbColor(); pRGBcolor.Blue = 0; pRGBcolor.Red = 255; ...

Java equivalent of OpenLayers

I am looking for a Java library to display map data from various sources, including shapefile, WMS, WFS, Google Maps, possibly ArcIMS, etc. It seems like OpenLayers is the closest thing to what I want, except it's a JavaScript library, and I'm writing a Swing application. GDAL looks promising, but as far as I can tell there won't be Jav...

Building a buffer over a terrain model

I have a polygon and a terrain model (can be either grid or TIN). I'd like to a build, say, a 1km buffer so that the 1km is measured over the surface of the terrain, i.e. not planimetric. The buffer must always be at least 1km from the polygon and prefer a measure over the flattest part of the terrain. Anyone know a good way to do th...

ArcGIS : Labels only rendered at 10,000,000 scale

I'm using ArcGIS Server 9.3 with an Oracle 10.2g database. I've created an MXD which contains my feature class and I've configured it to show one of the attributes as a label - both the feature class and the label are set to be visible at all scales. In ArcMap, the labels only show at a scale of 1:10,000,000 - as soon as I zoom in they ...

General Address Parser for Freeform Text

We have a program that displays map data (think Google Maps, but with much more interactivity and custom layers for our clients). We allow navigation via a set of combo boxes that prefill certain fields with a bunch of data (ie: Country: Canada, the Province field is filled in. Select Ontario, and a list of Counties/Regions is filled i...

GIS / Map display component

For a quick demonstrator I'm looking for a SWT or Swing component which can display geographical data. Unfortunatly I'm disconnected from the internet, so Google Maps won't help. The general idea is to assemble a small eclipse RCP application with just 'map view', connect to a custom web service, that provides geographical data (tracks)...

SQL query for point-in-polygon using Postgres

I have the following simple table: CREATE TABLE tbl_test ( id serial NOT NULL, poly polygon NOT NULL ) WITH (OIDS=FALSE); I then try to insert a row with a polygon: insert into tbl_test values(1, PolyFromText('POLYGON((0 0, 10 10, 10 0, 0 0))')) And run into this error: column "poly" is of type polygon but expression is of ...

(Simple?) Label Placement for Line Graphs

I'm drawing elevation profiles showing the elevation gain/loss along a trail, similar to the one below: This is basically a line graph with distance from the start on the x-axis and elevation on the y-axis. I'd like to provide fancy labels with spot elevations at interesting points along the trail, like the ones I have added by hand ...

How can I edit mif/mid gis data format?

Hello! I am working on an application (.net 2.0) that uses mif/mid data format to display GIS data. I need to find a way to edit these files with some sort of editor (outside of application). I googled a lot but was unable to find anything suitable (Map Maker worked but did not display labels from mid file). I see following solutions (...

Guidelines for GIS application development

Hi, i need some help! I'm supposed to create a GIS application for my MSc, and I was wondering what are the best free and (preferably) open source technologies for development. What programming language to use for development of such application. Known choices are: Database: PostgreSQL (PostGIS) (suggest other) Programming Language: PH...

See if lat / long falls within a polygon using mysql

I have the created the table below CREATE TABLE geom (g GEOMETRY); and have inserted many rows, example below: INSERT INTO geom (g) VALUES(PolygonFromText('POLYGON(( 9.190586853 45.464518970, 9.190602686 45.463993916, 9.191572471 45.464001929, 9.191613325 45.463884676, 9.192136130 45.463880767, 9.192111509 45.464095594, 9.192427961 4...

Does anyone know of any good open source Geodjango apps to dig through?

I'm looking to build a small GIS in my spare time and have been digging into Geodjango. I've been trying to find examples of open source Geodjango projects to look through, but I have had little luck, so here I am. I've been through most of the tutorials I could find, but they all seem to stop at the same point and I'm curious to loo...

How to look up elevation data by lat/lng

I am planning an app that will need the ability to look up the elevation of geographic points by lat/lng. Ideally I would like something that would work worldwide, but US-only would also suffice. I have looked at using the USGS Elevation Query Web Service, however it only allows you to query for one point at a time, and I will need to lo...

Using Java and any external libraries, how can I draw latitude/longitude points onto a graphical representation of the Earth?

I'm currently using the Java Map Projection Library (I was able to obtain the code used for the Applet from the author and modify it for use in a desktop application - not sure if he linked to that on his website yet) to draw a map of the Earth in an application. However, I want to take this a step further. I have a set of latitude/longi...

How do I find the lat/long that is x km north of a given lat/long

I have some C# code that generates google maps. This codes looks at all the Points I need to plot on the map and then works out the Bounds of a rectangle to include those points. It then passes this bounds to the Google Maps API to set the zoom level appropriately to show all of the points on the map. This code is working fine however I...

dojo dialog - check to see it is loaded

I am running a function that needs to close a dojo dialog if it is loaded. How do I check if a dojo dialog is running? Do I use pure javascript and check by id if it is undefined? if (dijit.byId("blah") !== undefined) { destroyRecursive dijit; } Or do i use a property of the dialog object like isFocusable method isLoaded pro...

How can I find if a lat long coordinate is valid in a coordinate system?

If I have a point in latitude/longitude and I want to find out if it is a valid for use within a particular coordinate system, how can I do it? As an example. Say I am working in Swiss Grid (CH 1903, EPSG 21781) and have a point representing something in London in the UK, I want to know if that point is valid in the Swiss Grid coordinat...

Good GIS Software or Components for Windows PC in .NET?

Last week i searched for good free or opensource solutions and component for GIS (Geographical Information Systems) I founded some system but no one fill my requirements SharpMap is very buggy software Gmap.net is very slow MapWindow have a very complex structure and is very buggy. I founded uDIG but is in java, i need a solution i...

Local data sources for GIS Map plugin?

I am developing an ASP.NET intranet application that needs to have an interactive map interface. There are some pretty neat Silverlight mapping plugins that I think could work well, specifically: ArcGIS Silverlight API: http://resources.esri.com/arcgisserver/apis/silverlight/ DeepEarth mapping framework: http://www.codeplex.com/deepe...