diff --git a/src/pe/raytracing/Raytracer.cpp b/src/pe/raytracing/Raytracer.cpp index 4a88ff18381de87bf6d885415ca243b580728985..b7e5c06ef8f01791852af85d8c11ac5620d680a6 100644 --- a/src/pe/raytracing/Raytracer.cpp +++ b/src/pe/raytracing/Raytracer.cpp @@ -88,7 +88,9 @@ Raytracer::Raytracer(const shared_ptr<BlockStorage> & forest, BlockDataID storag setupView_(); } - + +/*!\brief Utility function for setting up the view plane and calculating required variables. + */ void Raytracer::setupView_() { // eye coordinate system setup n = (cameraPosition_ - lookAtPoint_).getNormalized(); diff --git a/src/pe/raytracing/Raytracer.h b/src/pe/raytracing/Raytracer.h index 933c5d70b657b3c40dd93efd9c287dc2ccd3bb02..cfdb14b3d8459518b5e3729406b1ba7c2558fb13 100644 --- a/src/pe/raytracing/Raytracer.h +++ b/src/pe/raytracing/Raytracer.h @@ -32,26 +32,30 @@ namespace walberla { namespace pe { namespace raytracing { +/*!\brief Contains information about a ray-body intersection. + */ struct BodyIntersectionInfo { - size_t imageX; // viewing plane pixel coordinates to ... - size_t imageY; // ... identify ray by pixel it intersected - walberla::id_t bodySystemID; // body which was hit - real_t t; // distance from camera to intersection point on body + size_t imageX; //!< viewing plane x pixel coordinate the ray belongs to. + size_t imageY; //!< viewing plane y pixel coordinate the ray belongs to. + walberla::id_t bodySystemID; //!< system ID of body which was hit. + real_t t; //!< distance from camera to intersection point on body. }; +/*!\brief Simple struct for coordinates. + */ struct Coordinates { size_t x; size_t y; }; +/*!\brief Comparator for Coordinates struct with standard lexicographical ordering. + */ struct CoordinatesComparator { bool operator() (const Coordinates& lhs, const Coordinates& rhs) const { - // standard lexicographical ordering return (lhs.x < rhs.x) || (lhs.x == rhs.x && lhs.y < rhs.y); } }; - class Raytracer { public: /*!\name Constructors */