Blender
V3.3
|
#include <eevee_sampling.hh>
Public Member Functions | |
Sampling (Instance &inst) | |
~Sampling () | |
void | reset () |
bool | is_reset () const |
void | bind_resources (DRWShadingGroup *grp) |
float | rng_get (eSamplingDimension dimension) const |
float2 | rng_2d_get (eSamplingDimension starting_dimension) const |
float3 | rng_3d_get (eSamplingDimension starting_dimension) const |
bool | finished () const |
bool | finished_viewport () const |
bool | interactive_mode () const |
uint64_t | sample_count () const |
bool | do_render_sync () const |
uint64_t | dof_ring_count_get () const |
uint64_t | dof_sample_count_get () const |
Sampling | |
void | init (const Scene *scene) |
void | end_sync () |
void | step () |
Static Public Member Functions | |
Cumulative Distribution Function (CDF) | |
static void | cdf_from_curvemapping (const CurveMapping &curve, Vector< float > &cdf) |
static void | cdf_invert (Vector< float > &cdf, Vector< float > &inverted_cdf) |
Sampling patterns | |
void | dof_disk_sample_get (float *r_radius, float *r_theta) const |
static float3 | sample_ball (const float3 &rand) |
static float2 | sample_disk (const float2 &rand) |
static float2 | sample_spiral (const float2 &rand) |
Definition at line 25 of file eevee_sampling.hh.
|
inline |
Definition at line 65 of file eevee_sampling.hh.
|
inline |
Definition at line 66 of file eevee_sampling.hh.
|
inline |
Definition at line 85 of file eevee_sampling.hh.
References data_, and DRW_shgroup_storage_block_ref.
|
static |
Definition at line 230 of file eevee_sampling.cc.
References BKE_curvemapping_evaluateF(), BLI_assert, curve, float(), blender::Vector< T, InlineBufferCapacity, Allocator >::index_range(), blender::Vector< T, InlineBufferCapacity, Allocator >::last(), blender::Vector< T, InlineBufferCapacity, Allocator >::size(), and x.
|
static |
Definition at line 249 of file eevee_sampling.cc.
References float(), blender::Vector< T, InlineBufferCapacity, Allocator >::index_range(), inverted_cdf, blender::Vector< T, InlineBufferCapacity, Allocator >::size(), t, and x.
|
inline |
Definition at line 133 of file eevee_sampling.hh.
Special RNG for depth of field. Returns radius and theta angle offset to apply to the web sampling pattern.
Definition at line 187 of file eevee_sampling.cc.
|
inline |
Returns sample count inside the jittered depth of field web pattern.
Definition at line 171 of file eevee_sampling.hh.
|
inline |
Returns sample count inside the jittered depth of field web pattern.
Definition at line 179 of file eevee_sampling.hh.
void blender::eevee::Sampling::end_sync | ( | ) |
Definition at line 56 of file eevee_sampling.cc.
References Scene::eevee, SceneEEVEE::flag, blender::eevee::Instance::is_viewport(), min_ii(), SCE_EEVEE_TAA_REPROJECTION, and blender::eevee::Instance::scene.
Referenced by blender::eevee::Instance::end_sync().
|
inline |
Definition at line 109 of file eevee_sampling.hh.
Referenced by blender::eevee::Instance::render_frame().
|
inline |
Definition at line 115 of file eevee_sampling.hh.
Referenced by blender::eevee::Instance::draw_viewport().
Definition at line 22 of file eevee_sampling.cc.
References BLI_assert, divide_ceil_u(), Scene::eevee, SceneEEVEE::flag, blender::eevee::Instance::is_viewport(), SceneEEVEE::motion_blur_steps, SCE_EEVEE_DOF_JITTER, scene, SceneEEVEE::taa_render_samples, and SceneEEVEE::taa_samples.
Referenced by blender::eevee::Instance::init().
|
inline |
Definition at line 121 of file eevee_sampling.hh.
Referenced by blender::eevee::Film::end_sync().
|
inline |
Definition at line 80 of file eevee_sampling.hh.
Referenced by blender::eevee::Film::end_sync().
|
inline |
Definition at line 74 of file eevee_sampling.hh.
Referenced by blender::eevee::VelocityModule::end_sync(), blender::eevee::Film::init(), blender::eevee::VelocityModule::step_object_sync(), blender::eevee::World::sync(), blender::eevee::SyncModule::sync_object(), and blender::eevee::SyncModule::sync_world().
|
inline |
Definition at line 97 of file eevee_sampling.hh.
References data_.
Referenced by blender::eevee::Film::pixel_jitter_get().
|
inline |
Definition at line 103 of file eevee_sampling.hh.
References data_.
|
inline |
Definition at line 91 of file eevee_sampling.hh.
References data_.
Special ball distribution: Point are distributed in a way that when they are orthogonally projected into any plane, the resulting distribution is (close to) a uniform disc distribution. rand is 3 random float in the [0..1] range. Returns point in a ball of radius 1 and centered on the origin.
Definition at line 156 of file eevee_sampling.cc.
References cosf, fmaxf, M_PI, r, sample, sinf, sqrtf, and square_f().
|
inline |
Definition at line 126 of file eevee_sampling.hh.
Referenced by blender::eevee::Film::init().
Uniform disc distribution. rand is 2 random float in the [0..1] range. Returns point in a disk of radius 1 and centered on the origin.
Definition at line 171 of file eevee_sampling.cc.
References cosf, M_PI, sinf, and sqrtf.
Referenced by blender::eevee::Film::pixel_jitter_get().
void blender::eevee::Sampling::step | ( | ) |
Definition at line 86 of file eevee_sampling.cc.
References BLI_halton_2d(), BLI_halton_3d(), fractf(), offset, and r.