OGLplus (0.45.0) a C++ wrapper for OpenGL

An OGLplus object encapsulating the OpenGL asynchronous query functionality. More...

#include </home/chochlik/devel/oglplus/include/oglplus/query.hpp>

Inheritance diagram for oglplus::Query:
Collaboration diagram for oglplus::Query:

Public Types

typedef QueryTarget Target
 Query bind target.
 

Public Member Functions

void Begin (Target target) const
 Begin the query on the specified target. More...
 
void End (Target target) const
 End the query on the specified target. More...
 
void Counter (Target target) const
 Do a counter query on the specified target. More...
 
void Timestamp (void) const
 Do a timestamp query. More...
 
bool ResultAvailable (void) const
 Returns true if the query result is available. More...
 
void Result (GLint &result) const
 Get the query result. More...
 
void Result (GLuint &result) const
 Get the query result. More...
 
void Result (GLint64 &result) const
 Get the query result. More...
 
void Result (GLuint64 &result) const
 Get the query result. More...
 
template<typename ResultType >
void WaitForResult (ResultType &result) const
 Waits for and queries the result.
 
template<typename ResultType >
Execution< ResultType > Execute (Target target, ResultType &result) const
 Executes the query on the specified target and gets the result. More...
 

Detailed Description

An OGLplus object encapsulating the OpenGL asynchronous query functionality.

Examples:
standalone/020_oglplus_oalplus.cpp.

Member Function Documentation

void oglplus::QueryOps::Begin ( Target  target) const
inherited

Begin the query on the specified target.

Related OpenGL symbols:
glBeginQuery

References oglplus::EnumValueName(), and OGLPLUS_VERIFY.

void oglplus::QueryOps::Counter ( Target  target) const
inherited

Do a counter query on the specified target.

Related OpenGL symbols:
glQueryCounter

References oglplus::EnumValueName(), and OGLPLUS_VERIFY.

Referenced by oglplus::QueryOps::Timestamp().

void oglplus::QueryOps::End ( Target  target) const
inherited

End the query on the specified target.

Related OpenGL symbols:
glEndQuery

References oglplus::EnumValueName(), and OGLPLUS_VERIFY.

template<typename ResultType >
Execution<ResultType> oglplus::QueryOps::Execute ( Target  target,
ResultType &  result 
) const
inherited

Executes the query on the specified target and gets the result.

This function creates an instance of the Execution class which begins a query on the specified target when it is constructed and ends this query and gets its result when it is destroyed.

void oglplus::QueryOps::Result ( GLint &  result) const
inherited

Get the query result.

Related OpenGL symbols:
glGetQueryObject GL_QUERY_RESULT

References OGLPLUS_VERIFY.

Referenced by oglplus::QueryOps::WaitForResult().

void oglplus::QueryOps::Result ( GLuint &  result) const
inherited

Get the query result.

Related OpenGL symbols:
glGetQueryObject GL_QUERY_RESULT

References OGLPLUS_VERIFY.

void oglplus::QueryOps::Result ( GLint64 &  result) const
inherited

Get the query result.

Requires OpenGL 3.3 or the GL_ARB_timer_query extension.

Related OpenGL symbols:
glGetQueryObject GL_QUERY_RESULT

References OGLPLUS_VERIFY.

void oglplus::QueryOps::Result ( GLuint64 &  result) const
inherited

Get the query result.

Requires OpenGL 3.3 or the GL_ARB_timer_query extension.

Related OpenGL symbols:
glGetQueryObject GL_QUERY_RESULT

References OGLPLUS_VERIFY.

bool oglplus::QueryOps::ResultAvailable ( void  ) const
inherited

Returns true if the query result is available.

Related OpenGL symbols:
glGetQueryObject GL_QUERY_RESULT_AVAILABLE

References OGLPLUS_VERIFY.

Referenced by oglplus::QueryOps::WaitForResult().

void oglplus::QueryOps::Timestamp ( void  ) const
inherited

Do a timestamp query.

Related OpenGL symbols:
glQueryCounter GL_TIMESTAMP

References oglplus::QueryOps::Counter(), and oglplus::Timestamp.


The documentation for this class was generated from the following file:
  • /home/chochlik/devel/oglplus/include/oglplus/query.hpp

Copyright © 2010-2014 Matúš Chochlík, University of Žilina, Žilina, Slovakia.
<matus.chochlik -at- fri.uniza.sk>
<chochlik -at -gmail.com>
Documentation generated on Wed Apr 30 2014 by Doxygen (version 1.8.4).