Top Level Namespace
Defined in:
Constant Summary
-
FOURPI =
4.0 * Math::PI
-
INV_FOURPI =
1.0 / FOURPI
-
INV_PI =
1.0 / Math::PI
-
INV_TWOPI =
1.0 / TWOPI
-
PI_OVER_FOUR =
Math::PI / 4
-
PI_OVER_TWO =
Math::PI / 2
-
RADIANTS =
Math::PI / 180
-
TWOPI =
2.0 * Math::PI
-
TODO Use these constants everywhere
Method Summary
- balance_heuristic(nf : Int32, f_pdf : Float64, ng : Int32, g_pdf : Float64)
- clamp(x, min, max)
- concentric_sample_disk(u1 : Float64 = rand, u2 : Float64 = rand) : ::Tuple(Float64, Float64)
- cosine_hemisphere_pdf(cos_theta : Float64)
- cosine_sample_hemisphere(u1 : Float64 = rand, u2 : Float64 = rand) : Vector
- max(a, b)
- min(a, b)
- minmax(a, b)
- mix(a, b, t)
- power_heuristic(nf : Int32, f_pdf : Float64, ng : Int32, g_pdf : Float64)
- radiants(n)
- random
- same_hemisphere?(v1, v2)
- sign(x : Float64)
- smoothstep(x)
- solve_quadratic(a, b, c) : ::Tuple(Float64, Float64)?
-
stratified_sample_1D(nx : Int32, jitter = true)
TODO this is a litte bit different in pbrt
-
stratified_sample_2D(nx : Int32, ny : Int32, jitter = true)
TODO this is a litte bit different in pbrt
- uniform_hemisphere_pdf
- uniform_sample_disk(u1 : Float64 = rand, u2 : Float64 = rand) : ::Tuple(Float64, Float64)
- uniform_sample_hemisphere(u1 : Float64 = rand, u2 : Float64 = rand)
- uniform_sample_sphere(u1 : Float64 = rand, u2 : Float64 = rand)
- uniform_sphere_pdf
Macro Summary
Method Detail
def concentric_sample_disk(u1 : Float64 = rand, u2 : Float64 = rand) : ::Tuple(Float64, Float64)
#
def stratified_sample_2D(nx : Int32, ny : Int32, jitter = true)
#
TODO this is a litte bit different in pbrt
def uniform_sample_disk(u1 : Float64 = rand, u2 : Float64 = rand) : ::Tuple(Float64, Float64)
#