|
Blender V4.5
|
General operations for probes. More...
#include "BLI_sys_types.h"Go to the source code of this file.
Functions | |
| void | BKE_lightprobe_type_set (struct LightProbe *probe, short lightprobe_type) |
| struct LightProbe * | BKE_lightprobe_add (struct Main *bmain, const char *name) |
| void | BKE_lightprobe_cache_blend_write (struct BlendWriter *writer, struct LightProbeObjectCache *cache) |
| void | BKE_lightprobe_cache_blend_read (struct BlendDataReader *reader, struct LightProbeObjectCache *cache) |
| struct LightProbeGridCacheFrame * | BKE_lightprobe_grid_cache_frame_create (void) |
| LightProbeGridCacheFrame * | BKE_lightprobe_grid_cache_frame_copy (LightProbeGridCacheFrame *src) |
| void | BKE_lightprobe_grid_cache_frame_free (struct LightProbeGridCacheFrame *cache) |
| void | BKE_lightprobe_cache_create (struct Object *object) |
| LightProbeObjectCache * | BKE_lightprobe_cache_copy (LightProbeObjectCache *src_cache) |
| void | BKE_lightprobe_cache_free (struct Object *object) |
| int64_t | BKE_lightprobe_grid_cache_frame_sample_count (const struct LightProbeGridCacheFrame *cache) |
General operations for probes.
Definition in file BKE_lightprobe.h.
| struct LightProbe * BKE_lightprobe_add | ( | struct Main * | bmain, |
| const char * | name ) |
Definition at line 106 of file lightprobe.cc.
References BKE_id_new(), and BKE_lightprobe_add().
Referenced by BKE_lightprobe_add(), and BKE_object_obdata_add_from_type().
| void BKE_lightprobe_cache_blend_read | ( | struct BlendDataReader * | reader, |
| struct LightProbeObjectCache * | cache ) |
Definition at line 181 of file lightprobe.cc.
References BKE_lightprobe_cache_blend_read(), BLO_read_struct, LightProbeObjectCache::grid_static_cache, and lightprobe_grid_cache_frame_blend_read().
Referenced by BKE_lightprobe_cache_blend_read(), and object_blend_read_data().
| void BKE_lightprobe_cache_blend_write | ( | struct BlendWriter * | writer, |
| struct LightProbeObjectCache * | cache ) |
Definition at line 173 of file lightprobe.cc.
References BKE_lightprobe_cache_blend_write(), BLO_write_struct, LightProbeObjectCache::grid_static_cache, and lightprobe_grid_cache_frame_blend_write().
Referenced by BKE_lightprobe_cache_blend_write(), and object_blend_write().
| LightProbeObjectCache * BKE_lightprobe_cache_copy | ( | LightProbeObjectCache * | src_cache | ) |
Create a copy of a whole cache. This does not include the in-progress baking data.
Definition at line 251 of file lightprobe.cc.
References BKE_lightprobe_cache_copy(), BKE_lightprobe_grid_cache_frame_copy(), BLI_assert, LightProbeObjectCache::grid_static_cache, and MEM_dupallocN().
Referenced by BKE_lightprobe_cache_copy(), and object_copy_data().
| void BKE_lightprobe_cache_create | ( | struct Object * | object | ) |
Create the grid cache list depending on the lightprobe baking settings. The list is left empty to be filled by the baking process.
Definition at line 244 of file lightprobe.cc.
References BKE_lightprobe_cache_create(), BLI_assert, Object::lightprobe_cache, and MEM_callocN().
Referenced by BKE_lightprobe_cache_create(), and lightprobe_cache_irradiance_volume_subset_get().
| void BKE_lightprobe_cache_free | ( | struct Object * | object | ) |
Free all irradiance grids allocated for the given object.
Definition at line 265 of file lightprobe.cc.
References BKE_lightprobe_cache_free(), BKE_lightprobe_grid_cache_frame_free(), LightProbeObjectCache::grid_static_cache, Object::lightprobe_cache, MEM_SAFE_FREE, and LightProbeObjectCache::shared.
Referenced by BKE_lightprobe_cache_free(), lightprobe_cache_free_exec(), lightprobe_cache_irradiance_volume_subset_get(), and object_free_data().
| LightProbeGridCacheFrame * BKE_lightprobe_grid_cache_frame_copy | ( | LightProbeGridCacheFrame * | src | ) |
Create a copy of a cache frame. This does not include the in-progress baking data.
Definition at line 212 of file lightprobe.cc.
References LightProbeGridCacheFrame::baking, BKE_lightprobe_grid_cache_frame_copy(), LightProbeGridCacheFrame::block_infos, LightProbeGridCacheFrame::connectivity, LightProbeGridCacheFrame::irradiance, LightProbeBakingData::L0, LightProbeBakingData::L1_a, LightProbeBakingData::L1_b, LightProbeBakingData::L1_c, MEM_dupallocN(), spherical_harmonic_copy(), LightProbeGridCacheFrame::surfels, LightProbeBakingData::validity, LightProbeConnectivityData::validity, LightProbeBakingData::virtual_offset, and LightProbeGridCacheFrame::visibility.
Referenced by BKE_lightprobe_cache_copy(), and BKE_lightprobe_grid_cache_frame_copy().
| struct LightProbeGridCacheFrame * BKE_lightprobe_grid_cache_frame_create | ( | void | ) |
Create a single empty irradiance grid cache.
Definition at line 205 of file lightprobe.cc.
References BKE_lightprobe_grid_cache_frame_create(), and MEM_callocN().
Referenced by BKE_lightprobe_grid_cache_frame_create(), blender::eevee::IrradianceBake::read_result_packed(), and blender::eevee::IrradianceBake::read_result_unpacked().
| void BKE_lightprobe_grid_cache_frame_free | ( | struct LightProbeGridCacheFrame * | cache | ) |
Free a single grid cache.
Definition at line 230 of file lightprobe.cc.
References LightProbeGridCacheFrame::baking, BKE_lightprobe_grid_cache_frame_free(), LightProbeGridCacheFrame::block_infos, LightProbeGridCacheFrame::connectivity, LightProbeGridCacheFrame::irradiance, MEM_SAFE_FREE, spherical_harmonic_free(), LightProbeGridCacheFrame::surfels, LightProbeBakingData::validity, LightProbeConnectivityData::validity, LightProbeBakingData::virtual_offset, and LightProbeGridCacheFrame::visibility.
Referenced by BKE_lightprobe_cache_free(), BKE_lightprobe_grid_cache_frame_free(), blender::eevee::LightBake::run(), and blender::eevee::LightBake::update().
| int64_t BKE_lightprobe_grid_cache_frame_sample_count | ( | const struct LightProbeGridCacheFrame * | cache | ) |
Return the number of sample stored inside an irradiance cache. This depends on the light cache type.
References BKE_lightprobe_grid_cache_frame_sample_count().
Referenced by BKE_lightprobe_grid_cache_frame_sample_count(), BKE_lightprobe_grid_cache_frame_sample_count(), lightprobe_grid_cache_frame_blend_read(), and lightprobe_grid_cache_frame_blend_write().
| void BKE_lightprobe_type_set | ( | struct LightProbe * | probe, |
| short | lightprobe_type ) |
Definition at line 82 of file lightprobe.cc.
References LightProbe::attenuation_type, BKE_lightprobe_type_set(), BLI_assert_msg, LightProbe::clipsta, LightProbe::distinf, LightProbe::falloff, LIGHTPROBE_SHAPE_ELIPSOID, LIGHTPROBE_TYPE_PLANE, LIGHTPROBE_TYPE_SPHERE, LIGHTPROBE_TYPE_VOLUME, and LightProbe::type.
Referenced by BKE_lightprobe_type_set(), and blender::ed::object::lightprobe_add_exec().