[Qgis-developer] Renderer for vector field data

Barry Rowlingson b.rowlingson at lancaster.ac.uk
Fri Jan 8 03:05:06 EST 2010


On Fri, Jan 8, 2010 at 1:11 AM, Chris Crook <ccrook at linz.govt.nz> wrote:
> I'm wanting a renderer for vector field data.  In my case this is earth
> deformation data - surface displacements - but it could as easily be
> hydrological flow, or other such data.
>
> Ideally this will display an arrow of length and orientation based on data
> values (x,y or length,orientation) at points, but with some independent
> overall scaling to allow all the vectors in a layer to be rescaled without
> recalculating the data.  To be perfect (!) it would also take account of the
> projection convergence when using on the fly projections (though I could
> live without that, at least initially!)
>
> Do you know of a plug-in that does that?
>
> If not, is it possible to build a renderer like this with a python plug-in?
>
> And if it is possible, can you point me to any examples of a python renderer
> plug in that I could build from (I haven't programmed python or the Qgis/Qt
> API before, so examples would be really helpful!!)
>

 Here's a link to a python renderer I wrote that colours features
according to the ratio of two attributes:

http://www.maths.lancs.ac.uk/~rowlings/Software/ratioRenderer/

 this was a couple of years ago so expect to have to tweak it for
modern qgis versions.

 hope that helps. You'll need to write a renderFeature function that
draws your arrows.

Barry


More information about the Qgis-developer mailing list