| Flutter Impeller |

Public Types | Public Member Functions | Public Attributes | List of all members
impeller::GLProc< T > Struct Template Reference

`#include <proc_table_gles.h>`

## Public Types
using | GLFunctionType = T

## Public Member Functions
template<class... Args>
auto | operator() (Args &&... args) const
| Call the GL function with the appropriate parameters. Lookup the documentation for the GL function being called to understand the arguments and return types. The arguments types must match and will be type checked. More...
constexpr bool | IsAvailable () const
void | Reset ()

## Public Attributes
const char * | name = nullptr
GLFunctionType * | function = nullptr
PFNGLGETERRORPROC | error_fn = nullptr

## Detailed Description

### template<class T>
struct impeller::GLProc< T >

Definition at line 39 of file proc_table_gles.h.

## Member Typedef Documentation

## ◆ GLFunctionType

template<class T >

using impeller::GLProc< T >::GLFunctionType = T

Definition at line 40 of file proc_table_gles.h.

## Member Function Documentation

## ◆ IsAvailable()

template<class T >

constexpr bool impeller::GLProc< T >::IsAvailable | ( |  | ) | const
| inline constexpr

Definition at line 75 of file proc_table_gles.h.

75 { return function != nullptr; }

## ◆ operator()()

template<class T >
template<class... Args>

auto impeller::GLProc< T >::operator() | ( | Args &&... | args | ) | const
| inline

Call the GL function with the appropriate parameters. Lookup the documentation for the GL function being called to understand the arguments and return types. The arguments types must match and will be type checked.

Definition at line 65 of file proc_table_gles.h.

65 {
66 #ifdef IMPELLER_ERROR_CHECK_ALL_GL_CALLS
67 AutoErrorCheck error(error_fn, name);
68 #endif // IMPELLER_ERROR_CHECK_ALL_GL_CALLS
69 #ifdef IMPELLER_TRACE_ALL_GL_CALLS
70 TRACE_EVENT0("impeller", name);
71 #endif // IMPELLER_TRACE_ALL_GL_CALLS
72 return function(std::forward<Args>(args)...);
73 }

References impeller::GLProc< T >::error_fn, and impeller::GLProc< T >::name.

## ◆ Reset()

template<class T >

void impeller::GLProc< T >::Reset | ( |  | ) |
| inline

Definition at line 77 of file proc_table_gles.h.

77 {
78 name = nullptr;
79 function = nullptr;
80 error_fn = nullptr;
81 }

References impeller::GLProc< T >::error_fn, and impeller::GLProc< T >::name.

## Member Data Documentation

## ◆ error_fn

template<class T >

PFNGLGETERRORPROC impeller::GLProc< T >::error_fn = nullptr

An optional error function. If present, all calls will be followed by an error check.

Definition at line 56 of file proc_table_gles.h.

Referenced by impeller::GLProc< T >::operator()(), and impeller::GLProc< T >::Reset().

## ◆ function

template<class T >

GLFunctionType* impeller::GLProc< T >::function = nullptr

The pointer to the GL function.

Definition at line 50 of file proc_table_gles.h.

## ◆ name

template<class T >

const char* impeller::GLProc< T >::name = nullptr

The name of the GL function.

Definition at line 45 of file proc_table_gles.h.

Referenced by impeller::GLProc< T >::operator()(), and impeller::GLProc< T >::Reset().

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

- impeller/renderer/backend/gles/proc_table_gles.h

impeller::GLProc::error_fn
PFNGLGETERRORPROC error_fn
Definition: proc_table_gles.h:56
impeller::GLProc::name
const char * name
Definition: proc_table_gles.h:45