Lines Matching defs:state
296 // copy input resource state
353 ResourceBarrier GetSrcBufferBarrier(const GpuResourceState& state, const BindableBuffer& res)
356 state.accessFlags,
357 state.pipelineStageFlags | PipelineStageFlagBits::CORE_PIPELINE_STAGE_TOP_OF_PIPE_BIT,
364 ResourceBarrier GetSrcImageBarrier(const GpuResourceState& state, const BindableImage& res)
367 state.accessFlags,
368 state.pipelineStageFlags | PipelineStageFlagBits::CORE_PIPELINE_STAGE_TOP_OF_PIPE_BIT,
375 ResourceBarrier GetSrcImageBarrierMips(const GpuResourceState& state, const BindableImage& src,
394 state.accessFlags,
395 state.pipelineStageFlags | PipelineStageFlagBits::CORE_PIPELINE_STAGE_TOP_OF_PIPE_BIT,
403 ResourceBarrier GetDstBufferBarrier(const GpuResourceState& state, const BindableBuffer& res)
406 state.accessFlags,
407 state.pipelineStageFlags | PipelineStageFlagBits::CORE_PIPELINE_STAGE_BOTTOM_OF_PIPE_BIT,
414 ResourceBarrier GetDstImageBarrier(const GpuResourceState& state, const BindableImage& res)
417 state.accessFlags,
418 state.pipelineStageFlags | PipelineStageFlagBits::CORE_PIPELINE_STAGE_BOTTOM_OF_PIPE_BIT,
425 ResourceBarrier GetDstImageBarrierMips(const GpuResourceState& state, const BindableImage& src,
442 state.accessFlags,
443 state.pipelineStageFlags | PipelineStageFlagBits::CORE_PIPELINE_STAGE_BOTTOM_OF_PIPE_BIT,
625 // need to store some of the resource for frame state in undefined state (i.e. reset on frame boundaries)
628 // store final state for next frame
791 // store final state for backbuffer
793 const uint32_t flags = ref.state.accessFlags | ref.state.shaderStageFlags | ref.state.pipelineStageFlags;
795 swapchainStates_.swapchains.push_back({ ref.resource.handle, ref.state, ref.resource.imageLayout });
805 // they are always in undefined state in the beging of the frame
827 // update layouts for attachments to gpu image state
962 attachmentInputResourceStates.states[attachmentIdx] = stateRef.state;
993 ref.state = refState;
1110 stateRef.state.shaderStageFlags = 0;
1111 stateRef.state.accessFlags = cb.dst.accessFlags;
1112 stateRef.state.pipelineStageFlags = cb.dst.pipelineStageFlags;
1113 stateRef.state.gpuQueue = params.gpuQueue;
1122 stateRef.state.shaderStageFlags = 0;
1123 stateRef.state.accessFlags = cb.dst.accessFlags;
1124 stateRef.state.pipelineStageFlags = cb.dst.pipelineStageFlags;
1125 stateRef.state.gpuQueue = params.gpuQueue;
1181 cb.src.accessFlags = stateRef.state.accessFlags;
1183 stateRef.state.pipelineStageFlags | PipelineStageFlagBits::CORE_PIPELINE_STAGE_TOP_OF_PIPE_BIT;
1452 UpdateStateAndCreateBarriersGpuBuffer(bRes.state, bRes.resource, params);
1469 UpdateStateAndCreateBarriersGpuImage(bRes.state, bRes.resource, params);
1477 const GpuResourceState& state, const BindableImage& res, RenderGraph::ParameterCache& params)
1484 auto& ref = GetImageResourceStateRef(res.handle, state.gpuQueue);
1488 const GpuResourceState& prevState = ref.state;
1495 const bool accessFlagsChanged = (prevStateRb.accessFlags != state.accessFlags);
1497 const bool inputAttachment = (state.accessFlags == CORE_ACCESS_INPUT_ATTACHMENT_READ_BIT);
1501 (prevState.gpuQueue.type != state.gpuQueue.type)) {
1502 PLUGIN_ASSERT(state.gpuQueue.type != GpuQueue::QueueType::UNDEFINED);
1509 addMips ? GetDstImageBarrierMips(state, prevImage, res, ref.additionalState)
1510 : GetDstImageBarrier(state, res);
1515 ref.state = state;
1533 // get the current state of the buffer
1535 const ResourceBarrier prevStateRb = GetSrcBufferBarrier(srcStateRef.state, res);
1541 // update the cached state to match the situation after the barrier
1542 srcStateRef.state = dstState;
1554 const GpuResourceState srcState = stateRef.state;
1573 stateRef.state = newGpuResourceState;
1586 const GpuResourceState srcState = stateRef.state;
1609 stateRef.state = newGpuResourceState;
1638 gpuBufferTracking_[dataIdx].state.gpuQueue = queue; // current queue for default state
1667 gpuImageTracking_[dataIdx].state.gpuQueue = queue; // current queue for default state