projects
/
feisty_meow.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
or with the correct paths.
[feisty_meow.git]
/
graphiq
/
library
/
geometric
/
point.h
diff --git
a/graphiq/library/geometric/point.h
b/graphiq/library/geometric/point.h
index 0ebda9839ea43fbfe6565c76bc997d0bec696b57..00ed75a8bfbf9baabe9d174cbd3cad094a6a7279 100644
(file)
--- a/
graphiq/library/geometric/point.h
+++ b/
graphiq/library/geometric/point.h
@@
-121,7
+121,7
@@
void point<numeric_type>::set(numeric_type x, numeric_type y)
template <class numeric_type>
numeric_type point<numeric_type>::r() const
{
template <class numeric_type>
numeric_type point<numeric_type>::r() const
{
- const double sumsquar =
square(x()) +
square(y());
+ const double sumsquar =
basis::square(x()) + basis::
square(y());
return numeric_type(sqrt(sumsquar));
}
return numeric_type(sqrt(sumsquar));
}
@@
-132,7
+132,7
@@
void point<numeric_type>::set(numeric_type r, double_angle theta)
template <class numeric_type>
numeric_type point<numeric_type>::distance(const point &p2) const
{
template <class numeric_type>
numeric_type point<numeric_type>::distance(const point &p2) const
{
- const double sumsquar =
square(p2.x() - x()) +
square(p2.y() - y());
+ const double sumsquar =
basis::square(p2.x() - x()) + basis::
square(p2.y() - y());
return numeric_type(sqrt(sumsquar));
}
return numeric_type(sqrt(sumsquar));
}
@@
-170,7
+170,7
@@
bool point<contents>::unpack(basis::byte_array &packed_form)
template <class numeric_type>
numeric_type point<numeric_type>::magnitude() const
{
template <class numeric_type>
numeric_type point<numeric_type>::magnitude() const
{
- const double sumsquar =
square(x()) +
square(y());
+ const double sumsquar =
basis::square(x()) + basis::
square(y());
return numeric_type(sqrt(sumsquar));
}
return numeric_type(sqrt(sumsquar));
}
@@
-195,8
+195,8
@@
bool point<numeric_type>::operator == (const point &arg2) const
{
// this bit should be part of the floating point stuff...
double epsilon = 1e-10;
{
// this bit should be part of the floating point stuff...
double epsilon = 1e-10;
- return (absolute_value(x() - arg2.x()) <= epsilon)
- && (absolute_value(y() - arg2.y()) <= epsilon);
+ return (
basis::
absolute_value(x() - arg2.x()) <= epsilon)
+ && (
basis::
absolute_value(y() - arg2.y()) <= epsilon);
}
template <class numeric_type>
}
template <class numeric_type>