forked from blender/blender
Make DomeLight visible for Storm delegate #68
@ -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>();
|
||||
|
@ -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"
|
||||
|
@ -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());
|
||||
|
@ -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)
|
||||
|
Loading…
Reference in New Issue
Block a user