mpri-graphics-project/tests/TestImplicitSphere.hpp
Théophile Bastian 7b374c70ae Surfaces now provide a location hint
This is supposed to be a point in space close to the surface
2018-02-13 18:42:15 +01:00

15 lines
371 B
C++

#pragma once
#include "../Implicit.hpp"
class TestImplicitSphere: public ImplicitSurface {
public:
TestImplicitSphere(const Point& center, double r):
ImplicitSurface(center), radius(r) {}
virtual double operator()(double x, double y, double z) const;
virtual Point location_hint() const;
private:
double radius;
};