|
Photon Engine 2.0.0-beta
A physically based renderer.
|
Detailed information regarding a ray-primitive intersection. More...
#include <HitDetail.h>
Public Member Functions | |
| HitDetail () | |
| Creates a hit detail filled with default values. | |
| HitDetail & | setHitIntrinsics (const Primitive *primitive, const math::Vector3R &uvw, real rayT, uint64 faceID=NO_FACE_ID, FaceTopology faceTopology=FaceTopology(EFaceTopology::General)) |
| Set essential attributes that are independent to the coordinate system. | |
| void | computeBases () |
| math::Vector3R | getPos (ECoordSys coordSys=ECoordSys::World) const |
| math::Vector3R | getShadingNormal (ECoordSys coordSys=ECoordSys::World) const |
| math::Vector3R | getGeometryNormal (ECoordSys coordSys=ECoordSys::World) const |
| math::Vector3R | getdPdU (ECoordSys coordSys=ECoordSys::World) const |
| math::Vector3R | getdPdV (ECoordSys coordSys=ECoordSys::World) const |
| math::Vector3R | getdNdU (ECoordSys coordSys=ECoordSys::World) const |
| math::Vector3R | getdNdV (ECoordSys coordSys=ECoordSys::World) const |
| math::Vector3R | getUVW () const |
| const math::Basis3R & | getGeometryBasis (ECoordSys coordSys=ECoordSys::World) const |
| const math::Basis3R & | getShadingBasis (ECoordSys coordSys=ECoordSys::World) const |
| real | getRayT () const |
| Get the parametric distance from the incident ray's origin. Notice that parametric distance is not ordinary distance but defined in terms of a ray direction vector's length. | |
| uint64 | getFaceID () const |
| Get the face ID associated to the hit. | |
| FaceTopology | getFaceTopology () const |
| const Primitive * | getPrimitive () const |
| const HitInfo & | getHitInfo (ECoordSys coordSys=ECoordSys::World) const |
| HitInfo & | getHitInfo (ECoordSys coordSys=ECoordSys::World) |
| std::pair< real, real > | getDistanceErrorFactors () const |
| void | setDistanceErrorFactors (real meanFactor, real maxFactor) |
Static Public Attributes | |
| static constexpr auto | NO_FACE_ID = static_cast<uint64>(-1) |
Detailed information regarding a ray-primitive intersection.
| ph::HitDetail::HitDetail | ( | ) |
Creates a hit detail filled with default values.
| void ph::HitDetail::computeBases | ( | ) |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Get the face ID associated to the hit.
NO_FACE_ID if not available.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
Get the parametric distance from the incident ray's origin. Notice that parametric distance is not ordinary distance but defined in terms of a ray direction vector's length.
|
inline |
|
inline |
|
inline |
|
inline |
| HitDetail & ph::HitDetail::setHitIntrinsics | ( | const Primitive * | primitive, |
| const math::Vector3R & | uvw, | ||
| real | rayT, | ||
| uint64 | faceID = NO_FACE_ID, | ||
| FaceTopology | faceTopology = FaceTopology(EFaceTopology::General) ) |
Set essential attributes that are independent to the coordinate system.
| primitive | The primitive that was hit. |
| uvw | The parametric coordinates of the hit. |
| rayT | The parametric distance of the hit relative to the ray. The unit of this value depends on the length of the ray's direction vector. |
| faceID | ID of the face that was hit. This ID may not be globally unique, see getFaceID(). |
| faceTopology | Surface topology locally around the hit point. |
|
inlinestaticconstexpr |