forked from blender/blender
Fix rendering of Final render for Storm delegate #61
@ -39,6 +39,7 @@ set(INC
|
||||
|
||||
set(INC_SYS
|
||||
${PYTHON_INCLUDE_DIRS}
|
||||
${Epoxy_INCLUDE_DIRS}
|
||||
${USD_INCLUDE_DIRS}
|
||||
${BOOST_INCLUDE_DIR}
|
||||
${TBB_INCLUDE_DIR}
|
||||
|
@ -1,7 +1,8 @@
|
||||
/* SPDX-License-Identifier: Apache-2.0
|
||||
* Copyright 2011-2022 Blender Foundation */
|
||||
|
||||
#include <pxr/imaging/garch/glApi.h>
|
||||
#include <epoxy/gl.h>
|
||||
|
||||
#include <pxr/imaging/hd/light.h>
|
||||
|
||||
#include "BKE_lib_id.h"
|
||||
@ -155,7 +156,7 @@ void FinalEngineGPU::render(Depsgraph *depsgraph)
|
||||
}
|
||||
GPU_framebuffer_clear_color_depth(framebuffer, clear_color, 1.0f);
|
||||
|
||||
/* Important: we have to create and bind at least one Vertex Array Object (VAO) before render
|
||||
/* Important: we have to create and bind at least one Vertex Array Object (VAO) before render
|
||||
execution: More info at https://open.gl/drawing */
|
||||
GLuint VAO;
|
||||
glGenVertexArrays(1, &VAO);
|
||||
|
@ -253,14 +253,11 @@ void ViewportEngine::render(Depsgraph *depsgraph, bContext *context)
|
||||
}
|
||||
tasks.push_back(render_task_delegate_->get_task());
|
||||
|
||||
{
|
||||
/* Release the GIL before calling into hydra, in case any hydra plugins call into python. */
|
||||
engine_->Execute(render_index_.get(), &tasks);
|
||||
engine_->Execute(render_index_.get(), &tasks);
|
||||
|
||||
if ((bl_engine_->type->flag & RE_USE_GPU_CONTEXT) == 0) {
|
||||
draw_texture_.set_buffer(render_task_delegate_->get_renderer_aov(pxr::HdAovTokens->color));
|
||||
draw_texture_.draw(shader, view_settings.border[0], view_settings.border[1]);
|
||||
}
|
||||
if ((bl_engine_->type->flag & RE_USE_GPU_CONTEXT) == 0) {
|
||||
draw_texture_.set_buffer(render_task_delegate_->get_renderer_aov(pxr::HdAovTokens->color));
|
||||
draw_texture_.draw(shader, view_settings.border[0], view_settings.border[1]);
|
||||
}
|
||||
|
||||
GPU_shader_unbind();
|
||||
|
Loading…
Reference in New Issue
Block a user