24#ifndef PXR_IMAGING_HD_ST_STRATEGY_BASE_H
25#define PXR_IMAGING_HD_ST_STRATEGY_BASE_H
28#include "pxr/imaging/hdSt/api.h"
30#include "pxr/imaging/hd/bufferSpec.h"
31#include "pxr/imaging/hd/bufferArray.h"
38PXR_NAMESPACE_OPEN_SCOPE
41using HdBufferArraySharedPtr = std::shared_ptr<class HdBufferArray>;
42using HdBufferArrayRangeSharedPtr = std::shared_ptr<class HdBufferArrayRange>;
59 HdBufferSpecVector
const &bufferSpecs,
60 HdBufferArrayUsageHint usageHint) = 0;
68 HdBufferSpecVector
const &bufferSpecs,
69 HdBufferArrayUsageHint usageHint)
const = 0;
73 HdBufferArraySharedPtr
const &bufferArray)
const = 0;
78 HdBufferArraySharedPtr
const &bufferArray,
87PXR_NAMESPACE_CLOSE_SCOPE
Aggregation strategy base class.
size_t AggregationId
Aggregation ID.
virtual HdBufferArraySharedPtr CreateBufferArray(TfToken const &role, HdBufferSpecVector const &bufferSpecs, HdBufferArrayUsageHint usageHint)=0
Factory for creating HdBufferArray.
virtual HdBufferArrayRangeSharedPtr CreateBufferArrayRange()=0
Factory for creating HdBufferArrayRange.
virtual HdBufferSpecVector GetBufferSpecs(HdBufferArraySharedPtr const &bufferArray) const =0
Returns the buffer specs from a given buffer array.
virtual AggregationId ComputeAggregationId(HdBufferSpecVector const &bufferSpecs, HdBufferArrayUsageHint usageHint) const =0
Returns id for given bufferSpecs to be used for aggregation.
virtual size_t GetResourceAllocation(HdBufferArraySharedPtr const &bufferArray, VtDictionary &result) const =0
Returns the accumulated GPU resource allocation for items in the BufferArray passed as parameter.
virtual HDST_API void Flush()
(Optional) called to Flush consolidated / staging buffers.
Token for efficient comparison, assignment, and hashing of known strings.
A map with string keys and VtValue values.
TfToken class for efficient string referencing and hashing, plus conversions to and from stl string c...