+ don't compensate dx/dy

This commit is contained in:
Artem Pavlenko 2010-09-10 13:49:21 +00:00
parent acd05cb5cd
commit 46f9a7188a

View file

@ -346,8 +346,8 @@ void agg_renderer<T>::process(shield_symbolizer const& sym,
// remove displacement from image label
double lx = x - boost::get<0>(pos);
double ly = y - boost::get<1>(pos);
px=int(floor(lx - (0.5 * w))) + 1;
py=int(floor(ly - (0.5 * h))) + 1;
px=int(floor(lx - (0.5 * w)));
py=int(floor(ly - (0.5 * h)));
label_ext.init( floor(lx - 0.5 * w), floor(ly - 0.5 * h), ceil (lx + 0.5 * w), ceil (ly + 0.5 * h) );
}
else
@ -387,8 +387,8 @@ void agg_renderer<T>::process(shield_symbolizer const& sym,
double lx = x - boost::get<0>(pos);
double ly = y - boost::get<1>(pos);
int px=int(floor(lx - (0.5*w))) + 1;
int py=int(floor(ly - (0.5*h))) + 1;
int px=int(floor(lx - (0.5*w)));
int py=int(floor(ly - (0.5*h)));
pixmap_.set_rectangle_alpha(px,py,*(*data));
if (writer.first) writer.first->add_box(box2d<double>(px,py,px+w,py+h), feature, t_, writer.second);