Make DomeLight visible for Storm delegate #68

Merged
Bogdan Nagirniak merged 5 commits from Vasyl-Pidhirskyi/blender_bn:BLEN-460 into hydra-render 2023-07-20 22:35:48 +02:00
5 changed files with 10 additions and 15 deletions
Showing only changes of commit 18486907b0 - Show all commits

View File

@ -54,8 +54,7 @@ Engine::Engine(RenderEngine *bl_engine, const std::string &render_delegate_name)
render_index_.get(), pxr::SdfPath::AbsoluteRootPath().AppendElementString("renderTask"));
if (render_delegate_name == "HdStormRendererPlugin") {
light_tasks_delegate_ = std::make_unique<LightTasksDelegate>(
render_index_.get(),
pxr::SdfPath::AbsoluteRootPath().AppendElementString("lightTasks"));
render_index_.get(), pxr::SdfPath::AbsoluteRootPath().AppendElementString("lightTasks"));
}
engine_ = std::make_unique<pxr::HdEngine>();

View File

@ -17,8 +17,8 @@
#include "CLG_log.h"
#include "render_task_delegate.h"
#include "light_tasks_delegate.h"
#include "render_task_delegate.h"
#include "scene_delegate/blender_scene_delegate.h"
#include "scene_delegate/usd_scene_delegate.hh"

View File

@ -109,8 +109,7 @@ void FinalEngine::prepare_for_render(Depsgraph *depsgraph)
if (light_tasks_delegate_) {
light_tasks_delegate_->set_camera_path(free_camera_delegate_->GetCameraId());
light_tasks_delegate_->set_camera_and_viewport(
free_camera_delegate_->GetCameraId(), pxr::GfVec4d(0, 0, resolution_[0],
resolution_[1]));
free_camera_delegate_->GetCameraId(), pxr::GfVec4d(0, 0, resolution_[0], resolution_[1]));
tasks_ = light_tasks_delegate_->get_tasks();
}
tasks_.push_back(render_task_delegate_->get_task());

View File

@ -20,10 +20,7 @@ LightTasksDelegate::LightTasksDelegate(pxr::HdRenderIndex *parent_index,
pxr::HdTaskSharedPtrVector LightTasksDelegate::get_tasks()
{
return {
GetRenderIndex().GetTask(skydome_task),
GetRenderIndex().GetTask(simple_light_task)
};
return {GetRenderIndex().GetTask(skydome_task), GetRenderIndex().GetTask(simple_light_task)};
}
void LightTasksDelegate::set_camera_path(pxr::SdfPath const &camera_path)