static pointf Offset;
static point Viewport;
-static pointf GraphFocus;
static node_t *Curnode;
point rv;
if (Rot) {
-#if 0
- rv.x = ROUND(-(p.y - GraphFocus.y) * CompScale.x + Viewport.x / 2.);
- rv.y = ROUND( (p.x - GraphFocus.x) * CompScale.y + Viewport.y / 2.);
- } else {
- rv.x = ROUND( (p.x - GraphFocus.x) * CompScale.x + Viewport.x / 2.);
- rv.y = ROUND( (p.y - GraphFocus.y) * CompScale.y + Viewport.y / 2.);
-#else
rv.x = ROUND(-p.y * CompScale.x + Offset.x);
rv.y = ROUND( p.x * CompScale.y + Offset.y);
} else {
rv.x = ROUND( p.x * CompScale.x + Offset.x);
rv.y = ROUND( p.y * CompScale.y + Offset.y);
-#endif
}
return rv;
}
{
Viewport.x = gvc->job->width;
Viewport.y = gvc->job->height;
- GraphFocus = gvc->job->focus;
CompScale = gvc->job->compscale;
Offset = gvc->job->offset;