From: Jody G. <jod...@gm...> - 2009-04-25 08:24:11
|
Have a look at the StyleVisitor interface; you can use that to visit all the symbolizer elements used to rendering your features (and figure out what the target size is; and then use that size rather than 3x3 to determine your selection bounds). Note: In uDig we render each layer individual; allowing me to experimented in the past with just checking the pixels to see if anything is hit before trying to do a feature based query; this is only useful if you are rendering content onto individual rasters and then merging them. Jody On Sat, Apr 25, 2009 at 1:56 AM, yako yako <ya...@ho...> wrote: > Hello, > > I am making an application where the user can retrieve information from a > feature by clicking on it. > > To do this, I make a filter to get all features located on the area defined > by the projection on the map > of a 3x3 pixels square centered on the position of the click. > > I encouter a problem with Feature represented by a symbol because this > symbol can be bigger than > the real geometry of the feature. So we can not click anywhere on it to > retrieve its information. > > Is it possible to get the bounds of the symbol used to represent a feature > in order to compute its projection > on the map and check if it intersects the 'click area'? > > Is there an other way to assign a feature to a pixel on the map whatever its > type of representation is ? > > I hope I've been clear enough. > > Thank you, > > Yako Bak. > > ________________________________ > Découvrez toutes les possibilités de communication avec vos proches > ------------------------------------------------------------------------------ > Crystal Reports - New Free Runtime and 30 Day Trial > Check out the new simplified licensign option that enables unlimited > royalty-free distribution of the report engine for externally facing > server and web deployment. > http://p.sf.net/sfu/businessobjects > _______________________________________________ > Geotools-gt2-users mailing list > Geo...@li... > https://lists.sourceforge.net/lists/listinfo/geotools-gt2-users > > |