Photon Engine 2.0.0-beta
A physically based renderer.
Loading...
Searching...
No Matches
PLatLong01Sphere.h
Go to the documentation of this file.
1#pragma once
2
4#include "Math/math_fwd.h"
5
6namespace ph
7{
8
10{
11public:
12 explicit PLatLong01Sphere(real radius);
13
14 void calcHitDetail(
15 const Ray& ray,
16 HitProbe& probe,
17 HitDetail* out_detail) const override;
18
19 void genPosSample(
21 SampleFlow& sampleFlow,
22 HitProbe& probe) const override;
23
24 void calcPosPdf(PrimitivePosPdfQuery& query) const override;
25
28 math::Vector2R posToUV(const math::Vector3R& position) const;
29};
30
31}// end namespace ph
Detailed information regarding a ray-primitive intersection.
Definition HitDetail.h:26
Lightweight ray intersection testing and reporting object. If an intersection is found,...
Definition HitProbe.h:27
Definition PBasicSphere.h:14
Definition PLatLong01Sphere.h:10
void calcHitDetail(const Ray &ray, HitProbe &probe, HitDetail *out_detail) const override
Calculates properties of a hit, such as coordinates and normal.
Definition PLatLong01Sphere.cpp:20
PLatLong01Sphere(real radius)
Definition PLatLong01Sphere.cpp:16
void genPosSample(PrimitivePosSampleQuery &query, SampleFlow &sampleFlow, HitProbe &probe) const override
Generates a sample point on the surface of this primitive.
Definition PLatLong01Sphere.cpp:77
void calcPosPdf(PrimitivePosPdfQuery &query) const override
Given a point on the surface of this primitive, calculates the PDF of sampling this point.
Definition PLatLong01Sphere.cpp:100
math::Vector2R posToUV(const math::Vector3R &position) const
Maps a position on the sphere surface to UV coordinates (lat-long-01 format).
Definition PLatLong01Sphere.cpp:106
Information for the probability of generating a specific sample point on a primitive.
Definition PrimitivePosPdfQuery.h:91
Information for generating a sample point on a primitive.
Definition PrimitivePosSampleQuery.h:132
Represents a ray in space.
Definition Ray.h:21
A sample with arbitrary dimensions with fine-grained sampling control.
Definition SampleFlow.h:19
The root for all renderer implementations.
Definition EEngineProject.h:6