33 #include <visp3/ustk_needle_modeling/usNeedleTipBeveled.h>
35 #include <visp3/core/vpException.h>
36 #include <visp3/core/vpHomogeneousMatrix.h>
41 :
usNeedleTip(tip), _diameter(tip._diameter), _length(tip._length)
79 s <<
"usNeedleTipBeveled\n";
93 if (c !=
"usNeedleTipBeveled") {
94 vpException e(vpException::ioError,
"Stream does not contain usNeedleTipBeveled data");
107 s.write(
"usNeedleTipBeveled", 19);
110 s.write((
char *)&(tip.
_diameter),
sizeof(
double));
111 s.write((
char *)&(tip.
_length),
sizeof(
double));
121 if (strcmp(c,
"usNeedleTipBeveled")) {
122 vpException e(vpException::ioError,
"Stream does not contain usNeedleTipBeveled data");
127 s.read((
char *)&(tip.
_diameter),
sizeof(
double));
128 s.read((
char *)&(tip.
_length),
sizeof(
double));
132 void usNeedleTipBeveled::updateTipPose()
134 double angle = this->
getAngle() / 2;
virtual ~usNeedleTipBeveled()
virtual usNeedleTipBeveled & operator=(const usNeedleTipBeveled &needle)
virtual usNeedleTipBeveled * clone() const
void setDiameter(double diameter)
Parameters setters and getters.
usNeedleTipBeveled()
Constructors, destructors.
double getDiameter() const
vpHomogeneousMatrix m_worldMbase
virtual usNeedleTip & operator=(const usNeedleTip &needle)
vpHomogeneousMatrix m_worldMtip