ty for reply ; I've developed using my structure ;
MapGraphic { FeatureCollection (geotools) ; MapContent ( geotools ); StreaminRenderer (geotols); draw(context){ render graphic using streamingRenderer; } onDataChange(){ updateFeatureCollection; context.getLayer.refresh; } its working really fast. ty for advice. On Jul 5, 2012, at 5:04 PM, Jody Garnett wrote: > MapGraphic is intended for really fast feedback (i.e. no disk IO) - so > rendering from an in memory feature collection could be done! You can steal > the technique from BasicFeatureRenderer if you like … > > In the past, for tracking moving objects we have had good luck with one > thread filling in a data structure; and a map graphic drawing out of the data > structure using a timer (as with some of the animation examples). There is > also a glass layer you can place overtop of your map for more direct SWT > rendering. > > Note you can render a Memory based FeatureSource - there is no reason the > transaction code needs to involve writes to disk. GeoTools has several > implementations now (the original based on a Tree which sorts the features by > featureId, a list based one allowing you to wrap your own list up as a > feature collection, and a spatial index solution used for drawing > performance). > -- > Jody Garnett > > On Wednesday, 4 July 2012 at 9:53 PM, omur yavuz wrote: > >> Hi , >> >> i ve a question about mapgraphic rendering. map has a polygon layer named >> "A". some of attributes of layer changes dynamically in another thread. >> The easiest way to update "A" FeatureStrore every time attributes changes >> and re-render layer , but i don't want to use this method because of >> transaction management , disk writes vs. so I'm planning to create a >> FeatureCollection in memory and mapping it to a MapGraphic layer. >> how can i render FeatureCollection inside MapGraphic draw method . should i >> use MapGraphicContext RenderManager to create a renderer (and how) ? , or >> simply create a StreamingRenderer and empty Geotools MapContext inside >> MapGraphic ? >> >> Thanks For Help, >> >> >> _______________________________________________ >> User-friendly Desktop Internet GIS (uDig) >> http://udig.refractions.net >> http://lists.refractions.net/mailman/listinfo/udig-devel > > _______________________________________________ > User-friendly Desktop Internet GIS (uDig) > http://udig.refractions.net > http://lists.refractions.net/mailman/listinfo/udig-devel
_______________________________________________ User-friendly Desktop Internet GIS (uDig) http://udig.refractions.net http://lists.refractions.net/mailman/listinfo/udig-devel