summaryrefslogtreecommitdiffstats
path: root/src/libnr
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2010-03-26 04:34:25 +0000
committerTed Gould <ted@gould.cx>2010-03-26 04:34:25 +0000
commit9e023a3aa964a0d3fa1e31e46d33657367ba68aa (patch)
tree33f1392a340737e4eeefca6fd031f96c29befd2b /src/libnr
parentInstalling the pkgconfig file (diff)
parentAdding in shape-record.h (diff)
downloadinkscape-9e023a3aa964a0d3fa1e31e46d33657367ba68aa.tar.gz
inkscape-9e023a3aa964a0d3fa1e31e46d33657367ba68aa.zip
Merge from trunk
(bzr r8254.1.53)
Diffstat (limited to 'src/libnr')
-rw-r--r--src/libnr/nr-point-fns.cpp13
-rw-r--r--src/libnr/nr-point-fns.h2
2 files changed, 0 insertions, 15 deletions
diff --git a/src/libnr/nr-point-fns.cpp b/src/libnr/nr-point-fns.cpp
index 5082c3a10..0142655f2 100644
--- a/src/libnr/nr-point-fns.cpp
+++ b/src/libnr/nr-point-fns.cpp
@@ -61,19 +61,6 @@ NR::Point abs(NR::Point const &b)
return ret;
}
-NR::Point *
-get_snap_vector (NR::Point p, NR::Point o, double snap, double initial)
-{
- double r = NR::L2 (p - o);
- if (r < 1e-3)
- return NULL;
- double angle = NR::atan2 (p - o);
- // snap angle to snaps increments, starting from initial:
- double a_snapped = initial + floor((angle - initial)/snap + 0.5) * snap;
- // calculate the new position and subtract p to get the vector:
- return new NR::Point (o + r * NR::Point(cos(a_snapped), sin(a_snapped)) - p);
-}
-
NR::Point
snap_vector_midpoint (NR::Point p, NR::Point begin, NR::Point end, double snap)
{
diff --git a/src/libnr/nr-point-fns.h b/src/libnr/nr-point-fns.h
index e927725b4..9ef7205c6 100644
--- a/src/libnr/nr-point-fns.h
+++ b/src/libnr/nr-point-fns.h
@@ -90,8 +90,6 @@ Point abs(Point const &b);
} /* namespace NR */
-NR::Point *get_snap_vector (NR::Point p, NR::Point o, double snap, double initial);
-
NR::Point snap_vector_midpoint (NR::Point p, NR::Point begin, NR::Point end, double snap);
double get_offset_between_points (NR::Point p, NR::Point begin, NR::Point end);