forked from blender/blender
Support more AOVs #78
@ -119,7 +119,8 @@ void Engine::set_sync_setting(const std::string &key, const pxr::VtValue &val)
|
||||
void Engine::set_render_setting(const std::string &key, const pxr::VtValue &val)
|
||||
{
|
||||
if (STRPREFIX(key.c_str(), "aovToken:")) {
|
||||
render_delegate_settings_.aovs.add_new(key.substr(key.find(":") + 1), pxr::TfToken(val.UncheckedGet<std::string>()));
|
||||
render_delegate_settings_.aovs.add_new(key.substr(key.find(":") + 1),
|
||||
pxr::TfToken(val.UncheckedGet<std::string>()));
|
||||
}
|
||||
else {
|
||||
render_delegate_->SetRenderSetting(pxr::TfToken(key), val);
|
||||
|
@ -70,8 +70,7 @@ void RenderTaskDelegate::set_camera(pxr::SdfPath const &camera_id)
|
||||
return;
|
||||
}
|
||||
task_params_.camera = camera_id;
|
||||
GetRenderIndex().GetChangeTracker().MarkTaskDirty(task_id_,
|
||||
pxr::HdChangeTracker::DirtyParams);
|
||||
GetRenderIndex().GetChangeTracker().MarkTaskDirty(task_id_, pxr::HdChangeTracker::DirtyParams);
|
||||
}
|
||||
|
||||
bool RenderTaskDelegate::is_converged()
|
||||
@ -86,8 +85,7 @@ void RenderTaskDelegate::set_viewport(pxr::GfVec4d const &viewport)
|
||||
}
|
||||
auto &render_index = GetRenderIndex();
|
||||
task_params_.viewport = viewport;
|
||||
render_index.GetChangeTracker().MarkTaskDirty(task_id_,
|
||||
pxr::HdChangeTracker::DirtyParams);
|
||||
render_index.GetChangeTracker().MarkTaskDirty(task_id_, pxr::HdChangeTracker::DirtyParams);
|
||||
|
||||
int w = viewport[2] - viewport[0];
|
||||
int h = viewport[3] - viewport[1];
|
||||
@ -123,8 +121,7 @@ void RenderTaskDelegate::add_aov(pxr::TfToken const &aov_key)
|
||||
binding.renderBufferId = buf_id;
|
||||
binding.aovSettings = aov_desc.aovSettings;
|
||||
task_params_.aovBindings.push_back(binding);
|
||||
render_index.GetChangeTracker().MarkTaskDirty(task_id_,
|
||||
pxr::HdChangeTracker::DirtyParams);
|
||||
render_index.GetChangeTracker().MarkTaskDirty(task_id_, pxr::HdChangeTracker::DirtyParams);
|
||||
|
||||
CLOG_INFO(LOG_RENDER_HYDRA, 1, "%s", aov_key.GetText());
|
||||
}
|
||||
@ -171,8 +168,7 @@ void GPURenderTaskDelegate::set_viewport(pxr::GfVec4d const &viewport)
|
||||
}
|
||||
auto &render_index = GetRenderIndex();
|
||||
task_params_.viewport = viewport;
|
||||
render_index.GetChangeTracker().MarkTaskDirty(task_id_,
|
||||
pxr::HdChangeTracker::DirtyParams);
|
||||
render_index.GetChangeTracker().MarkTaskDirty(task_id_, pxr::HdChangeTracker::DirtyParams);
|
||||
|
||||
if (tex_color_) {
|
||||
GPU_texture_free(tex_color_);
|
||||
|
Loading…
Reference in New Issue
Block a user