Blender V4.3
blender::gpu::GLQueryPool Class Reference

#include <gl_query.hh>

Inherits blender::gpu::QueryPool.

Public Member Functions

 ~GLQueryPool ()
 
void init (GPUQueryType type) override
 
void begin_query () override
 
void end_query () override
 
void get_occlusion_result (MutableSpan< uint32_t > r_values) override
 
- Public Member Functions inherited from blender::gpu::QueryPool
virtual ~QueryPool ()
 

Detailed Description

Definition at line 19 of file gl_query.hh.

Constructor & Destructor Documentation

◆ ~GLQueryPool()

blender::gpu::GLQueryPool::~GLQueryPool ( )

Member Function Documentation

◆ begin_query()

void blender::gpu::GLQueryPool::begin_query ( )
overridevirtual

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

Implements blender::gpu::QueryPool.

Definition at line 36 of file gl_query.cc.

References blender::Vector< T, InlineBufferCapacity, Allocator >::capacity(), QUERY_CHUNCK_LEN, blender::Vector< T, InlineBufferCapacity, Allocator >::resize(), and blender::Vector< T, InlineBufferCapacity, Allocator >::size().

◆ end_query()

void blender::gpu::GLQueryPool::end_query ( )
overridevirtual

Implements blender::gpu::QueryPool.

Definition at line 48 of file gl_query.cc.

◆ get_occlusion_result()

void blender::gpu::GLQueryPool::get_occlusion_result ( MutableSpan< uint32_t > r_values)
overridevirtual

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.

Implements blender::gpu::QueryPool.

Definition at line 54 of file gl_query.cc.

References BLI_assert, and blender::MutableSpan< T >::size().

◆ init()

void blender::gpu::GLQueryPool::init ( GPUQueryType type)
overridevirtual

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.

Implements blender::gpu::QueryPool.

Definition at line 20 of file gl_query.cc.

References BLI_assert, and blender::gpu::to_gl().


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