added missing projection transformation for label placement.

TODO: move to geometry class to always return transformed label position
This commit is contained in:
Artem Pavlenko 2006-10-21 12:16:19 +00:00
parent 118e8f0d52
commit a3817cc362

View file

@ -395,6 +395,11 @@ namespace mapnik
else
{
p->geom->label_position(&p->starting_x, &p->starting_y);
// TODO:
// We would only want label position in final 'paper' coords.
// Move view and proj transforms to e.g. label_position(x,y,proj_trans,ctrans)?
double z=0;
p->proj_trans->backward(p->starting_x, p->starting_y, z);
p->ctrans->forward(&p->starting_x, &p->starting_y);
}