OpenQMC API
Loading...
Searching...
No Matches
bntables.h File Reference
#include "encode.h"
#include "gpu.h"
#include <cstdint>
#include "data/pmj/keys.txt"
#include "data/pmj/ranks.txt"
#include "data/sobol/keys.txt"
#include "data/sobol/ranks.txt"
#include "data/lattice/keys.txt"
#include "data/lattice/ranks.txt"
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  oqmc::bntables::TableReturnValue
 Return type for table value. More...
 

Namespaces

namespace  oqmc
 
namespace  oqmc::bntables
 
namespace  oqmc::bntables::pmj
 
namespace  oqmc::bntables::sobol
 
namespace  oqmc::bntables::lattice
 

Functions

template<int XBits, int YBits, int ZBits>
constexpr TableReturnValue oqmc::bntables::tableValue (std::uint16_t pixel, std::uint16_t shift, const std::uint32_t keyTable[], const std::uint32_t rankTable[])
 Lookup value pair from table.
 

Variables

constexpr auto oqmc::bntables::xBits = 8
 256 pixels in x.
 
constexpr auto oqmc::bntables::yBits = 8
 256 pixels in y.
 
constexpr auto oqmc::bntables::size = 1 << (xBits + yBits)
 2^16 table size.
 
constexpr std::uint32_t oqmc::bntables::pmj::keyTable []
 Optimised blue noise key table for pmj.
 
constexpr std::uint32_t oqmc::bntables::pmj::rankTable []
 Optimised blue noise rank table for pmj.
 
constexpr std::uint32_t oqmc::bntables::sobol::keyTable []
 Optimised blue noise key table for sobol.
 
constexpr std::uint32_t oqmc::bntables::sobol::rankTable []
 Optimised blue noise rank table for sobol.
 
constexpr std::uint32_t oqmc::bntables::lattice::keyTable []
 Optimised blue noise key table for lattice.
 
constexpr std::uint32_t oqmc::bntables::lattice::rankTable []
 Optimised blue noise rank table for lattice.
 

Detailed Description

Pre-computed and optimised blue noise tables used to decorrelate between pixels, and extend the base sampler implementations with blue noise properties. A generalised method extending 'Lessons Learned and Improvements when Building Screen-Space Samplers with Blue-Noise Error Distribution.' by Laurent Belcour and Eric Heitz was used to optimise the tables. Lookups for the table can apply constant random shifts for different domains, allowing a single table to be re-used for N domains.