|
Blender V4.3
|
#include <vk_render_graph_node.hh>
Public Member Functions | |
| template<typename NodeInfo > | |
| void | set_node_data (const typename NodeInfo::CreateInfo &create_info) |
| template<typename NodeInfo > | |
| void | build_links (VKResourceStateTracker &resources, VKRenderGraphNodeLinks &node_links, const typename NodeInfo::CreateInfo &create_info) |
| VkPipelineStageFlags | pipeline_stage_get () const |
| void | build_commands (VKCommandBufferInterface &command_buffer, VKBoundPipelines &r_bound_pipelines) |
| void | free_data () |
| void | reset () |
Node stored inside a render graph.
Node specific data in the render graph are stored in a vector to ensure that the data can be prefetched and removing a level of indirection. A consequence is that we cannot use class based nodes.
Definition at line 49 of file vk_render_graph_node.hh.
|
inline |
Build commands for this node and record them in the given command_buffer.
NOTE: Pipeline barriers should already be added. See VKCommandBuilder::build_node and `VKCommandBuilderbuild_pipeline_barriers.
Definition at line 178 of file vk_render_graph_node.hh.
References blender::gpu::render_graph::BEGIN_QUERY, begin_query, blender::gpu::render_graph::BEGIN_RENDERING, begin_rendering, blender::gpu::render_graph::BLIT_IMAGE, blit_image, BUILD_COMMANDS, blender::gpu::render_graph::CLEAR_ATTACHMENTS, clear_attachments, blender::gpu::render_graph::CLEAR_COLOR_IMAGE, clear_color_image, blender::gpu::render_graph::CLEAR_DEPTH_STENCIL_IMAGE, clear_depth_stencil_image, blender::gpu::render_graph::COPY_BUFFER, copy_buffer, blender::gpu::render_graph::COPY_BUFFER_TO_IMAGE, copy_buffer_to_image, blender::gpu::render_graph::COPY_IMAGE, copy_image, blender::gpu::render_graph::COPY_IMAGE_TO_BUFFER, copy_image_to_buffer, blender::gpu::render_graph::DISPATCH, dispatch, blender::gpu::render_graph::DISPATCH_INDIRECT, dispatch_indirect, blender::gpu::render_graph::DRAW, draw, blender::gpu::render_graph::DRAW_INDEXED, draw_indexed, blender::gpu::render_graph::DRAW_INDEXED_INDIRECT, draw_indexed_indirect, blender::gpu::render_graph::DRAW_INDIRECT, draw_indirect, blender::gpu::render_graph::END_QUERY, end_query, blender::gpu::render_graph::END_RENDERING, end_rendering, blender::gpu::render_graph::FILL_BUFFER, fill_buffer, blender::gpu::render_graph::RESET_QUERY_POOL, reset_query_pool, blender::gpu::render_graph::SYNCHRONIZATION, synchronization, blender::gpu::render_graph::UNUSED, blender::gpu::render_graph::UPDATE_BUFFER, update_buffer, blender::gpu::render_graph::UPDATE_MIPMAPS, and update_mipmaps.
|
inline |
Build the input/output links for this.
Newly created links are added to the node_links parameter.
Definition at line 101 of file vk_render_graph_node.hh.
|
inline |
Free data kept by the node
Definition at line 227 of file vk_render_graph_node.hh.
References blender::gpu::render_graph::BEGIN_QUERY, blender::gpu::render_graph::BEGIN_RENDERING, blender::gpu::render_graph::BLIT_IMAGE, blender::gpu::render_graph::CLEAR_ATTACHMENTS, blender::gpu::render_graph::CLEAR_COLOR_IMAGE, blender::gpu::render_graph::CLEAR_DEPTH_STENCIL_IMAGE, blender::gpu::render_graph::COPY_BUFFER, blender::gpu::render_graph::COPY_BUFFER_TO_IMAGE, blender::gpu::render_graph::COPY_IMAGE, blender::gpu::render_graph::COPY_IMAGE_TO_BUFFER, blender::gpu::render_graph::DISPATCH, dispatch, blender::gpu::render_graph::DISPATCH_INDIRECT, dispatch_indirect, blender::gpu::render_graph::DRAW, draw, blender::gpu::render_graph::DRAW_INDEXED, draw_indexed, blender::gpu::render_graph::DRAW_INDEXED_INDIRECT, draw_indexed_indirect, blender::gpu::render_graph::DRAW_INDIRECT, draw_indirect, blender::gpu::render_graph::END_QUERY, blender::gpu::render_graph::END_RENDERING, blender::gpu::render_graph::FILL_BUFFER, FREE_DATA, blender::gpu::render_graph::RESET_QUERY_POOL, blender::gpu::render_graph::SYNCHRONIZATION, blender::gpu::render_graph::UNUSED, blender::gpu::render_graph::UPDATE_BUFFER, update_buffer, and blender::gpu::render_graph::UPDATE_MIPMAPS.
Referenced by reset().
|
inline |
Get the pipeline stage of the node.
Pipeline stage is used to update src/dst_stage_masks of the VKCommandBuilder.
Definition at line 116 of file vk_render_graph_node.hh.
References blender::gpu::render_graph::BEGIN_QUERY, blender::gpu::render_graph::BEGIN_RENDERING, BLI_assert_unreachable, blender::gpu::render_graph::BLIT_IMAGE, blender::gpu::render_graph::CLEAR_ATTACHMENTS, blender::gpu::render_graph::CLEAR_COLOR_IMAGE, blender::gpu::render_graph::CLEAR_DEPTH_STENCIL_IMAGE, blender::gpu::render_graph::COPY_BUFFER, blender::gpu::render_graph::COPY_BUFFER_TO_IMAGE, blender::gpu::render_graph::COPY_IMAGE, blender::gpu::render_graph::COPY_IMAGE_TO_BUFFER, blender::gpu::render_graph::DISPATCH, blender::gpu::render_graph::DISPATCH_INDIRECT, blender::gpu::render_graph::DRAW, blender::gpu::render_graph::DRAW_INDEXED, blender::gpu::render_graph::DRAW_INDEXED_INDIRECT, blender::gpu::render_graph::DRAW_INDIRECT, blender::gpu::render_graph::END_QUERY, blender::gpu::render_graph::END_RENDERING, blender::gpu::render_graph::FILL_BUFFER, blender::gpu::render_graph::VKNodeInfo< VKNodeType::BEGIN_QUERY, VKBeginQueryData, VKBeginQueryData, VK_PIPELINE_STAGE_NONE, VKResourceType::NONE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::BEGIN_RENDERING, VKBeginRenderingCreateInfo, VKBeginRenderingData, VK_PIPELINE_STAGE_ALL_GRAPHICS_BIT, VKResourceType::IMAGE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::BLIT_IMAGE, VKBlitImageData, VKBlitImageData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::IMAGE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::CLEAR_ATTACHMENTS, VKClearAttachmentsData, VKClearAttachmentsData, VK_PIPELINE_STAGE_COLOR_ATTACHMENT_OUTPUT_BIT|VK_PIPELINE_STAGE_EARLY_FRAGMENT_TESTS_BIT|VK_PIPELINE_STAGE_LATE_FRAGMENT_TESTS_BIT, VKResourceType::IMAGE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::CLEAR_COLOR_IMAGE, VKClearColorImageData, VKClearColorImageData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::IMAGE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::CLEAR_DEPTH_STENCIL_IMAGE, VKClearDepthStencilImageCreateInfo, VKClearDepthStencilImageData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::IMAGE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::COPY_BUFFER, VKCopyBufferData, VKCopyBufferData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::COPY_BUFFER_TO_IMAGE, VKCopyBufferToImageData, VKCopyBufferToImageData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::IMAGE|VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::COPY_IMAGE, VKCopyImageCreateInfo, VKCopyImageData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::IMAGE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::COPY_IMAGE_TO_BUFFER, VKCopyImageToBufferData, VKCopyImageToBufferData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::IMAGE|VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::DISPATCH, VKDispatchCreateInfo, VKDispatchData, VK_PIPELINE_STAGE_COMPUTE_SHADER_BIT, VKResourceType::IMAGE|VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::DISPATCH_INDIRECT, VKDispatchIndirectCreateInfo, VKDispatchIndirectData, VK_PIPELINE_STAGE_DRAW_INDIRECT_BIT|VK_PIPELINE_STAGE_COMPUTE_SHADER_BIT, VKResourceType::IMAGE|VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::DRAW, VKDrawCreateInfo, VKDrawData, VK_PIPELINE_STAGE_ALL_GRAPHICS_BIT, VKResourceType::IMAGE|VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::DRAW_INDEXED, VKDrawIndexedCreateInfo, VKDrawIndexedData, VK_PIPELINE_STAGE_ALL_GRAPHICS_BIT, VKResourceType::IMAGE|VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::DRAW_INDEXED_INDIRECT, VKDrawIndexedIndirectCreateInfo, VKDrawIndexedIndirectData, VK_PIPELINE_STAGE_ALL_GRAPHICS_BIT, VKResourceType::IMAGE|VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::DRAW_INDIRECT, VKDrawIndirectCreateInfo, VKDrawIndirectData, VK_PIPELINE_STAGE_ALL_GRAPHICS_BIT, VKResourceType::IMAGE|VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::END_QUERY, VKEndQueryData, VKEndQueryData, VK_PIPELINE_STAGE_NONE, VKResourceType::IMAGE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::END_RENDERING, VKEndRenderingData, VKEndRenderingData, VK_PIPELINE_STAGE_ALL_GRAPHICS_BIT, VKResourceType::NONE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::FILL_BUFFER, VKFillBufferData, VKFillBufferData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::RESET_QUERY_POOL, VKResetQueryPoolData, VKResetQueryPoolData, VK_PIPELINE_STAGE_NONE, VKResourceType::NONE >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::SYNCHRONIZATION, VKSynchronizationCreateInfo, VKSynchronizationData, VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT, VKResourceType::IMAGE|VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::UPDATE_BUFFER, VKUpdateBufferData, VKUpdateBufferData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::BUFFER >::pipeline_stage, blender::gpu::render_graph::VKNodeInfo< VKNodeType::UPDATE_MIPMAPS, VKUpdateMipmapsData, VKUpdateMipmapsData, VK_PIPELINE_STAGE_TRANSFER_BIT, VKResourceType::IMAGE >::pipeline_stage, blender::gpu::render_graph::RESET_QUERY_POOL, blender::gpu::render_graph::SYNCHRONIZATION, blender::gpu::render_graph::UNUSED, blender::gpu::render_graph::UPDATE_BUFFER, and blender::gpu::render_graph::UPDATE_MIPMAPS.
|
inline |
Reset nodes.
Nodes are reset so they can be reused in consecutive calls. Data allocated by the node are freed. This function dispatches the free_data to the actual node implementation.
Definition at line 275 of file vk_render_graph_node.hh.
References free_data(), and blender::gpu::render_graph::UNUSED.
|
inline |
Set the data of the node.
Pre-conditions:
VKNodeType::UNUSED. Memory allocated for nodes are reused between consecutive use. Checking for unused node types will ensure that previous usage has been reset. Resetting is done as part of free_data Definition at line 85 of file vk_render_graph_node.hh.
References BLI_assert, and blender::gpu::render_graph::UNUSED.
| union { ... } blender::gpu::render_graph::VKRenderGraphNode |
| VKBeginQueryNode::Data blender::gpu::render_graph::VKRenderGraphNode::begin_query |
Definition at line 52 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKBeginRenderingNode::Data blender::gpu::render_graph::VKRenderGraphNode::begin_rendering |
Definition at line 53 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKBlitImageNode::Data blender::gpu::render_graph::VKRenderGraphNode::blit_image |
Definition at line 54 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKClearAttachmentsNode::Data blender::gpu::render_graph::VKRenderGraphNode::clear_attachments |
Definition at line 55 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKClearColorImageNode::Data blender::gpu::render_graph::VKRenderGraphNode::clear_color_image |
Definition at line 56 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKClearDepthStencilImageNode::Data blender::gpu::render_graph::VKRenderGraphNode::clear_depth_stencil_image |
Definition at line 57 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKCopyBufferNode::Data blender::gpu::render_graph::VKRenderGraphNode::copy_buffer |
Definition at line 58 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKCopyBufferToImageNode::Data blender::gpu::render_graph::VKRenderGraphNode::copy_buffer_to_image |
Definition at line 59 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKCopyImageNode::Data blender::gpu::render_graph::VKRenderGraphNode::copy_image |
Definition at line 60 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKCopyImageToBufferNode::Data blender::gpu::render_graph::VKRenderGraphNode::copy_image_to_buffer |
Definition at line 61 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKDispatchNode::Data blender::gpu::render_graph::VKRenderGraphNode::dispatch |
Definition at line 62 of file vk_render_graph_node.hh.
Referenced by build_commands(), and free_data().
| VKDispatchIndirectNode::Data blender::gpu::render_graph::VKRenderGraphNode::dispatch_indirect |
Definition at line 63 of file vk_render_graph_node.hh.
Referenced by build_commands(), and free_data().
| VKDrawNode::Data blender::gpu::render_graph::VKRenderGraphNode::draw |
Definition at line 64 of file vk_render_graph_node.hh.
Referenced by build_commands(), and free_data().
| VKDrawIndexedNode::Data blender::gpu::render_graph::VKRenderGraphNode::draw_indexed |
Definition at line 65 of file vk_render_graph_node.hh.
Referenced by build_commands(), and free_data().
| VKDrawIndexedIndirectNode::Data blender::gpu::render_graph::VKRenderGraphNode::draw_indexed_indirect |
Definition at line 66 of file vk_render_graph_node.hh.
Referenced by build_commands(), and free_data().
| VKDrawIndirectNode::Data blender::gpu::render_graph::VKRenderGraphNode::draw_indirect |
Definition at line 67 of file vk_render_graph_node.hh.
Referenced by build_commands(), and free_data().
| VKEndQueryNode::Data blender::gpu::render_graph::VKRenderGraphNode::end_query |
Definition at line 68 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKEndRenderingNode::Data blender::gpu::render_graph::VKRenderGraphNode::end_rendering |
Definition at line 69 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKFillBufferNode::Data blender::gpu::render_graph::VKRenderGraphNode::fill_buffer |
Definition at line 70 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKResetQueryPoolNode::Data blender::gpu::render_graph::VKRenderGraphNode::reset_query_pool |
Definition at line 71 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKSynchronizationNode::Data blender::gpu::render_graph::VKRenderGraphNode::synchronization |
Definition at line 72 of file vk_render_graph_node.hh.
Referenced by build_commands().
| VKNodeType blender::gpu::render_graph::VKRenderGraphNode::type |
Definition at line 50 of file vk_render_graph_node.hh.
| VKUpdateBufferNode::Data blender::gpu::render_graph::VKRenderGraphNode::update_buffer |
Definition at line 73 of file vk_render_graph_node.hh.
Referenced by build_commands(), and free_data().
| VKUpdateMipmapsNode::Data blender::gpu::render_graph::VKRenderGraphNode::update_mipmaps |
Definition at line 74 of file vk_render_graph_node.hh.
Referenced by build_commands().