Panda3D
Public Member Functions | Static Public Member Functions | Friends
OcclusionQueryContext Class Reference

Returned from a GSG in response to begin_occlusion_query() . More...

#include "occlusionQueryContext.h"

Inheritance diagram for OcclusionQueryContext:
QueryContext TypedReferenceCount TypedObject ReferenceCount MemoryBase MemoryBase DXOcclusionQueryContext9

List of all members.

Public Member Functions

virtual TypeHandle force_init_type ()
virtual int get_num_fragments () const =0
 Returns the number of fragments (pixels) of the specified geometry that passed the depth test.
virtual TypeHandle get_type () const

Static Public Member Functions

static TypeHandle get_class_type ()
static void init_type ()
 This function is declared non-inline to work around a compiler bug in g++ 2.96.

Friends

class PreparedGraphicsObjects

Detailed Description

Returned from a GSG in response to begin_occlusion_query() .

. end_occlusion_query(), this records the number of fragments (pixels) that passed the depth test between the bracketing calls.

Definition at line 28 of file occlusionQueryContext.h.


Member Function Documentation

int OcclusionQueryContext::get_num_fragments ( ) const [pure virtual]

Returns the number of fragments (pixels) of the specified geometry that passed the depth test.

If is_answer_ready() did not return true, this function may block before it returns.

It is only valid to call this from the draw thread.

Implemented in DXOcclusionQueryContext9.

Definition at line 30 of file occlusionQueryContext.cxx.

static void OcclusionQueryContext::init_type ( ) [inline, static]

This function is declared non-inline to work around a compiler bug in g++ 2.96.

Making it inline seems to cause problems in the optimizer.

Reimplemented from QueryContext.

Reimplemented in DXOcclusionQueryContext9.

Definition at line 38 of file occlusionQueryContext.h.

References QueryContext::init_type().

Referenced by DXOcclusionQueryContext9::init_type().


The documentation for this class was generated from the following files:
 All Classes Functions Variables Enumerations