OpenGL ES SDK for Android ARM Developer Center
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
HiZCulling Class Reference

#include <culling.hpp>

Inheritance diagram for HiZCulling:
CullingInterface HiZCullingNoLOD

Classes

struct  Uniforms
 

Public Member Functions

 HiZCulling ()
 
 HiZCulling (const char *program)
 
 ~HiZCulling ()
 
void setup_occluder_geometry (const std::vector< vec4 > &positions, const std::vector< uint32_t > &indices)
 
void set_view_projection (const mat4 &projection, const mat4 &view, const vec2 &zNearFar)
 
void rasterize_occluders ()
 
void test_bounding_boxes (GLuint counter_buffer, const unsigned *counter_offsets, unsigned num_offsets, const GLuint *culled_instance_buffer, GLuint instance_data_buffer, unsigned num_instances)
 
GLuint get_depth_texture () const
 
- Public Member Functions inherited from CullingInterface
virtual ~CullingInterface ()
 
virtual unsigned get_num_lods () const
 

Private Member Functions

void init ()
 

Private Attributes

GLuint depth_render_program
 
GLuint depth_mip_program
 
GLuint culling_program
 
GLDrawable quad
 
struct {
   GLuint   vertex
 
   GLuint   index
 
   GLuint   vao
 
   unsigned   elements
 
occluder
 
GLuint depth_texture
 
GLuint shadow_sampler
 
unsigned lod_levels
 
std::vector< GLuintframebuffers
 
GLuint uniform_buffer
 
Uniforms uniforms
 

Additional Inherited Members

- Protected Member Functions inherited from CullingInterface
void compute_frustum_from_view_projection (vec4 *planes, const mat4 &view_projection)
 

Detailed Description

Definition at line 71 of file culling.hpp.

Constructor & Destructor Documentation

HiZCulling::HiZCulling ( )

Definition at line 28 of file hizculling.cpp.

HiZCulling::HiZCulling ( const char *  program)

Definition at line 34 of file hizculling.cpp.

HiZCulling::~HiZCulling ( )

Definition at line 216 of file hizculling.cpp.

Member Function Documentation

GLuint HiZCulling::get_depth_texture ( ) const
inlinevirtual

Reimplemented from CullingInterface.

Definition at line 86 of file culling.hpp.

void HiZCulling::init ( )
private

Definition at line 40 of file hizculling.cpp.

void HiZCulling::rasterize_occluders ( )
virtual

Implements CullingInterface.

Definition at line 163 of file hizculling.cpp.

void HiZCulling::set_view_projection ( const mat4 projection,
const mat4 view,
const vec2 zNearFar 
)
virtual

Implements CullingInterface.

Definition at line 202 of file hizculling.cpp.

void HiZCulling::setup_occluder_geometry ( const std::vector< vec4 > &  positions,
const std::vector< uint32_t > &  indices 
)
virtual

Implements CullingInterface.

Definition at line 142 of file hizculling.cpp.

void HiZCulling::test_bounding_boxes ( GLuint  counter_buffer,
const unsigned *  counter_offsets,
unsigned  num_offsets,
const GLuint culled_instance_buffer,
GLuint  instance_data_buffer,
unsigned  num_instances 
)
virtual

Implements CullingInterface.

Definition at line 105 of file hizculling.cpp.

Member Data Documentation

GLuint HiZCulling::culling_program
private

Definition at line 91 of file culling.hpp.

GLuint HiZCulling::depth_mip_program
private

Definition at line 90 of file culling.hpp.

GLuint HiZCulling::depth_render_program
private

Definition at line 89 of file culling.hpp.

GLuint HiZCulling::depth_texture
private

Definition at line 103 of file culling.hpp.

unsigned HiZCulling::elements

Definition at line 100 of file culling.hpp.

std::vector<GLuint> HiZCulling::framebuffers
private

Definition at line 106 of file culling.hpp.

GLuint HiZCulling::index

Definition at line 98 of file culling.hpp.

unsigned HiZCulling::lod_levels
private

Definition at line 105 of file culling.hpp.

struct { ... } HiZCulling::occluder
GLDrawable HiZCulling::quad
private

Definition at line 93 of file culling.hpp.

GLuint HiZCulling::shadow_sampler
private

Definition at line 104 of file culling.hpp.

GLuint HiZCulling::uniform_buffer
private

Definition at line 108 of file culling.hpp.

Uniforms HiZCulling::uniforms
private

Definition at line 117 of file culling.hpp.

GLuint HiZCulling::vao

Definition at line 99 of file culling.hpp.

GLuint HiZCulling::vertex

Definition at line 97 of file culling.hpp.


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