13 : _renderParam(renderParam)
17void HdCyclesOutputDriver::write_render_tile(
const Tile &
tile)
19 update_render_tile(
tile);
22 for (
const HdRenderPassAovBinding &aovBinding : _renderParam->
GetAovBindings()) {
24 renderBuffer->SetConverged(
true);
29bool HdCyclesOutputDriver::update_render_tile(
const Tile &
tile)
31 std::vector<float> pixels;
33 for (
const HdRenderPassAovBinding &aovBinding : _renderParam->GetAovBindings()) {
34 if (
const auto renderBuffer =
static_cast<HdCyclesRenderBuffer *
>(aovBinding.renderBuffer)) {
35 if (aovBinding == _renderParam->GetDisplayAovBinding() && renderBuffer->IsResourceUsed()) {
39 const HdFormat
format = renderBuffer->GetFormat();
40 if (
format == HdFormatInvalid) {
47 tile.size.
y == renderBuffer->GetHeight() &&
48 (
format >= HdFormatFloat32 &&
format <= HdFormatFloat32Vec4))
50 float *
const data =
static_cast<float *
>(renderBuffer->Map());
51 TF_VERIFY(
tile.get_pass_pixels(aovBinding.aovName.GetString(),
channels,
data));
52 renderBuffer->Unmap();
56 if (
tile.get_pass_pixels(aovBinding.aovName.GetString(),
channels, pixels.data())) {
57 const bool isId = aovBinding.aovName == HdAovTokens->primId ||
58 aovBinding.aovName == HdAovTokens->elementId ||
59 aovBinding.aovName == HdAovTokens->instanceId;
61 renderBuffer->WritePixels(pixels.data(),
66 renderBuffer->Unmap();
70 if (aovBinding.aovName != HdAovTokens->elementId) {
71 TF_RUNTIME_ERROR(
"Could not find pass for AOV '%s'", aovBinding.aovName.GetText());
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Brightness Control the brightness and contrast of the input color Vector Map input vector components with curves Camera Retrieve information about the camera and how it relates to the current shading point s position Clamp a value between a minimum and a maximum Vector Perform vector math operation Invert Invert a producing a negative Combine Generate a color from its and blue channels(Deprecated)") DefNode(ShaderNode
HdCyclesOutputDriver(HdCyclesSession *renderParam)
const PXR_NS::HdRenderPassAovBindingVector & GetAovBindings() const
#define HDCYCLES_NAMESPACE_CLOSE_SCOPE
ccl_global const KernelWorkTile * tile