Changeset View
Changeset View
Standalone View
Standalone View
source/blender/blenkernel/intern/scene.c
| Show First 20 Lines • Show All 2,035 Lines • ▼ Show 20 Lines | SceneRenderLayer *BKE_scene_add_render_layer(Scene *sce, const char *name) | ||||
| BLI_uniquename(&sce->r.layers, srl, DATA_("RenderLayer"), '.', offsetof(SceneRenderLayer, name), sizeof(srl->name)); | BLI_uniquename(&sce->r.layers, srl, DATA_("RenderLayer"), '.', offsetof(SceneRenderLayer, name), sizeof(srl->name)); | ||||
| BLI_addtail(&sce->r.layers, srl); | BLI_addtail(&sce->r.layers, srl); | ||||
| /* note, this is also in render, pipeline.c, to make layer when scenedata doesnt have it */ | /* note, this is also in render, pipeline.c, to make layer when scenedata doesnt have it */ | ||||
| srl->lay = (1 << 20) - 1; | srl->lay = (1 << 20) - 1; | ||||
| srl->layflag = 0x7FFF; /* solid ztra halo edge strand */ | srl->layflag = 0x7FFF; /* solid ztra halo edge strand */ | ||||
| srl->passflag = SCE_PASS_COMBINED | SCE_PASS_Z; | srl->passflag = SCE_PASS_COMBINED | SCE_PASS_Z; | ||||
| srl->pass_alpha_threshold = 0.5f; | srl->pass_alpha_threshold = 0.5f; | ||||
| srl->denoising_flag = SCE_DENOISING_PASS_DIFFDIR|SCE_DENOISING_PASS_GLOSSDIR|SCE_DENOISING_PASS_TRANSDIR|SCE_DENOISING_PASS_SUBDIR| | |||||
| SCE_DENOISING_PASS_DIFFIND|SCE_DENOISING_PASS_GLOSSIND|SCE_DENOISING_PASS_TRANSIND|SCE_DENOISING_PASS_SUBIND; | |||||
| srl->denoising_radius = 8; | |||||
| BKE_freestyle_config_init(&srl->freestyleConfig); | BKE_freestyle_config_init(&srl->freestyleConfig); | ||||
| return srl; | return srl; | ||||
| } | } | ||||
| bool BKE_scene_remove_render_layer(Main *bmain, Scene *scene, SceneRenderLayer *srl) | bool BKE_scene_remove_render_layer(Main *bmain, Scene *scene, SceneRenderLayer *srl) | ||||
| { | { | ||||
| const int act = BLI_findindex(&scene->r.layers, srl); | const int act = BLI_findindex(&scene->r.layers, srl); | ||||
| ▲ Show 20 Lines • Show All 552 Lines • Show Last 20 Lines | |||||