[GRASS-dev] v.what and spatial index

Trevor Wiens twiens at interbaun.com
Fri Sep 8 10:07:16 EDT 2006


On Fri, 08 Sep 2006 09:47:16 +0200
Moritz Lennert wrote:

> Glynn Clements wrote:
> > Moritz Lennert wrote:
> > 
> >> However, v.what does not have an interactive mode (that's the whole idea 
> >> of v.what so it fits better into the GUI). This means that since it 
> >> builds the spatial index everytime you call it, everytime you use the 
> >> query tool you get the building of the spatial index.
> >>
> >> Now, I see several options from here:
> > 
> >> - Change the query tool in the GUI so that it collects points and then 
> >> sends the whole series to v.what. This has the big disadvantage that you 
> >> don't see the results of your clicks immediately (i.e. you "blindly" 
> >> click on a series of points and then push "go" to see the results for 
> >> all of these points). It still means that whenever you resuse the query 
> >> tool spatial index gets rebuilt which can be very annoying if you have 
> >> to query information out of a map. So, even though this might be a 
> >> temporary "solution", I don't find it very satisfactory.
> >>
> >> - Reimplement an interactive version of v.what, or rather make it 
> >> possible to use d.what.vect from the GUI. This would probably mean 
> >> recoding d.what.vect in whatever the GUI language and call GRASS library 
> >> functions from there.
> > 
> > The obvious approach is to extend v.what to allow coordinates to be
> > read from stdin.
> > 
> > BTW, it appears that v.what currently ignores all coordinate pairs
> > other than the first.
> 
> Didn't even try that, but yes. Shouldn't be too hard to implement, 
> though. Trevor, any reason you left this out ?
> 

I simply removed the interactive functionality in d.what.vect which
Radim wrote. Other than that I made only minimal changes to the code.
That could be added however fairly easily. I think however the more
pressing issue is some of the re-write stuff that Radim refers to in
his TODO. At this time, I don't have the familiarity with the vector
library to work on that list of items, sorry. However, once the spatial
index is stored in a file and read as needed, this would eliminate the
need for entering multiple point sets wouldn't it? If however we need
multiple point sets, I'm sure that I could add that relatively quickly
if needed.

T
-- 
Trevor Wiens 
twiens at interbaun.com

The significant problems that we face cannot be solved at the same 
level of thinking we were at when we created them. 
(Albert Einstein)




More information about the grass-dev mailing list