Open 3D Engine Atom Gem API Reference 25.05.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
AZ::RHI::FrameAttachment Class Reference

#include <FrameAttachment.h>

Inherited by AZ::RHI::BufferFrameAttachment, and AZ::RHI::ImageFrameAttachment.

Public Member Functions

 AZ_RTTI (FrameAttachment, "{F35548B3-4B2C-478C-9ED9-759CAEAE2729}")
 
const AttachmentId & GetId () const
 Returns the attachment id.
 
ResourceGetResource ()
 Returns the resource associated with this frame attachment.
 
const ResourceGetResource () const
 
AttachmentLifetimeType GetLifetimeType () const
 Returns the attachment lifetime type.
 
const ScopeAttachmentGetFirstScopeAttachment (int deviceIndex) const
 
ScopeAttachmentGetFirstScopeAttachment (int deviceIndex)
 
const ScopeAttachmentGetLastScopeAttachment (int deviceIndex) const
 
ScopeAttachmentGetLastScopeAttachment (int deviceIndex)
 
bool HasScopeAttachments () const
 Returns whether there are any scope attachments at all.
 
ScopeGetFirstScope (int deviceIndex) const
 
ScopeGetLastScope (int deviceIndex) const
 
HardwareQueueClassMask GetUsedQueueMask () const
 Returns the mask of all the hardware queues that this attachment is used on.
 
HardwareQueueClassMask GetSupportedQueueMask () const
 Returns the mask of all the hardware queues that this attachment is supported on.
 
void SetResource (Ptr< Resource > resource, int deviceIndex=MultiDevice::InvalidDeviceIndex)
 [Internal] Assigns the resource. This may only be done once.
 

Protected Member Functions

 FrameAttachment (const AttachmentId &attachmentId, HardwareQueueClassMask supportedQueueMask, AttachmentLifetimeType lifetimeType)
 
 FrameAttachment (const FrameAttachment &)=delete
 
 FrameAttachment (FrameAttachment &&)=delete
 

Friends

class FrameGraphAttachmentDatabase
 
class FrameGraphCompiler
 

Detailed Description

FrameAttachment is the base class for all attachments stored in the frame graph. Attachments can be used on multiple devices at the same time. They are "attached" to scopes via ScopeAttachment instances. These scope attachments form a linked list per device from the first to last scope on each device. FrameAttachments are associated with a unique AttachmentId.

FrameAttachments are rebuilt every frame, and are created through the FrameGraph.

Member Function Documentation

◆ GetFirstScope()

Scope * AZ::RHI::FrameAttachment::GetFirstScope ( int  deviceIndex) const

Returns the first / last scope associated with the lifetime of this attachment of a specific device or nullptr if no Scope uses this attachment on the given device. The guarantee is that the attachment is not used by any scope with index prior to GetFirstScope or any scope with index after GetLastScope. It does not, however, guarantee that the attachment is actually used by either scope. The scope attachment list must be traversed to determine usage.

◆ GetFirstScopeAttachment()

const ScopeAttachment * AZ::RHI::FrameAttachment::GetFirstScopeAttachment ( int  deviceIndex) const

Returns the first scope attachment in the linked list of a specific device or nullptr if no Scope uses this attachment on the given device.

◆ GetLastScopeAttachment()

const ScopeAttachment * AZ::RHI::FrameAttachment::GetLastScopeAttachment ( int  deviceIndex) const

Returns the last scope attachment in the linked list of a specific device or nullptr if no Scope uses this attachment on the given device.


The documentation for this class was generated from the following file: