Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   Related Pages  

sgl Class Reference

#include <sgl.h>

List of all members.

Public Types

enum  CompressionVendor {
  eCOMPRESSION_VENDOR_ARB,
  eCOMPRESSION_VENDOR_S3
}

Public Methods

typedef void (APIENTRY *multiTexCoordFunc)(GLenum, const GLfloat *)

Static Public Methods

void initialize (ostream *default_stream=&cout)
GLuint getDisplayList ()
void releaseDisplayList (GLuint dlist)
void deleteUnusedDisplayLists ()
GLuint getTextureObj ()
void releaseTextureObj (GLuint tex_obj)
void deleteUnusedTextureObjs ()
unsigned int nextPower2 (unsigned int val)
void* getDLLHandle (const char *dll_name)
void* getFuncPtr (void *dll, const char *func_name)
void* getGLFuncPtr (const char *func_name)
 void (APIENTRY *drawRangeElements)(GLenum, GLuint, GLuint, GLsizei, GLenum, const GLvoid *)
 void (APIENTRY *setActiveTextureUnit)(GLenum)
 void (APIENTRY *setClientActiveTextureUnit)(GLenum)
multiTexCoordFunc getMultiTexFunc (const char *type)
 void (APIENTRY *compressedTexImage2D)(GLenum, GLint, GLenum, GLsizei, GLsizei, GLint, GLsizei, const GLvoid *)
 void (APIENTRY *getCompressedTexImage)(GLenum, GLint, GLvoid *)
 void (APIENTRY *pointParameterf)(GLenum, GLfloat)
 void (APIENTRY *pointParameterfv)(GLenum, GLfloat *)

Static Public Attributes

bool s_initialized
GLint s_max_prefetch_indices
GLint s_max_prefetch_vertices
GLint s_max_texture_size
GLint s_clamp_to_edge
GLenum s_rescale_normal
float s_max_texture_max_anisotropy
GLint s_num_texture_units
multiTexCoordFunc multiTexCoord1sv
multiTexCoordFunc multiTexCoord2sv
multiTexCoordFunc multiTexCoord3sv
multiTexCoordFunc multiTexCoord4sv
multiTexCoordFunc multiTexCoord1iv
multiTexCoordFunc multiTexCoord2iv
multiTexCoordFunc multiTexCoord3iv
multiTexCoordFunc multiTexCoord4iv
multiTexCoordFunc multiTexCoord1fv
multiTexCoordFunc multiTexCoord2fv
multiTexCoordFunc multiTexCoord3fv
multiTexCoordFunc multiTexCoord4fv
multiTexCoordFunc multiTexCoord1dv
multiTexCoordFunc multiTexCoord2dv
multiTexCoordFunc multiTexCoord3dv
multiTexCoordFunc multiTexCoord4dv
unsigned int s_num_statelet_types
GLenum s_stencil_inc_wrap
GLenum s_stencil_dec_wrap
GLint s_num_stencil_bits
bool s_multisample_capable
bool s_texture_env_add_capable
bool s_texture_env_combine_capable
bool s_texture_env_dot3_capable
bool s_occlusion_capable
GLenum s_occlusion_enable_flag
GLenum s_occlusion_result_flag
bool s_texture_compression_capable
CompressionVendor s_texture_compression_vendor
bool s_auto_mipmap_capable
GLenum s_auto_mipmap_enable_flag
bool s_texture_lod_bias_capable
float s_max_texture_lod_bias
bool s_texture_lod_capable
bool s_fog_distance_capable
bool s_point_parameters_capable
float s_point_default_size_min
float s_point_default_size_max
float s_point_default_fade_threshold
bool s_texture_cube_map_capable
GLint s_max_cube_map_texture_size
GLint s_max_lights

Protected Methods

 sgl ()
 ~sgl ()


Detailed Description

NEED CLASS DESCRIPTION HERE.

Several environment variable can affect the runtime behavior of sgl. SGL_DATA_PATH - Defines the search path that sgl will use by default when loading data files. SGL_DISABLE_HARDWARE_MIPMAP - When set forces sgl to use a software algorithm for computing texture mipmaps. This may be necessary on machines with a broken implementation of the GL_EXT_generate_mipmap extension. SGL_DISABLE_VERTEX_PREFETCH - When set prevents sgl from using the glDrawRangeElements functions in the draw routines. SGL_NUM_TEXTURE_UNITS - When set sgl will use the lesser of the number automatically detected texture units and the value of the environment variable.

Definition at line 198 of file sgl.h.


Constructor & Destructor Documentation

sgl::sgl ( ) [protected]
 

Not implemented. Don't use.

sgl::~sgl ( ) [protected]
 

Not implemented. Don't use.


Member Function Documentation

void sgl::initialize ( ostream * default_stream = &cout ) [static]
 

This function should be called before any drawing is done with sgl. NOTE: a valid graphics context _must_ be made current before calling this function.

Parameters:
default_stream   the ostream to use with sglPrint() output

GLuint sgl::getDisplayList ( ) [static]
 

This function will allocate a new display list for use. NOTE: a valid graphics context _must_ be made current before calling this function.

Returns:
a new display list

void sgl::releaseDisplayList ( GLuint dlist ) [static]
 

This function will schedule the given display list for deletion.

Parameters:
dlist   display list to delete

void sgl::deleteUnusedDisplayLists ( ) [static]
 

This function should be called every once in a while to delete unused display lists. The preDraw() method of sglScene calls this function. NOTE: a valid graphics context _must_ be made current before calling this function.

GLuint sgl::getTextureObj ( ) [static]
 

This function will allocate a new texture object for use. NOTE: a valid graphics context _must_ be made current before calling this function.

Returns:
a new texture object

void sgl::releaseTextureObj ( GLuint tex_obj ) [static]
 

This function will schedule the given texture object for deletion.

Parameters:
tex_obj   texture object to delete

void sgl::deleteUnusedTextureObjs ( ) [static]
 

This function should be called every once in a while to delete unused texture objects. The preDraw() method of sglScene calls this function. NOTE: a valid graphics context _must_ be made current before calling this function.

unsigned int sgl::nextPower2 ( unsigned int val ) [static]
 

Gets the power of 2 that is greater or equal to the given value.

Parameters:
val   input value
Returns:
a power of 2 that is greater or equal to val

void* sgl::getDLLHandle ( const char * dll_name ) [static]
 

Loads a dynamically loadable library with the given name. Note that the true name of the dll actually loaded is system dependent: libdll_name.so on unix vs dll_name.dll on WIN32.

Parameters:
dll_name   name of dll to load
Returns:
a handle to the dll, or NULL if dll is not found

void* sgl::getFuncPtr ( void * dll,
const char * func_name ) [static]
 

Gets a pointer to a function in the given dll.

Parameters:
dll   handle to the dll to load from
func_name   name of the function to find
Returns:
function pointer, or NULL if function is not found

void* sgl::getGLFuncPtr ( const char * func_name ) [static]
 

Gets a pointer to a function in the opengl library.

Parameters:
func_name   name of the function to find
Returns:
function pointer, or NULL if function is not found


The documentation for this class was generated from the following file:
Generated at Mon Jul 1 18:00:10 2002 for SGL by doxygen1.2.6 written by Dimitri van Heesch, © 1997-2001