本文整理汇总了C++中bl::RenderSettings::use_motion_blur方法的典型用法代码示例。如果您正苦于以下问题:C++ RenderSettings::use_motion_blur方法的具体用法?C++ RenderSettings::use_motion_blur怎么用?C++ RenderSettings::use_motion_blur使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类bl::RenderSettings
的用法示例。
在下文中一共展示了RenderSettings::use_motion_blur方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: create_session
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// Create the Blender session and all Octane session data structures
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
void BlenderSession::create_session() {
SessionParams session_params = BlenderSync::get_session_params(b_engine, b_userpref, b_scene, interactive);
session_params.width = width;
session_params.height = height;
BL::RenderSettings r = b_scene.render();
motion_blur = r.use_motion_blur();
shuttertime = r.motion_blur_shutter();
mb_samples = r.motion_blur_samples();
mb_cur_sample = 0;
mb_sample_in_work = 0;
PointerRNA oct_scene = RNA_pointer_get(&b_scene.ptr, "octane");
mb_type = static_cast<MotionBlurType>(RNA_enum_get(&oct_scene, "mb_type"));
mb_direction = static_cast<MotionBlurDirection>(RNA_enum_get(&oct_scene, "mb_direction"));
mb_frame_time_sampling = motion_blur && mb_type == INTERNAL ? 1.0f / session_params.fps : -1.0f;
// Reset status/progress
last_status = "";
last_progress = -1.0f;
// Create session
string cur_path = blender_absolute_path(b_data, b_scene, b_scene.render().filepath().c_str());
cur_path += "/alembic_export.abc";
session = new Session(session_params, cur_path.c_str());
session->set_blender_session(this);
session->set_pause(BlenderSync::get_session_pause_state(b_scene, interactive));
// Create scene
scene = new Scene(session, interactive || !b_engine.is_animation() ? true : (b_scene.frame_current() == b_scene.frame_start()));
session->scene = scene;
scene->server = session->server;
// Create sync
sync = new BlenderSync(b_engine, b_data, b_scene, scene, interactive, session->progress);
if(b_rv3d)
sync->sync_view(b_v3d, b_rv3d, width, height);
else
sync->sync_camera(b_engine.camera_override(), width, height);
// Set buffer parameters
BufferParams buffer_params = BlenderSync::get_display_buffer_params(scene->camera, width, height);
if(interactive || !b_engine.is_animation() || b_scene.frame_current() == b_scene.frame_start())
session->reset(buffer_params, mb_frame_time_sampling);
} //create_session()