From 6834ea10320ab9a479bc511af540dedeecaa5629 Mon Sep 17 00:00:00 2001 From: Pascal Grittmann Date: Thu, 8 Aug 2024 17:03:54 +0200 Subject: [PATCH] docs --- SeeSharp/Shading/Background/Background.cs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/SeeSharp/Shading/Background/Background.cs b/SeeSharp/Shading/Background/Background.cs index a6730a4..5ea816a 100644 --- a/SeeSharp/Shading/Background/Background.cs +++ b/SeeSharp/Shading/Background/Background.cs @@ -13,6 +13,12 @@ public abstract class Background { public abstract BackgroundSample SampleDirection(Vector2 primary); public abstract Vector2 SampleDirectionInverse(Vector3 Direction); + + /// + /// Computes the PDF for sampling a given direction from the background + /// + /// Direction from the scene towards the background + /// Solid angle PDF public abstract float DirectionPdf(Vector3 Direction); public abstract (Ray, RgbColor, float) SampleRay(Vector2 primaryPos, Vector2 primaryDir); public abstract (Vector2, Vector2) SampleRayInverse(Vector3 dir, Vector3 pos);