Blender V4.5
BKE_scene.hh File Reference
#include "BLI_sys_types.h"

Go to the source code of this file.

Classes

struct  SceneBaseIter

Macros

#define SETLOOPER(_sce_basis, _sce_iter, _base)
#define SETLOOPER_VIEW_LAYER(_sce_basis, _view_layer, _sce_iter, _base)
#define SETLOOPER_SET_ONLY(_sce_basis, _sce_iter, _base)

Enumerations

enum  eSceneCopyMethod { SCE_COPY_NEW = 0 , SCE_COPY_EMPTY = 1 , SCE_COPY_LINK_COLLECTION = 2 , SCE_COPY_FULL = 3 }

Functions

Base_setlooper_base_step (Scene **sce_iter, ViewLayer *view_layer, Base *base)
SceneBKE_scene_add (Main *bmain, const char *name)
void BKE_scene_remove_rigidbody_object (Main *bmain, Scene *scene, Object *ob, bool free_us)
bool BKE_scene_object_find (Scene *scene, Object *ob)
ObjectBKE_scene_object_find_by_name (const Scene *scene, const char *name)
int BKE_scene_base_iter_next (Depsgraph *depsgraph, SceneBaseIter *iter, Scene **scene, int val, Base **base, Object **ob)
void BKE_scene_base_flag_to_objects (const Scene *scene, ViewLayer *view_layer)
void BKE_scene_object_base_flag_sync_from_base (Base *base)
void BKE_scene_set_background (Main *bmain, Scene *sce)
SceneBKE_scene_set_name (Main *bmain, const char *name)
ToolSettingsBKE_toolsettings_copy (ToolSettings *toolsettings, int flag)
void BKE_toolsettings_free (ToolSettings *toolsettings)
SceneBKE_scene_duplicate (Main *bmain, Scene *sce, eSceneCopyMethod type)
void BKE_scene_groups_relink (Scene *sce)
bool BKE_scene_can_be_removed (const Main *bmain, const Scene *scene)
bool BKE_scene_has_view_layer (const Scene *scene, const ViewLayer *layer)
SceneBKE_scene_find_from_collection (const Main *bmain, const Collection *collection)
ObjectBKE_scene_camera_switch_find (Scene *scene)
bool BKE_scene_camera_switch_update (Scene *scene)
const char * BKE_scene_find_marker_name (const Scene *scene, int frame)
const char * BKE_scene_find_last_marker_name (const Scene *scene, int frame)
int BKE_scene_frame_snap_by_seconds (Scene *scene, double interval_in_seconds, int frame)
bool BKE_scene_validate_setscene (Main *bmain, Scene *sce)
float BKE_scene_ctime_get (const Scene *scene)
float BKE_scene_frame_to_ctime (const Scene *scene, int frame)
float BKE_scene_frame_get (const Scene *scene)
void BKE_scene_frame_set (Scene *scene, float frame)
TransformOrientationSlotBKE_scene_orientation_slot_get_from_flag (Scene *scene, int flag)
TransformOrientationSlotBKE_scene_orientation_slot_get (Scene *scene, int slot_index)
void BKE_scene_orientation_slot_set_index (TransformOrientationSlot *orient_slot, int orientation)
int BKE_scene_orientation_slot_get_index (const TransformOrientationSlot *orient_slot)
int BKE_scene_orientation_get_index (Scene *scene, int slot_index)
int BKE_scene_orientation_get_index_from_flag (Scene *scene, int flag)
void BKE_scene_update_sound (Depsgraph *depsgraph, Main *bmain)
void BKE_scene_update_tag_audio_volume (Depsgraph *, Scene *scene)
void BKE_scene_graph_update_tagged (Depsgraph *depsgraph, Main *bmain)
void BKE_scene_graph_evaluated_ensure (Depsgraph *depsgraph, Main *bmain)
void BKE_scene_graph_update_for_newframe (Depsgraph *depsgraph)
void BKE_scene_graph_update_for_newframe_ex (Depsgraph *depsgraph, bool clear_recalc)
void BKE_scene_view_layer_graph_evaluated_ensure (Main *bmain, Scene *scene, ViewLayer *view_layer)
SceneRenderViewBKE_scene_add_render_view (Scene *sce, const char *name)
bool BKE_scene_remove_render_view (Scene *scene, SceneRenderView *srv)
int get_render_subsurf_level (const RenderData *r, int lvl, bool for_render)
int get_render_child_particle_number (const RenderData *r, int child_num, bool for_render)
bool BKE_scene_use_shading_nodes_custom (Scene *scene)
bool BKE_scene_use_spherical_stereo (Scene *scene)
bool BKE_scene_uses_blender_eevee (const Scene *scene)
bool BKE_scene_uses_blender_workbench (const Scene *scene)
bool BKE_scene_uses_cycles (const Scene *scene)
bool BKE_scene_uses_shader_previews (const Scene *scene)
bool BKE_scene_uses_cycles_experimental_features (Scene *scene)
void BKE_scene_copy_data_eevee (Scene *sce_dst, const Scene *sce_src)
void BKE_scene_disable_color_management (Scene *scene)
bool BKE_scene_check_rigidbody_active (const Scene *scene)
int BKE_scene_num_threads (const Scene *scene)
int BKE_render_num_threads (const RenderData *r)
void BKE_render_resolution (const RenderData *r, const bool use_crop, int *r_width, int *r_height)
int BKE_render_preview_pixel_size (const RenderData *r)
bool BKE_scene_multiview_is_stereo3d (const RenderData *rd)
bool BKE_scene_multiview_is_render_view_active (const RenderData *rd, const SceneRenderView *srv)
bool BKE_scene_multiview_is_render_view_first (const RenderData *rd, const char *viewname)
bool BKE_scene_multiview_is_render_view_last (const RenderData *rd, const char *viewname)
int BKE_scene_multiview_num_views_get (const RenderData *rd)
SceneRenderViewBKE_scene_multiview_render_view_findindex (const RenderData *rd, int view_id)
const char * BKE_scene_multiview_render_view_name_get (const RenderData *rd, int view_id)
int BKE_scene_multiview_view_id_get (const RenderData *rd, const char *viewname)
void BKE_scene_multiview_filepath_get (const SceneRenderView *srv, const char *filepath, char *r_filepath)
void BKE_scene_multiview_view_filepath_get (const RenderData *rd, const char *filepath, const char *view, char *r_filepath)
const char * BKE_scene_multiview_view_suffix_get (const RenderData *rd, const char *viewname)
const char * BKE_scene_multiview_view_id_suffix_get (const RenderData *rd, int view_id)
void BKE_scene_multiview_view_prefix_get (Scene *scene, const char *filepath, char *r_prefix, const char **r_ext)
void BKE_scene_multiview_videos_dimensions_get (const RenderData *rd, size_t width, size_t height, size_t *r_width, size_t *r_height)
int BKE_scene_multiview_num_videos_get (const RenderData *rd)
void BKE_scene_ppm_get (const RenderData *rd, double r_ppm[2])
void BKE_scene_allocate_depsgraph_hash (Scene *scene)
void BKE_scene_ensure_depsgraph_hash (Scene *scene)
void BKE_scene_free_depsgraph_hash (Scene *scene)
void BKE_scene_free_view_layer_depsgraph (Scene *scene, ViewLayer *view_layer)
Depsgraph * BKE_scene_get_depsgraph (const Scene *scene, const ViewLayer *view_layer)
Depsgraph * BKE_scene_ensure_depsgraph (Main *bmain, Scene *scene, ViewLayer *view_layer)
GHashBKE_scene_undo_depsgraphs_extract (Main *bmain)
void BKE_scene_undo_depsgraphs_restore (Main *bmain, GHash *depsgraph_extract)
void BKE_scene_transform_orientation_remove (Scene *scene, TransformOrientation *orientation)
TransformOrientationBKE_scene_transform_orientation_find (const Scene *scene, int index)
int BKE_scene_transform_orientation_get_index (const Scene *scene, const TransformOrientation *orientation)

Macro Definition Documentation

◆ SETLOOPER

#define SETLOOPER ( _sce_basis,
_sce_iter,
_base )
Value:
_sce_iter = _sce_basis, \
&_sce_iter, BKE_view_layer_context_active_PLACEHOLDER(_sce_basis), NULL); \
_base; \
_base = _setlooper_base_step(&_sce_iter, NULL, _base)
ViewLayer * BKE_view_layer_context_active_PLACEHOLDER(const Scene *scene)
Base * _setlooper_base_step(Scene **sce_iter, ViewLayer *view_layer, Base *base)
Definition scene.cc:2776

Use as the contents of a 'for' loop: for (SETLOOPER(...)) { ... }.

Definition at line 37 of file BKE_scene.hh.

◆ SETLOOPER_SET_ONLY

#define SETLOOPER_SET_ONLY ( _sce_basis,
_sce_iter,
_base )
Value:
_sce_iter = _sce_basis, _base = _setlooper_base_step(&_sce_iter, NULL, NULL); \
_base; \
_base = _setlooper_base_step(&_sce_iter, NULL, _base)

Definition at line 49 of file BKE_scene.hh.

Referenced by clean_viewport_memory().

◆ SETLOOPER_VIEW_LAYER

#define SETLOOPER_VIEW_LAYER ( _sce_basis,
_view_layer,
_sce_iter,
_base )
Value:
_sce_iter = _sce_basis, _base = _setlooper_base_step(&_sce_iter, _view_layer, NULL); \
_base; \
_base = _setlooper_base_step(&_sce_iter, NULL, _base)

Definition at line 44 of file BKE_scene.hh.

Referenced by BKE_ptcache_bake().

Enumeration Type Documentation

◆ eSceneCopyMethod

Enumerator
SCE_COPY_NEW 
SCE_COPY_EMPTY 
SCE_COPY_LINK_COLLECTION 
SCE_COPY_FULL 

Definition at line 29 of file BKE_scene.hh.

Function Documentation

◆ _setlooper_base_step()

Base * _setlooper_base_step ( Scene ** sce_iter,
ViewLayer * view_layer,
Base * base )

Helper function for the SETLOOPER and SETLOOPER_VIEW_LAYER macros

It iterates over the bases of the active layer and then the bases of the active layer of the background (set) scenes recursively.

Definition at line 2776 of file scene.cc.

References BKE_view_layer_default_render(), BKE_view_layer_object_bases_get(), BKE_view_layer_synced_ensure(), ListBase::first, Base::next, and Scene::set.

◆ BKE_render_num_threads()

◆ BKE_render_preview_pixel_size()

int BKE_render_preview_pixel_size ( const RenderData * r)

◆ BKE_render_resolution()

◆ BKE_scene_add()

◆ BKE_scene_add_render_view()

SceneRenderView * BKE_scene_add_render_view ( Scene * sce,
const char * name )

◆ BKE_scene_allocate_depsgraph_hash()

void BKE_scene_allocate_depsgraph_hash ( Scene * scene)

◆ BKE_scene_base_flag_to_objects()

void BKE_scene_base_flag_to_objects ( const Scene * scene,
ViewLayer * view_layer )

◆ BKE_scene_base_iter_next()

◆ BKE_scene_camera_switch_find()

◆ BKE_scene_camera_switch_update()

◆ BKE_scene_can_be_removed()

bool BKE_scene_can_be_removed ( const Main * bmain,
const Scene * scene )

Definition at line 1995 of file scene.cc.

References ID_IS_LINKED, LISTBASE_FOREACH, and Main::scenes.

Referenced by scene_delete_poll().

◆ BKE_scene_check_rigidbody_active()

bool BKE_scene_check_rigidbody_active ( const Scene * scene)

◆ BKE_scene_copy_data_eevee()

void BKE_scene_copy_data_eevee ( Scene * sce_dst,
const Scene * sce_src )

◆ BKE_scene_ctime_get()

◆ BKE_scene_disable_color_management()

◆ BKE_scene_duplicate()

Scene * BKE_scene_duplicate ( Main * bmain,
Scene * sce,
eSceneCopyMethod type )

Definition at line 1825 of file scene.cc.

References Scene::audio, RenderData::bake, BKE_animdata_duplicate_id_action(), BKE_collection_duplicate(), BKE_color_managed_colorspace_settings_copy(), BKE_color_managed_display_settings_copy(), BKE_color_managed_view_settings_copy(), BKE_curvemapping_copy_data(), BKE_curvemapping_free_data(), BKE_id_copy(), BKE_id_copy_for_duplicate(), BKE_image_format_copy(), BKE_libblock_relink_to_newid(), BKE_main_collection_sync(), BKE_main_id_newptr_and_tag_clear(), BKE_scene_add(), BKE_scene_copy_data_eevee(), BKE_sound_destroy_scene(), BKE_sound_reset_scene_runtime(), BKE_toolsettings_copy(), BKE_toolsettings_free(), BLI_assert, RigidBodyWorld::constraints, Scene::display, Scene::display_settings, blender::seq::editing_free(), FOREACH_MAIN_ID_BEGIN, FOREACH_MAIN_ID_END, Scene::gpd, RigidBodyWorld::group, Scene::id, ID_IS_LINKED, ID_REMAP_FORCE_OBDATA_IN_EDITMODE, ID_TAG_NEW, id_us_ensure_real(), id_us_min(), IDP_CopyProperty(), BakeData::im_format, RenderData::im_format, LIB_ID_COPY_DEFAULT, LIB_ID_DUPLICATE_IS_SUBPROCESS, LISTBASE_FOREACH, Scene::master_collection, RenderData::mblur_shutter_curve, ID::name, Scene::physics_settings, Scene::preview, ID::properties, Scene::r, remove_sequencer_fcurves(), Scene::rigidbody_world, SCE_COPY_EMPTY, SCE_COPY_FULL, Scene::sequencer_colorspace_settings, ID::system_properties, ID::tag, Scene::toolsettings, U, Scene::unit, USER_DUP_LINKED_ID, USER_DUP_OBJECT, Scene::view_layers, Scene::view_settings, RenderData::views, and Scene::world.

Referenced by scene_add().

◆ BKE_scene_ensure_depsgraph()

◆ BKE_scene_ensure_depsgraph_hash()

void BKE_scene_ensure_depsgraph_hash ( Scene * scene)

Definition at line 3315 of file scene.cc.

References BKE_scene_allocate_depsgraph_hash(), and Scene::depsgraph_hash.

Referenced by scene_get_depsgraph_p().

◆ BKE_scene_find_from_collection()

Scene * BKE_scene_find_from_collection ( const Main * bmain,
const Collection * collection )

Definition at line 2213 of file scene.cc.

References BKE_view_layer_has_collection(), LISTBASE_FOREACH, and Main::scenes.

◆ BKE_scene_find_last_marker_name()

const char * BKE_scene_find_last_marker_name ( const Scene * scene,
int frame )

Return the current marker for this frame, we can have more than 1 marker per frame, this just returns the first (unfortunately).

Definition at line 2305 of file scene.cc.

References TimeMarker::frame, LISTBASE_FOREACH, Scene::markers, MAXFRAME, and TimeMarker::name.

Referenced by stampdata().

◆ BKE_scene_find_marker_name()

const char * BKE_scene_find_marker_name ( const Scene * scene,
int frame )

◆ BKE_scene_frame_get()

◆ BKE_scene_frame_set()

void BKE_scene_frame_set ( Scene * scene,
float frame )

Set current frame and sub-frame based on a fractional frame.

Definition at line 2386 of file scene.cc.

References RenderData::cfra, modf, Scene::r, and RenderData::subframe.

Referenced by bc_update_scene(), deg_flush_updates_and_refresh(), keyframe_jump_exec(), lineart_bake_startjob(), RE_engine_frame_set(), and blender::seq::seq_render_scene_strip().

◆ BKE_scene_frame_snap_by_seconds()

int BKE_scene_frame_snap_by_seconds ( Scene * scene,
double interval_in_seconds,
int frame )

Definition at line 2323 of file scene.cc.

References FPS, mod_i(), and round_db_to_int().

Referenced by append_second_snap_target().

◆ BKE_scene_frame_to_ctime()

float BKE_scene_frame_to_ctime ( const Scene * scene,
int frame )

Convert integer frame number to fractional frame number taking into account sub-frames and time remapping.

Definition at line 2372 of file scene.cc.

References RenderData::framelen, Scene::r, and RenderData::subframe.

Referenced by BKE_ptcache_id_time(), BKE_scene_ctime_get(), DEG_evaluate_on_framechange(), and object_add_or_copy_particle_system().

◆ BKE_scene_free_depsgraph_hash()

void BKE_scene_free_depsgraph_hash ( Scene * scene)

◆ BKE_scene_free_view_layer_depsgraph()

void BKE_scene_free_view_layer_depsgraph ( Scene * scene,
ViewLayer * view_layer )

◆ BKE_scene_get_depsgraph()

◆ BKE_scene_graph_evaluated_ensure()

◆ BKE_scene_graph_update_for_newframe()

◆ BKE_scene_graph_update_for_newframe_ex()

◆ BKE_scene_graph_update_tagged()

◆ BKE_scene_groups_relink()

void BKE_scene_groups_relink ( Scene * sce)

Definition at line 1988 of file scene.cc.

References BKE_rigidbody_world_groups_relink(), and Scene::rigidbody_world.

◆ BKE_scene_has_view_layer()

bool BKE_scene_has_view_layer ( const Scene * scene,
const ViewLayer * layer )

Definition at line 2208 of file scene.cc.

References BLI_findindex(), and Scene::view_layers.

Referenced by BKE_scene_get_depsgraph(), and scene_get_depsgraph_p().

◆ BKE_scene_multiview_filepath_get()

void BKE_scene_multiview_filepath_get ( const SceneRenderView * srv,
const char * filepath,
char * r_filepath )

Definition at line 3120 of file scene.cc.

References BLI_path_suffix(), BLI_strncpy(), FILE_MAX, and SceneRenderView::suffix.

Referenced by RE_RenderAnim().

◆ BKE_scene_multiview_is_render_view_active()

◆ BKE_scene_multiview_is_render_view_first()

bool BKE_scene_multiview_is_render_view_first ( const RenderData * rd,
const char * viewname )
Returns
true if viewname is the first or if the name is NULL or not found.

Definition at line 3026 of file scene.cc.

References BKE_scene_multiview_is_render_view_active(), LISTBASE_FOREACH, R_MULTIVIEW, RenderData::scemode, STREQ, and RenderData::views.

Referenced by blender::render::Context::viewer_output_to_viewer_image().

◆ BKE_scene_multiview_is_render_view_last()

bool BKE_scene_multiview_is_render_view_last ( const RenderData * rd,
const char * viewname )
Returns
true if viewname is the last or if the name is NULL or not found.

Definition at line 3045 of file scene.cc.

References BKE_scene_multiview_is_render_view_active(), LISTBASE_FOREACH_BACKWARD, R_MULTIVIEW, RenderData::scemode, STREQ, and RenderData::views.

◆ BKE_scene_multiview_is_stereo3d()

◆ BKE_scene_multiview_num_videos_get()

◆ BKE_scene_multiview_num_views_get()

◆ BKE_scene_multiview_render_view_findindex()

SceneRenderView * BKE_scene_multiview_render_view_findindex ( const RenderData * rd,
int view_id )

◆ BKE_scene_multiview_render_view_name_get()

const char * BKE_scene_multiview_render_view_name_get ( const RenderData * rd,
int view_id )

◆ BKE_scene_multiview_videos_dimensions_get()

void BKE_scene_multiview_videos_dimensions_get ( const RenderData * rd,
size_t width,
size_t height,
size_t * r_width,
size_t * r_height )

◆ BKE_scene_multiview_view_filepath_get()

void BKE_scene_multiview_view_filepath_get ( const RenderData * rd,
const char * filepath,
const char * view,
char * r_filepath )

When multi-view is not used the filepath is as usual (e.g., Image.jpg). When multi-view is on, even if only one view is enabled the view is incorporated into the file name (e.g., Image_L.jpg). That allows for the user to re-render individual views.

Definition at line 3128 of file scene.cc.

References BLI_findstring(), BLI_path_suffix(), BLI_strncpy(), FILE_MAX, offsetof, STRNCPY(), SceneRenderView::suffix, and RenderData::views.

Referenced by BKE_image_render_write(), and image_save_single().

◆ BKE_scene_multiview_view_id_get()

◆ BKE_scene_multiview_view_id_suffix_get()

◆ BKE_scene_multiview_view_prefix_get()

◆ BKE_scene_multiview_view_suffix_get()

◆ BKE_scene_num_threads()

◆ BKE_scene_object_base_flag_sync_from_base()

void BKE_scene_object_base_flag_sync_from_base ( Base * base)

Synchronize object base flags

This is usually handled by the depsgraph. However, in rare occasions we need to use the latest object flags before depsgraph is fully updated.

It should (ideally) only run for copy-on-written objects since this is runtime data generated per-view-layer.

Definition at line 2870 of file scene.cc.

References Object::base_flag, Base::flag, and Base::object.

Referenced by blender::ed::object::base_select(), BKE_scene_base_flag_to_objects(), BKE_scene_set_background(), loose_data_instantiate_collection_process(), loose_data_instantiate_object_base_instance_init(), blender::ed::object::make_object_duplilist_real(), and blender::ed::object::object_hide_view_clear_exec().

◆ BKE_scene_object_find()

bool BKE_scene_object_find ( Scene * scene,
Object * ob )

Check if there is any instance of the object in the scene.

Definition at line 2019 of file scene.cc.

References BKE_view_layer_object_bases_get(), BKE_view_layer_synced_ensure(), BLI_findptr(), LISTBASE_FOREACH, offsetof, and Scene::view_layers.

◆ BKE_scene_object_find_by_name()

Object * BKE_scene_object_find_by_name ( const Scene * scene,
const char * name )

◆ BKE_scene_orientation_get_index()

◆ BKE_scene_orientation_get_index_from_flag()

int BKE_scene_orientation_get_index_from_flag ( Scene * scene,
int flag )

◆ BKE_scene_orientation_slot_get()

◆ BKE_scene_orientation_slot_get_from_flag()

◆ BKE_scene_orientation_slot_get_index()

◆ BKE_scene_orientation_slot_set_index()

void BKE_scene_orientation_slot_set_index ( TransformOrientationSlot * orient_slot,
int orientation )

Activate a transform orientation in a 3D view based on an enum value.

Parameters
orientationIf this is V3D_ORIENT_CUSTOM or greater, the custom transform orientation with index orientation - V3D_ORIENT_CUSTOM gets activated.

Definition at line 2422 of file scene.cc.

References TransformOrientationSlot::index_custom, TransformOrientationSlot::type, and V3D_ORIENT_CUSTOM.

Referenced by blender::ed::transform::select_orientation_exec().

◆ BKE_scene_ppm_get()

void BKE_scene_ppm_get ( const RenderData * rd,
double r_ppm[2] )

Calculate the final pixels-per-meter, from the scenes PPM & aspect data.

Definition at line 3245 of file scene.cc.

References RenderData::ppm_base, RenderData::ppm_factor, UNLIKELY, RenderData::xasp, and RenderData::yasp.

Referenced by image_save_single(), RE_InitState(), render_result_from_bake(), render_result_new(), and blender::compositor::FileOutput::save().

◆ BKE_scene_remove_render_view()

bool BKE_scene_remove_render_view ( Scene * scene,
SceneRenderView * srv )

◆ BKE_scene_remove_rigidbody_object()

void BKE_scene_remove_rigidbody_object ( Main * bmain,
Scene * scene,
Object * ob,
bool free_us )

◆ BKE_scene_set_background()

void BKE_scene_set_background ( Main * bmain,
Scene * sce )

Sets the active scene, mainly used when running in background mode (--scene command line argument). This is also called to set the scene directly, bypassing windowing code. Otherwise WM_window_set_active_scene is used when changing scenes by the user.

Definition at line 2043 of file scene.cc.

References BKE_scene_object_base_flag_sync_from_base(), BKE_scene_validate_setscene(), BKE_view_layer_object_bases_get(), BKE_view_layer_synced_ensure(), LISTBASE_FOREACH, Main::objects, SELECT, and Scene::view_layers.

Referenced by BKE_scene_set_name(), Freestyle::BlenderStrokeRenderer::BlenderStrokeRenderer(), ED_scene_change_update(), and setup_app_data().

◆ BKE_scene_set_name()

Scene * BKE_scene_set_name ( Main * bmain,
const char * name )

◆ BKE_scene_transform_orientation_find()

◆ BKE_scene_transform_orientation_get_index()

int BKE_scene_transform_orientation_get_index ( const Scene * scene,
const TransformOrientation * orientation )
Returns
the index that orientation has within scene's transform-orientation list or -1 if not found.

Definition at line 3541 of file scene.cc.

References BLI_findindex(), and Scene::transform_spaces.

Referenced by blender::ed::transform::BIF_selectTransformOrientation(), and BKE_scene_transform_orientation_remove().

◆ BKE_scene_transform_orientation_remove()

◆ BKE_scene_undo_depsgraphs_extract()

◆ BKE_scene_undo_depsgraphs_restore()

◆ BKE_scene_update_sound()

◆ BKE_scene_update_tag_audio_volume()

void BKE_scene_update_tag_audio_volume ( Depsgraph * ,
Scene * scene )

Definition at line 2533 of file scene.cc.

References BLI_assert, DEG_is_evaluated(), Scene::id, ID_RECALC_AUDIO_VOLUME, and ID::recalc.

◆ BKE_scene_use_shading_nodes_custom()

bool BKE_scene_use_shading_nodes_custom ( Scene * scene)

◆ BKE_scene_use_spherical_stereo()

bool BKE_scene_use_spherical_stereo ( Scene * scene)

◆ BKE_scene_uses_blender_eevee()

◆ BKE_scene_uses_blender_workbench()

◆ BKE_scene_uses_cycles()

◆ BKE_scene_uses_cycles_experimental_features()

bool BKE_scene_uses_cycles_experimental_features ( Scene * scene)

Return whether the Cycles experimental feature is enabled. It is invalid to call without first ensuring that Cycles is the active render engine (e.g. with BKE_scene_uses_cycles).

Note
We cannot use const as RNA_id_pointer_create is not using a const ID.

Definition at line 2848 of file scene.cc.

References BKE_scene_uses_cycles(), BLI_assert, CYCLES_FEATURES_EXPERIMENTAL, Scene::id, RNA_enum_get(), RNA_id_pointer_create(), RNA_pointer_get(), and RNA_pointer_is_null().

Referenced by RE_engine_supports_alembic_procedural(), and uiTemplateCacheFileProcedural().

◆ BKE_scene_uses_shader_previews()

bool BKE_scene_uses_shader_previews ( const Scene * scene)

◆ BKE_scene_validate_setscene()

bool BKE_scene_validate_setscene ( Main * bmain,
Scene * sce )

Checks for cycle, returns true if it's all OK.

Definition at line 2345 of file scene.cc.

References BLI_listbase_count(), Main::scenes, and Scene::set.

Referenced by BKE_scene_set_background().

◆ BKE_scene_view_layer_graph_evaluated_ensure()

void BKE_scene_view_layer_graph_evaluated_ensure ( Main * bmain,
Scene * scene,
ViewLayer * view_layer )

Ensures given scene/view_layer pair has a valid, up-to-date depsgraph.

Warning
Sets matching depsgraph as active, so should only be called from the active editing context (usually, from operators).

Definition at line 2702 of file scene.cc.

References BKE_scene_ensure_depsgraph(), BKE_scene_graph_update_tagged(), DEG_make_active(), and depsgraph.

◆ BKE_toolsettings_copy()

◆ BKE_toolsettings_free()

◆ get_render_child_particle_number()

int get_render_child_particle_number ( const RenderData * r,
int child_num,
bool for_render )

◆ get_render_subsurf_level()

int get_render_subsurf_level ( const RenderData * r,
int lvl,
bool for_render )