summaryrefslogtreecommitdiffstats
path: root/src/edge.c
diff options
context:
space:
mode:
authorDavid Robillard <d@drobilla.net>2011-12-14 05:29:47 +0000
committerDavid Robillard <d@drobilla.net>2011-12-14 05:29:47 +0000
commit3680d163650c1d79869952520aba2eae281da95e (patch)
treebd372ecf5b1c954e6bffd6c9415c641983d106e2 /src/edge.c
parenta70ec768ee9a3a5783f2c07feb77e67ced78a802 (diff)
downloadganv-3680d163650c1d79869952520aba2eae281da95e.tar.gz
ganv-3680d163650c1d79869952520aba2eae281da95e.tar.bz2
ganv-3680d163650c1d79869952520aba2eae281da95e.zip
Draw directly to window cairo context instead of gdk pixmap.
git-svn-id: http://svn.drobilla.net/lad/trunk/ganv@3875 a436a847-0d15-0410-975c-d299462d15a1
Diffstat (limited to 'src/edge.c')
-rw-r--r--src/edge.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/edge.c b/src/edge.c
index 22a0ba9..8d43f46 100644
--- a/src/edge.c
+++ b/src/edge.c
@@ -300,10 +300,10 @@ ganv_edge_draw(GanvItem* item,
GanvEdge* edge = GANV_EDGE(item);
GanvEdgeImpl* impl = edge->impl;
- double src_x = impl->coords.x1 - x;
- double src_y = impl->coords.y1 - y;
- double dst_x = impl->coords.x2 - x;
- double dst_y = impl->coords.y2 - y;
+ double src_x = impl->coords.x1;
+ double src_y = impl->coords.y1;
+ double dst_x = impl->coords.x2;
+ double dst_y = impl->coords.y2;
double dx = src_x - dst_x;
double dy = src_y - dst_y;
@@ -332,16 +332,16 @@ ganv_edge_draw(GanvItem* item,
// Path 1 (src_x, src_y) -> (join_x, join_y)
// Control point 1
- const double src_x1 = impl->coords.cx1 - x;
- const double src_y1 = impl->coords.cy1 - y;
+ const double src_x1 = impl->coords.cx1;
+ const double src_y1 = impl->coords.cy1;
// Control point 2
const double src_x2 = (join_x + src_x1) / 2.0;
const double src_y2 = (join_y + src_y1) / 2.0;
// Path 2, (join_x, join_y) -> (dst_x, dst_y)
// Control point 1
- const double dst_x1 = impl->coords.cx2 - x;
- const double dst_y1 = impl->coords.cy2 - y;
+ const double dst_x1 = impl->coords.cx2;
+ const double dst_y1 = impl->coords.cy2;
// Control point 2
const double dst_x2 = (join_x + dst_x1) / 2.0;
const double dst_y2 = (join_y + dst_y1) / 2.0;