34 #ifndef SOMAIO_TRANSFORMATION_TRANSFORMATION_H 35 #define SOMAIO_TRANSFORMATION_TRANSFORMATION_H 85 Point3dd transform(
double x,
double y,
double z )
const;
88 Point3df transform(
float x,
float y,
float z )
const;
105 virtual std::unique_ptr<Transformation3d>
getInverse()
const {
106 throw std::logic_error(
"not implemented");
112 virtual Point3dd transformDouble(
double x,
double y,
double z )
const = 0;
116 virtual Point3df transformFloat(
float x,
float y,
float z )
const;
125 return transformDouble( x, y, z );
132 return transformFloat( x, y, z );
138 return transformPoint3df( pos );
145 return transformPoint3dd( pos );
152 return transformPoint3d( pos );
159 Point3dd transformed = transform( (
double) pos[0], (
double) pos[1],
161 return Point3df( (
float) transformed[0], (
float) transformed[1],
162 (
float) transformed[2] );
169 return transform( pos[0], pos[1], pos[2] );
176 Point3dd transformed = transform( (
double) x, (
double) y, (
double) z );
177 return Point3df( (
float) transformed[0], (
float) transformed[1],
178 (
float) transformed[2] );
184 Point3dd transformed = transform( (
double) p[0], (
double) p[1],
186 return Point3d( (int16_t) rint( transformed[0] ),
187 (int16_t) rint( transformed[1] ),
188 (int16_t) rint( transformed[2] ) );
The template class to implement basic vectors.
AimsVector< float, 3 > Point3df
AimsVector< int16_t, 3 > Point3d