Photon Engine 2.0.0-beta
A physically based renderer.
Loading...
Searching...
No Matches
SGUtil.h
Go to the documentation of this file.
1#pragma once
2
3#include "Math/TVector2.h"
4
5#include <Common/assertion.h>
6
7#include <cstddef>
8
9namespace ph
10{
11
12class SGUtil final
13{
14public:
15 static void genArray2dStrata(math::Vector2R* out_coordArray2Ds, std::size_t numXs, std::size_t numYs);
16 static void genArray2dLatinHypercube(math::Vector2R* out_coordArray2Ds, std::size_t num2Ds);
17
18 template<typename T>
19 static void shuffleDurstenfeld(T* out_array, std::size_t arraySize);
20};
21
22// method template implementations:
23
24template<typename T>
25void SGUtil::shuffleDurstenfeld(T* const out_array, const std::size_t arraySize)
26{
27 for(std::size_t i = arraySize - 1; i > 0; i--)
28 {
29 // TODO
30 PH_ASSERT_UNREACHABLE_SECTION();
31 }
32}
33
34}// end namespace ph
Definition SGUtil.h:13
static void shuffleDurstenfeld(T *out_array, std::size_t arraySize)
Definition SGUtil.h:25
static void genArray2dLatinHypercube(math::Vector2R *out_coordArray2Ds, std::size_t num2Ds)
Definition SGUtil.cpp:25
static void genArray2dStrata(math::Vector2R *out_coordArray2Ds, std::size_t numXs, std::size_t numYs)
Definition SGUtil.cpp:7
The root for all renderer implementations.
Definition EEngineProject.h:6