42 BL::BlendData &b_data,
46 bool use_developer_ui,
54 procedural_map(scene),
56 particle_system_map(scene),
61 use_developer_ui(use_developer_ui),
68 dicing_rate = preview ?
RNA_float_get(&cscene,
"preview_dicing_rate") :
70 max_subdivisions =
RNA_int_get(&cscene,
"max_subdivisions");
81 this->b_data = b_data;
82 this->b_scene = b_scene;
92 b_bake_target = b_object;
98 BL::SpaceView3D &b_v3d,
99 BL::RegionView3D &b_rv3d)
103 BL::Object b_dicing_camera_object = get_dicing_camera_object(b_v3d, b_rv3d);
104 bool dicing_camera_updated =
false;
107 for (BL::DepsgraphUpdate &b_update : b_depsgraph.updates) {
114 BL::ID b_id(b_update.id());
117 if (b_id.is_a(&RNA_Material)) {
118 const BL::Material b_mat(b_id);
119 shader_map.set_recalc(b_mat);
122 else if (b_id.is_a(&RNA_Light)) {
123 const BL::Light b_light(b_id);
124 shader_map.set_recalc(b_light);
125 geometry_map.set_recalc(b_light);
128 else if (b_id.is_a(&RNA_Object)) {
129 BL::Object b_ob(b_id);
130 const bool can_have_geometry = object_can_have_geometry(b_ob);
131 const bool is_light = !can_have_geometry && object_is_light(b_ob);
133 if (b_ob.is_instancer() && b_update.is_updated_shading()) {
135 object_map.set_recalc(b_ob);
138 if (can_have_geometry ||
is_light) {
139 const bool updated_geometry = b_update.is_updated_geometry();
140 const bool updated_transform = b_update.is_updated_transform();
143 if (can_have_geometry) {
144 if (updated_transform || b_update.is_updated_shading()) {
145 object_map.set_recalc(b_ob);
149 b_ob, preview, use_adaptive_subdivision) !=
154 if (updated_geometry || (updated_transform && use_adaptive_subdiv)) {
155 BL::ID
const key = BKE_object_is_modified(b_ob) ?
158 geometry_map.set_recalc(key);
161 const map<void *, set<BL::ID>>::const_iterator instance_geometries =
162 instance_geometries_by_object.find(b_ob.ptr.data);
163 if (instance_geometries != instance_geometries_by_object.end()) {
164 for (BL::ID
const &geometry : instance_geometries->second) {
165 geometry_map.set_recalc(geometry);
170 if (updated_geometry) {
171 BL::Object::particle_systems_iterator b_psys;
172 for (b_ob.particle_systems.begin(b_psys); b_psys != b_ob.particle_systems.end();
175 particle_system_map.set_recalc(b_ob);
181 if (b_update.is_updated_transform() || b_update.is_updated_shading()) {
182 object_map.set_recalc(b_ob);
183 geometry_map.set_recalc(b_ob);
186 if (updated_geometry) {
187 geometry_map.set_recalc(b_ob);
191 else if (object_is_camera(b_ob)) {
192 shader_map.set_recalc(b_ob);
195 if (b_dicing_camera_object == b_ob) {
196 dicing_camera_updated =
true;
200 else if (b_id.is_a(&RNA_Mesh)) {
201 const BL::Mesh b_mesh(b_id);
202 geometry_map.set_recalc(b_mesh);
205 else if (b_id.is_a(&RNA_World)) {
206 const BL::World b_world(b_id);
207 if (world_map == b_world.ptr.data) {
210 shader_map.set_recalc(b_world);
213 else if (b_id.is_a(&RNA_Scene)) {
214 shader_map.set_recalc(b_id);
217 else if (b_id.is_a(&RNA_Volume)) {
218 const BL::Volume b_volume(b_id);
219 geometry_map.set_recalc(b_volume);
222 else if (b_id.is_a(&RNA_Camera)) {
223 if (b_dicing_camera_object && b_dicing_camera_object.data() == b_id) {
224 dicing_camera_updated =
true;
229 if (use_adaptive_subdivision) {
232 bool dicing_prop_changed =
false;
234 const float updated_dicing_rate = preview ?
RNA_float_get(&cscene,
"preview_dicing_rate") :
237 if (dicing_rate != updated_dicing_rate) {
238 dicing_rate = updated_dicing_rate;
239 dicing_prop_changed =
true;
242 const int updated_max_subdivisions =
RNA_int_get(&cscene,
"max_subdivisions");
244 if (max_subdivisions != updated_max_subdivisions) {
245 max_subdivisions = updated_max_subdivisions;
246 dicing_prop_changed =
true;
254 for (
const pair<const GeometryKey, Geometry *> &iter : geometry_map.key_to_scene_data()) {
257 Mesh *mesh =
static_cast<Mesh *
>(geom);
260 geometry_map.set_recalc(BL::ID(id_ptr));
270 if (viewport_parameters.shader_modified(new_viewport_parameters)) {
275 has_updates_ |= viewport_parameters.modified(new_viewport_parameters);
280 BL::Depsgraph &b_depsgraph,
281 BL::SpaceView3D &b_v3d,
282 BL::Object &b_override,
285 void **python_thread_state,
289 ImageManager *image_manager = scene->image_manager.get();
290 const int frame = b_scene.frame_current();
293 if (!has_updates_ && !auto_refresh_update) {
299 BL::ViewLayer b_view_layer = b_depsgraph.view_layer_eval();
303 const bool background = !b_v3d;
307 sync_film(b_view_layer, b_v3d);
308 sync_shaders(b_depsgraph, b_v3d, auto_refresh_update);
311 geometry_synced.clear();
316 sync_objects(b_depsgraph, b_v3d);
318 sync_motion(b_render, b_depsgraph, b_v3d, b_override, width, height, python_thread_state);
320 geometry_synced.clear();
324 shader_map.post_sync(
false);
326 VLOG_INFO <<
"Total time spent synchronizing data: " <<
timer.get_time();
328 has_updates_ =
false;
340 use_adaptive_subdivision = (
get_enum(cscene,
"feature_set") != 0) && !b_bake_target;
341 use_experimental_procedural = (
get_enum(cscene,
"feature_set") != 0);
345 integrator->set_min_bounce(
get_int(cscene,
"min_light_bounces"));
346 integrator->set_max_bounce(
get_int(cscene,
"max_bounces"));
348 integrator->set_max_diffuse_bounce(
get_int(cscene,
"diffuse_bounces"));
349 integrator->set_max_glossy_bounce(
get_int(cscene,
"glossy_bounces"));
350 integrator->set_max_transmission_bounce(
get_int(cscene,
"transmission_bounces"));
351 integrator->set_max_volume_bounce(
get_int(cscene,
"volume_bounces"));
353 integrator->set_transparent_min_bounce(
get_int(cscene,
"min_transparent_bounces"));
354 integrator->set_transparent_max_bounce(
get_int(cscene,
"transparent_max_bounces"));
356 integrator->set_volume_max_steps(
get_int(cscene,
"volume_max_steps"));
357 const float volume_step_rate = (preview) ?
get_float(cscene,
"volume_preview_step_rate") :
359 integrator->set_volume_step_rate(volume_step_rate);
361 integrator->set_caustics_reflective(
get_boolean(cscene,
"caustics_reflective"));
362 integrator->set_caustics_refractive(
get_boolean(cscene,
"caustics_refractive"));
363 integrator->set_filter_glossy(
get_float(cscene,
"blur_glossy"));
368 if (b_scene.frame_subframe() != 0.0f) {
372 seed +=
hash_uint2((
int)(b_scene.frame_subframe() * (
float)INT_MAX),
377 integrator->set_seed(
seed);
379 integrator->set_sample_clamp_direct(
get_float(cscene,
"sample_clamp_direct"));
380 integrator->set_sample_clamp_indirect(
get_float(cscene,
"sample_clamp_indirect"));
382 integrator->set_motion_blur(view_layer.use_motion_blur);
385 const bool use_light_tree =
get_boolean(cscene,
"use_light_tree");
386 integrator->set_use_light_tree(use_light_tree);
387 integrator->set_light_sampling_threshold(
get_float(cscene,
"light_sampling_threshold"));
389 if (integrator->use_light_tree_is_modified()) {
396 switch (sampling_pattern) {
414 if (!use_developer_ui) {
420 const bool is_vertex_baking = b_bake_target && b_scene.render().bake().target() !=
421 BL::BakeSettings::target_IMAGE_TEXTURES;
422 scene->bake_manager->set_use_seed(is_vertex_baking);
423 if (is_vertex_baking) {
429 integrator->set_sampling_pattern(sampling_pattern);
432 bool use_adaptive_sampling =
false;
434 samples =
get_int(cscene,
"preview_samples");
435 use_adaptive_sampling =
RNA_boolean_get(&cscene,
"use_preview_adaptive_sampling");
436 integrator->set_use_adaptive_sampling(use_adaptive_sampling);
437 integrator->set_adaptive_threshold(
get_float(cscene,
"preview_adaptive_threshold"));
438 integrator->set_adaptive_min_samples(
get_int(cscene,
"preview_adaptive_min_samples"));
441 samples =
get_int(cscene,
"samples");
442 use_adaptive_sampling =
RNA_boolean_get(&cscene,
"use_adaptive_sampling");
443 integrator->set_use_adaptive_sampling(use_adaptive_sampling);
444 integrator->set_adaptive_threshold(
get_float(cscene,
"adaptive_threshold"));
445 integrator->set_adaptive_min_samples(
get_int(cscene,
"adaptive_min_samples"));
448 float scrambling_distance =
get_float(cscene,
"scrambling_distance");
449 const bool auto_scrambling_distance =
get_boolean(cscene,
"auto_scrambling_distance");
450 if (auto_scrambling_distance) {
459 if (use_adaptive_sampling) {
465 scrambling_distance *= 4.0f /
sqrtf(samples);
469 const bool preview_scrambling_distance =
get_boolean(cscene,
"preview_scrambling_distance");
470 if ((preview && !preview_scrambling_distance) ||
473 scrambling_distance = 1.0f;
476 if (scrambling_distance != 1.0f) {
477 VLOG_INFO <<
"Using scrambling distance: " << scrambling_distance;
479 integrator->set_scrambling_distance(scrambling_distance);
483 integrator->set_ao_bounces(
get_int(cscene,
"ao_bounces"));
486 integrator->set_ao_bounces(
get_int(cscene,
"ao_bounces_render"));
490 integrator->set_ao_bounces(0);
493#ifdef WITH_CYCLES_DEBUG
496 integrator->set_direct_light_sampling_type(direct_light_sampling_type);
499 integrator->set_use_guiding(
get_boolean(cscene,
"use_guiding"));
500 integrator->set_use_surface_guiding(
get_boolean(cscene,
"use_surface_guiding"));
501 integrator->set_use_volume_guiding(
get_boolean(cscene,
"use_volume_guiding"));
502 integrator->set_guiding_training_samples(
get_int(cscene,
"guiding_training_samples"));
504 if (use_developer_ui) {
505 integrator->set_deterministic_guiding(
get_boolean(cscene,
"use_deterministic_guiding"));
506 integrator->set_surface_guiding_probability(
get_float(cscene,
"surface_guiding_probability"));
507 integrator->set_volume_guiding_probability(
get_float(cscene,
"volume_guiding_probability"));
508 integrator->set_use_guiding_direct_light(
get_boolean(cscene,
"use_guiding_direct_light"));
509 integrator->set_use_guiding_mis_weights(
get_boolean(cscene,
"use_guiding_mis_weights"));
512 integrator->set_guiding_distribution_type(guiding_distribution_type);
515 "guiding_directional_sampling_type",
518 integrator->set_guiding_directional_sampling_type(guiding_directional_sampling_type);
519 integrator->set_guiding_roughness_threshold(
get_float(cscene,
"guiding_roughness_threshold"));
523 b_scene, b_view_layer, background, denoise_device_info);
527 if (is_vertex_baking) {
528 denoise_params.
use =
false;
531 integrator->set_use_denoise(denoise_params.
use);
536 if (denoise_params.
use) {
537 integrator->set_denoiser_type(denoise_params.
type);
538 integrator->set_denoise_use_gpu(denoise_params.
use_gpu);
539 integrator->set_denoise_start_sample(denoise_params.
start_sample);
540 integrator->set_use_denoise_pass_albedo(denoise_params.
use_pass_albedo);
541 integrator->set_use_denoise_pass_normal(denoise_params.
use_pass_normal);
542 integrator->set_denoiser_prefilter(denoise_params.
prefilter);
543 integrator->set_denoiser_quality(denoise_params.
quality);
553void BlenderSync::sync_film(BL::ViewLayer &b_view_layer, BL::SpaceView3D &b_v3d)
562 film->set_display_pass(new_viewport_parameters.display_pass);
563 film->set_show_active_pixels(new_viewport_parameters.show_active_pixels);
566 film->set_exposure(
get_float(cscene,
"film_exposure"));
567 film->set_filter_type(
569 const float filter_width = (film->get_filter_type() ==
FILTER_BOX) ?
572 film->set_filter_width(filter_width);
574 if (b_scene.world()) {
575 BL::WorldMistSettings b_mist = b_scene.world().mist_settings();
577 film->set_mist_start(b_mist.start());
578 film->set_mist_depth(b_mist.depth());
580 switch (b_mist.falloff()) {
581 case BL::WorldMistSettings::falloff_QUADRATIC:
582 film->set_mist_falloff(2.0f);
584 case BL::WorldMistSettings::falloff_LINEAR:
585 film->set_mist_falloff(1.0f);
587 case BL::WorldMistSettings::falloff_INVERSE_QUADRATIC:
588 film->set_mist_falloff(0.5f);
596 film->set_use_approximate_shadow_catcher(
true);
599 film->set_use_approximate_shadow_catcher(!
get_boolean(crl,
"use_pass_shadow_catcher"));
607 view_layer.
name = b_view_layer.name();
610 view_layer.use_background_shader = b_view_layer.use_sky();
612 view_layer.use_surfaces = b_view_layer.use_solid() || b_bake_target;
613 view_layer.use_hair = b_view_layer.use_strand();
614 view_layer.use_volumes = b_view_layer.use_volumes();
615 view_layer.use_motion_blur = b_view_layer.use_motion_blur() &&
616 b_scene.render().use_motion_blur();
619 view_layer.material_override = b_view_layer.material_override();
621 view_layer.world_override = b_view_layer.world_override();
625 const int use_layer_samples =
get_enum(cscene,
"use_layer_samples");
627 view_layer.bound_samples = (use_layer_samples == 1);
628 view_layer.samples = 0;
630 if (use_layer_samples != 2) {
631 const int samples = b_view_layer.samples();
632 view_layer.samples = samples;
637void BlenderSync::sync_images()
641 const bool is_interface_locked = b_engine.render() && b_engine.render().use_lock_interface();
649 for (BL::Image &b_image : b_data.images) {
651 if (is_builtin ==
false) {
652 b_image.buffers_free();
662 const string name = b_pass.name();
663#define MAP_PASS(passname, passtype, noisy) \
664 if (name == passname) { \
666 mode = (noisy) ? PassMode::NOISY : PassMode::DENOISED; \
739 pass->set_type(type);
740 pass->set_name(ustring(name));
741 pass->set_mode(mode);
750 scene->delete_nodes(set<Pass *>(scene_passes.begin(), scene_passes.end()));
757 const int crypto_depth =
divide_up(
min(16, b_view_layer.pass_cryptomatte_depth()), 2);
758 scene->film->set_cryptomatte_depth(crypto_depth);
760 if (b_view_layer.use_pass_cryptomatte_object()) {
763 if (b_view_layer.use_pass_cryptomatte_material()) {
766 if (b_view_layer.use_pass_cryptomatte_asset()) {
769 scene->film->set_cryptomatte_passes(cryptomatte_passes);
771 unordered_set<string> expected_passes;
774 BL::ViewLayer::aovs_iterator b_aov_iter;
775 for (b_view_layer.aovs.begin(b_aov_iter); b_aov_iter != b_view_layer.aovs.end(); ++b_aov_iter) {
776 BL::AOV b_aov(*b_aov_iter);
777 if (!b_aov.is_valid()) {
781 const string name = b_aov.name();
784 pass_add(scene, type, name.c_str());
785 expected_passes.insert(name);
789 BL::ViewLayer::lightgroups_iterator b_lightgroup_iter;
790 for (b_view_layer.lightgroups.begin(b_lightgroup_iter);
791 b_lightgroup_iter != b_view_layer.lightgroups.end();
794 BL::Lightgroup b_lightgroup(*b_lightgroup_iter);
796 const string name =
string_printf(
"Combined_%s", b_lightgroup.name().c_str());
799 pass->set_lightgroup(ustring(b_lightgroup.name()));
800 expected_passes.insert(name);
804 for (BL::RenderPass &b_pass : b_rlay.passes) {
809 if (!expected_passes.count(b_pass.name())) {
810 LOG(ERROR) <<
"Unknown pass " << b_pass.name();
816 (b_view_layer.use_motion_blur() && b_scene.render().use_motion_blur()))
821 pass_add(scene, pass_type, b_pass.name().c_str(), pass_mode);
824 scene->film->set_pass_alpha_threshold(b_view_layer.pass_alpha_threshold());
834 const bool is_interface_locked = b_engine.render() && b_engine.render().use_lock_interface();
835 const bool is_persistent_data = b_engine.render() && b_engine.render().use_persistent_data();
836 const bool can_free_caches =
845 if (!can_free_caches) {
851 for (BL::Object &b_ob : b_depsgraph.objects) {
854 if (b_ob.type() == BL::Object::type_GREASEPENCIL) {
857 b_ob.cache_release();
864 const bool background,
865 const bool use_developer_ui)
871 if (shadingsystem == 0) {
874 else if (shadingsystem == 1) {
878 if (background || (use_developer_ui &&
get_enum(cscene,
"debug_bvh_type"))) {
897 texture_limit =
RNA_enum_get(&cscene,
"texture_limit_render");
902 if (texture_limit > 0 && b_scene.render().use_simplify()) {
903 params.texture_limit = 1 << (texture_limit + 6);
911 params.background = background;
925 BL::Preferences &b_preferences,
932 if (background && !b_engine.is_preview()) {
937 params.temp_dir = b_engine.temporary_directory();
945 params.background = background;
950 b_preferences, b_scene,
params.background, b_engine.is_preview(),
params.denoise_device);
953 const int samples =
get_int(cscene,
"samples");
954 const int preview_samples =
get_int(cscene,
"preview_samples");
955 const bool use_sample_subset =
get_boolean(cscene,
"use_sample_subset");
956 const int sample_subset_offset =
get_int(cscene,
"sample_offset");
957 const int sample_subset_length =
get_int(cscene,
"sample_subset_length");
962 params.use_sample_subset = use_sample_subset;
963 params.sample_subset_offset = sample_subset_offset;
964 params.sample_subset_length = sample_subset_length;
967 params.samples = preview_samples;
968 if (
params.samples == 0) {
971 params.use_sample_subset =
false;
972 params.sample_subset_offset = 0;
973 params.sample_subset_length = 0;
977 params.pixel_size = b_engine.get_preview_pixel_size(b_scene);
986 if (shadingsystem == 0) {
989 else if (shadingsystem == 1) {
1006 params.use_profiling =
params.device.has_profiling && !b_engine.is_preview() && background &&
1014 params.use_auto_tile =
false;
1021 BL::ViewLayer &b_view_layer,
1025 enum DenoiserInput {
1026 DENOISER_INPUT_RGB = 1,
1027 DENOISER_INPUT_RGB_ALBEDO = 2,
1028 DENOISER_INPUT_RGB_ALBEDO_NORMAL = 3,
1036 int input_passes = -1;
1048 input_passes = (DenoiserInput)
get_enum(
1049 cscene,
"denoising_input_passes", DENOISER_INPUT_NUM, DENOISER_INPUT_RGB_ALBEDO_NORMAL);
1054 denoising.
use =
false;
1070 input_passes = (DenoiserInput)
get_enum(
1071 cscene,
"preview_denoising_input_passes", DENOISER_INPUT_NUM, DENOISER_INPUT_RGB_ALBEDO);
1077 denoising.
use =
false;
1082 switch (input_passes) {
1083 case DENOISER_INPUT_RGB:
1088 case DENOISER_INPUT_RGB_ALBEDO:
1093 case DENOISER_INPUT_RGB_ALBEDO_NORMAL:
1099 LOG(ERROR) <<
"Unhandled input passes enum " << input_passes;
DeviceInfo blender_device_info(BL::Preferences &b_preferences, BL::Scene &b_scene, bool background, bool preview, DeviceInfo &preferences_device)
int blender_device_threads(BL::Scene &b_scene)
static unsigned long seed
static bool print_render_stats
BlenderSync(BL::RenderEngine &b_engine, BL::BlendData &b_data, BL::Scene &b_scene, Scene *scene, bool preview, bool use_developer_ui, Progress &progress)
static DenoiseParams get_denoise_params(BL::Scene &b_scene, BL::ViewLayer &b_view_layer, bool background, const DeviceInfo &denoise_device)
void sync_data(BL::RenderSettings &b_render, BL::Depsgraph &b_depsgraph, BL::SpaceView3D &b_v3d, BL::Object &b_override, const int width, const int height, void **python_thread_state, const DeviceInfo &denoise_device_info)
static bool get_session_pause(BL::Scene &b_scene, bool background)
static SessionParams get_session_params(BL::RenderEngine &b_engine, BL::Preferences &b_preferences, BL::Scene &b_scene, bool background)
void sync_recalc(BL::Depsgraph &b_depsgraph, BL::SpaceView3D &b_v3d, BL::RegionView3D &b_rv3d)
void sync_view_layer(BL::ViewLayer &b_view_layer)
void sync_integrator(BL::ViewLayer &b_view_layer, bool background, const DeviceInfo &denoise_device_info)
void free_data_after_sync(BL::Depsgraph &b_depsgraph)
static SceneParams get_scene_params(BL::Scene &b_scene, const bool background, const bool use_developer_ui)
void reset(BL::BlendData &b_data, BL::Scene &b_scene)
void set_bake_target(BL::Object &b_object)
void sync_render_passes(BL::RenderLayer &b_rlay, BL::ViewLayer &b_view_layer)
DenoiserPrefilter prefilter
static DenoiserType automatic_viewport_denoiser_type(const DeviceInfo &denoise_device_info)
bool set_animation_frame_update(const int frame)
void tag_update(Scene *scene, const uint32_t flag)
AdaptiveSampling get_adaptive_sampling() const
static bool image_is_builtin(BL::Image &ima, BL::RenderEngine &engine)
static float get_float(PointerRNA &ptr, const char *name)
static bool get_boolean(PointerRNA &ptr, const char *name)
static int get_int(PointerRNA &ptr, const char *name)
static int get_enum(PointerRNA &ptr, const char *name, int num_values=-1, int default_value=-1)
static Mesh::SubdivisionType object_subdivision_type(BL::Object &b_ob, const bool preview, const bool use_adaptive_subdivision)
static CCL_NAMESPACE_BEGIN BL::ID object_get_data(const BL::Object &b_ob, const bool use_adaptive_subdivision)
static bool region_view3d_navigating_or_transforming(const BL::RegionView3D &b_rv3d)
DebugFlags & DebugFlags()
@ DENOISER_QUALITY_BALANCED
@ DENOISER_PREFILTER_FAST
@ DENOISER_PREFILTER_NONE
#define CCL_NAMESPACE_END
ccl_device_inline uint hash_uint2(const uint kx, const uint ky)
@ DIRECT_LIGHT_SAMPLING_MIS
@ DIRECT_LIGHT_SAMPLING_NUM
GuidingDirectionalSamplingType
@ GUIDING_DIRECTIONAL_SAMPLING_NUM_TYPES
@ GUIDING_DIRECTIONAL_SAMPLING_TYPE_RIS
@ SAMPLING_PATTERN_AUTOMATIC
@ SAMPLING_PATTERN_BLUE_NOISE_FIRST
@ SAMPLING_PATTERN_TABULATED_SOBOL
@ SAMPLING_PATTERN_BLUE_NOISE_PURE
@ PASS_TRANSMISSION_DIRECT
@ PASS_TRANSMISSION_COLOR
@ PASS_TRANSMISSION_INDIRECT
@ PASS_GUIDING_PROBABILITY
@ PASS_ADAPTIVE_AUX_BUFFER
@ PASS_GUIDING_AVG_ROUGHNESS
@ GUIDING_TYPE_PARALLAX_AWARE_VMM
PointerRNA RNA_pointer_get(PointerRNA *ptr, const char *name)
const PointerRNA PointerRNA_NULL
int RNA_int_get(PointerRNA *ptr, const char *name)
float RNA_float_get(PointerRNA *ptr, const char *name)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
int RNA_enum_get(PointerRNA *ptr, const char *name)
PointerRNA RNA_id_pointer_create(ID *id)
bool string_startswith(const string_view s, const string_view start)
CCL_NAMESPACE_BEGIN string string_printf(const char *format,...)
T * create_node(Args &&...)=delete
static bool get_known_pass_type(BL::RenderPass &b_pass, PassType &type, PassMode &mode)
#define MAP_PASS(passname, passtype, noisy)
static Pass * pass_add(Scene *scene, PassType type, const char *name, PassMode mode=PassMode::DENOISED)
static CCL_NAMESPACE_BEGIN const char * cryptomatte_prefix
ccl_device_inline bool is_light(const ccl_global KernelLightTreeEmitter *kemitter)
ccl_device_inline size_t divide_up(const size_t x, const size_t y)