[Qgis-developer] Viewport rotation

Sandro Santilli strk at keybit.net
Thu Nov 20 02:54:01 PST 2014


On Thu, Nov 20, 2014 at 09:01:55AM +1100, Nyall Dawson wrote:
> On 20 November 2014 07:46, Sandro Santilli <strk at keybit.net> wrote:
> > Hi all,
> > I'm looking at implementing viewport rotation support and wondering if
> > anyone has already an idea about what it would take.
> >
> > Could adding support in QgsMapToPixel be possibly enough to make
> > navigation tools aware of rotation ? Or would it be better to plug
> > another transformation in between, as if it was a reprojection ?
> >
> 
> Hi Sandro,
> 
> How are you thinking of implementing this? In the map canvas only?

I don't know yet, that's why I'm asking.

> Ideally, I think this should be supported in the map renderer -
> QgsMapRendererJob.

Would that be similar to considering it an additional transformation
on the input data, like reprojection ?

> Currently the composer supports rotated maps, but it's a bit of a
> hack. It's really just rendering the map and then rotating the result.
> As a result all labels, symbology, etc also get rotated, which isn't
> ideal. If support for rotating maps was added to the actual map
> renderer then the composer would also benefit, as we'd be able to
> properly rotate the map without messing up labels and symbology.

Yep, makes sense. I'll try to understand what it takes.
Thanks for the pointers so far.

--strk;

 ()  ASCII ribbon campaign  --  Keep it simple !
 /\  http://strk.keybit.net/rants/ascii_mails.txt  


More information about the Qgis-developer mailing list