Blender V4.3
blender::gpu::QueryPool Class Referenceabstract

#include <gpu_query.hh>

Inherited by blender::gpu::GLQueryPool, blender::gpu::MTLQueryPool, and blender::gpu::VKQueryPool.

Public Member Functions

virtual ~QueryPool ()
 
virtual void init (GPUQueryType type)=0
 
virtual void begin_query ()=0
 
virtual void end_query ()=0
 
virtual void get_occlusion_result (MutableSpan< uint32_t > r_values)=0
 

Detailed Description

Definition at line 21 of file gpu_query.hh.

Constructor & Destructor Documentation

◆ ~QueryPool()

virtual blender::gpu::QueryPool::~QueryPool ( )
inlinevirtual

Definition at line 23 of file gpu_query.hh.

Member Function Documentation

◆ begin_query()

virtual void blender::gpu::QueryPool::begin_query ( )
pure virtual

Will start and end the query at this index inside the pool. The pool will resize automatically.

Implemented in blender::gpu::GLQueryPool, blender::gpu::MTLQueryPool, and blender::gpu::VKQueryPool.

Referenced by gpu_select_query_load_id().

◆ end_query()

virtual void blender::gpu::QueryPool::end_query ( )
pure virtual

◆ get_occlusion_result()

virtual void blender::gpu::QueryPool::get_occlusion_result ( MutableSpan< uint32_t > r_values)
pure virtual

Must be fed with a buffer large enough to contain all the queries issued. IMPORTANT: Result for each query can be either binary or represent the number of samples drawn.

Implemented in blender::gpu::GLQueryPool, blender::gpu::MTLQueryPool, and blender::gpu::VKQueryPool.

Referenced by gpu_select_query_end().

◆ init()

virtual void blender::gpu::QueryPool::init ( GPUQueryType type)
pure virtual

Will start and end the query at this index inside the pool. The pool will resize automatically but does not support sparse allocation. So prefer using consecutive indices.

Implemented in blender::gpu::GLQueryPool, blender::gpu::MTLQueryPool, and blender::gpu::VKQueryPool.

Referenced by gpu_select_query_begin().


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