altEngine
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Member Functions | Public Attributes | List of all members
Graphics Class Reference

#include <graphics.h>

Collaboration diagram for Graphics:
Collaboration graph
[legend]

Public Member Functions

 Graphics ()
 
void init (void *param1, void *param2)
 
bool error_check ()
 
void clear ()
 
void clear_color (vec3 &color)
 
void clear_multi ()
 
void cleardepth ()
 
void clearstencil ()
 
void Depth (bool flag)
 
void Blend (bool flag)
 
void BlendFuncDstColorOne ()
 
void BlendFuncDstColorZero ()
 
void BlendFuncOneOne ()
 
void BlendFuncZeroOne ()
 
void BlendFuncOneZero ()
 
void BlendFuncZeroOneMinusAlpha ()
 
void BlendFuncOneOneMinusAlpha ()
 
void BlendFuncDstColorOneMinusDstAlpha ()
 
void BlendFuncDstColorSrcAlpha ()
 
void BlendFuncOneMinusSrcAlphaSrcAlpha ()
 
void BlendFuncSrcAlphaOneMinusSrcAlpha ()
 
void BlendFuncOneAlpha ()
 
void BlendFuncZeroSrcColor ()
 
void BlendFuncDstColorSrcColor ()
 
void BlendFuncZeroSrcAlpha ()
 
void BlendFuncOneMinusDstColorZero ()
 
void BlendFuncOneSrcAlpha ()
 
void CullFace (int mode)
 
void Color (bool flag)
 
void DepthFunc (int op)
 
void Stencil (bool flag)
 
void StencilFunc (int op, int ref, unsigned int mask)
 
void StencilOp (int stencil_fail, int zfail, int zpass)
 
void TwoSidedStencilOp (int face, int stencil_fail, int zfail, int zpass)
 
void DrawText (const char *str, float x, float y)
 
void swap ()
 
void resize (const int width, const int height)
 
void destroy ()
 
void DrawArray (primitive_t primitive, int start_index, int start_vertex, unsigned int num_index, int num_verts)
 
void DrawArrayTri (int start_index, int start_vertex, unsigned int num_index, int num_verts)
 
void DrawArrayTriStrip (int start_index, int start_vertex, unsigned int num_index, int num_verts)
 
void DrawArrayLineStrip (int start_index, int start_vertex, unsigned int num_index, int num_verts)
 
void DrawArrayLine (int start_index, int start_vertex, unsigned int num_index, int num_verts)
 
void DrawArrayPoint (int start_index, int start_vertex, unsigned int num_index, int num_verts)
 
void CreateVertexArrayObject (unsigned int &vao)
 
void SelectVertexArrayObject (unsigned int vao)
 
void DeleteVertexArrayObject (unsigned int vao)
 
int CreateIndexBuffer (void *index_buffer, int num_index)
 
void SelectIndexBuffer (int handle)
 
void DeleteIndexBuffer (int handle)
 
int CreateVertexBuffer (void *vertex_buffer, int num_vertex, bool dynamic=false)
 
void SelectVertexBuffer (int handle)
 
void DeleteVertexBuffer (int handle)
 
void SelectTexture (int level, int index)
 
void SelectTextureArray (int level, int texObject)
 
void DeselectTexture (int level)
 
int CreateCubeMap ()
 
void SelectCubemap (int texObject)
 
int LoadTexture (int width, int height, int components, int format, void *bytes, bool clamp, int anisotropic)
 
int LoadTextureArray (int width, int height, int components, int format, void **bytes, bool clamp, int num_layer)
 
void DeleteTexture (int handle)
 
void SelectShader (int program)
 
int checkFramebuffer ()
 
int CreateFramebuffer (int width, int height, unsigned int &fbo, unsigned int &quad_tex, unsigned int &depth_tex, unsigned int &normal_depth, int multisample, bool twoattach)
 
void DeleteFrameBuffer (int fbo, int quad, int depth)
 
void fbAttachTexture (int texObj)
 
void fbAttachTextureOne (int texObj)
 
void fbAttachDepth (int texObj)
 
void bindFramebuffer (int fbo, int num_attach=1)
 
void GetDebugLog ()
 
 ~Graphics ()
 

Public Attributes

int width
 
int height
 
gpustat_t gpustat
 
Display * display
 
Window window
 
XFontStruct * font
 

Constructor & Destructor Documentation

Graphics::Graphics ( )
Graphics::~Graphics ( )

Member Function Documentation

void Graphics::bindFramebuffer ( int  fbo,
int  num_attach = 1 
)

Here is the caller graph for this function:

void Graphics::Blend ( bool  flag)

Here is the caller graph for this function:

void Graphics::BlendFuncDstColorOne ( )

Here is the caller graph for this function:

void Graphics::BlendFuncDstColorOneMinusDstAlpha ( )

Here is the caller graph for this function:

void Graphics::BlendFuncDstColorSrcAlpha ( )

Here is the caller graph for this function:

void Graphics::BlendFuncDstColorSrcColor ( )

Here is the caller graph for this function:

void Graphics::BlendFuncDstColorZero ( )

Here is the caller graph for this function:

void Graphics::BlendFuncOneAlpha ( )
void Graphics::BlendFuncOneMinusDstColorZero ( )

Here is the caller graph for this function:

void Graphics::BlendFuncOneMinusSrcAlphaSrcAlpha ( )

Here is the caller graph for this function:

void Graphics::BlendFuncOneOne ( )

Here is the caller graph for this function:

void Graphics::BlendFuncOneOneMinusAlpha ( )
void Graphics::BlendFuncOneSrcAlpha ( )

Here is the caller graph for this function:

void Graphics::BlendFuncOneZero ( )

Here is the caller graph for this function:

void Graphics::BlendFuncSrcAlphaOneMinusSrcAlpha ( )

Here is the caller graph for this function:

void Graphics::BlendFuncZeroOne ( )

Here is the caller graph for this function:

void Graphics::BlendFuncZeroOneMinusAlpha ( )
void Graphics::BlendFuncZeroSrcAlpha ( )

Here is the caller graph for this function:

void Graphics::BlendFuncZeroSrcColor ( )

Here is the caller graph for this function:

int Graphics::checkFramebuffer ( )
void Graphics::clear ( )

Here is the caller graph for this function:

void Graphics::clear_color ( vec3 color)

Here is the caller graph for this function:

void Graphics::clear_multi ( )
void Graphics::cleardepth ( )

Here is the caller graph for this function:

void Graphics::clearstencil ( )
void Graphics::Color ( bool  flag)

Here is the caller graph for this function:

int Graphics::CreateCubeMap ( )
int Graphics::CreateFramebuffer ( int  width,
int  height,
unsigned int &  fbo,
unsigned int &  quad_tex,
unsigned int &  depth_tex,
unsigned int &  normal_depth,
int  multisample,
bool  twoattach 
)

Here is the caller graph for this function:

int Graphics::CreateIndexBuffer ( void *  index_buffer,
int  num_index 
)

Here is the caller graph for this function:

void Graphics::CreateVertexArrayObject ( unsigned int &  vao)

Here is the caller graph for this function:

int Graphics::CreateVertexBuffer ( void *  vertex_buffer,
int  num_vertex,
bool  dynamic = false 
)

Here is the caller graph for this function:

void Graphics::CullFace ( int  mode)

Here is the caller graph for this function:

void Graphics::DeleteFrameBuffer ( int  fbo,
int  quad,
int  depth 
)

Here is the caller graph for this function:

void Graphics::DeleteIndexBuffer ( int  handle)

Here is the caller graph for this function:

void Graphics::DeleteTexture ( int  handle)

Here is the caller graph for this function:

void Graphics::DeleteVertexArrayObject ( unsigned int  vao)
void Graphics::DeleteVertexBuffer ( int  handle)

Here is the caller graph for this function:

void Graphics::Depth ( bool  flag)

Here is the caller graph for this function:

void Graphics::DepthFunc ( int  op)

Here is the caller graph for this function:

void Graphics::DeselectTexture ( int  level)
void Graphics::destroy ( )

Here is the caller graph for this function:

void Graphics::DrawArray ( primitive_t  primitive,
int  start_index,
int  start_vertex,
unsigned int  num_index,
int  num_verts 
)
void Graphics::DrawArrayLine ( int  start_index,
int  start_vertex,
unsigned int  num_index,
int  num_verts 
)
void Graphics::DrawArrayLineStrip ( int  start_index,
int  start_vertex,
unsigned int  num_index,
int  num_verts 
)
void Graphics::DrawArrayPoint ( int  start_index,
int  start_vertex,
unsigned int  num_index,
int  num_verts 
)
void Graphics::DrawArrayTri ( int  start_index,
int  start_vertex,
unsigned int  num_index,
int  num_verts 
)

Here is the caller graph for this function:

void Graphics::DrawArrayTriStrip ( int  start_index,
int  start_vertex,
unsigned int  num_index,
int  num_verts 
)

Here is the caller graph for this function:

void Graphics::DrawText ( const char *  str,
float  x,
float  y 
)
bool Graphics::error_check ( )
void Graphics::fbAttachDepth ( int  texObj)

Here is the caller graph for this function:

void Graphics::fbAttachTexture ( int  texObj)

Here is the caller graph for this function:

void Graphics::fbAttachTextureOne ( int  texObj)
void Graphics::GetDebugLog ( )

Here is the caller graph for this function:

void Graphics::init ( void *  param1,
void *  param2 
)

Here is the caller graph for this function:

int Graphics::LoadTexture ( int  width,
int  height,
int  components,
int  format,
void *  bytes,
bool  clamp,
int  anisotropic 
)

Here is the caller graph for this function:

int Graphics::LoadTextureArray ( int  width,
int  height,
int  components,
int  format,
void **  bytes,
bool  clamp,
int  num_layer 
)
void Graphics::resize ( const int  width,
const int  height 
)

Here is the caller graph for this function:

void Graphics::SelectCubemap ( int  texObject)
void Graphics::SelectIndexBuffer ( int  handle)

Here is the caller graph for this function:

void Graphics::SelectShader ( int  program)
void Graphics::SelectTexture ( int  level,
int  index 
)

Here is the caller graph for this function:

void Graphics::SelectTextureArray ( int  level,
int  texObject 
)
void Graphics::SelectVertexArrayObject ( unsigned int  vao)

Here is the caller graph for this function:

void Graphics::SelectVertexBuffer ( int  handle)

Here is the caller graph for this function:

void Graphics::Stencil ( bool  flag)

Here is the caller graph for this function:

void Graphics::StencilFunc ( int  op,
int  ref,
unsigned int  mask 
)

Here is the caller graph for this function:

void Graphics::StencilOp ( int  stencil_fail,
int  zfail,
int  zpass 
)

Here is the caller graph for this function:

void Graphics::swap ( )

Here is the caller graph for this function:

void Graphics::TwoSidedStencilOp ( int  face,
int  stencil_fail,
int  zfail,
int  zpass 
)

Here is the caller graph for this function:

Member Data Documentation

Display* Graphics::display
XFontStruct* Graphics::font
gpustat_t Graphics::gpustat
int Graphics::height
int Graphics::width
Window Graphics::window

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