RenderTools::ShadowProxy Class Reference

#include <ShadowProxy.h>

List of all members.

Public Types

enum  ProxyType { CYLINDER, SPHERE, BOX }

Public Member Functions

virtual const string getTypeName (bool ofComponent=false) const
const int getType (void) const
Vec3 getSize (const Vec3 &offset=Vec3()) const
void setSize (const Vec3 &size)
void setColor (const Vec3 &color)
const Vec3getColor (void) const
const Mat4getLocal (void) const
AABB getAABB (const Vec3 &offset=Vec3())
const RendernodePtr getAssociatedRendernode (void) const
void render (void)

Static Public Member Functions

static PropertyPtr create (const XMLNodePtr &xml=XMLNodePtr())
static void createProperties (void)
static void onInitialize (void)
static void setCamera (const CameraPtr camera)
static ShadowProxyPtr addProxy (ProxyType type, const Vec3 &size, const Vec3 &color, const RendernodePtr node, const Mat4 &matrix)
static void project (void)
static void render (bool showGrid)
static SamplerPtr getMap (void)
static Vec2 getMapSize (void)
static Vec2 getMapSize2 (void)
static Vec2 getGridSize (void)
static void deleteAssociatedProxies (const RendernodePtr node)
static void deleteAssociatedProxies (string path)
static int retrieveIndex (const RendernodePtr node)
static CameraPtr getAssociatedCamera (void)


Detailed Description

Definition at line 14 of file ShadowProxy.h.


Member Enumeration Documentation

Enumerator:
CYLINDER 
SPHERE 
BOX 

Definition at line 17 of file ShadowProxy.h.


Member Function Documentation

ShadowProxyPtr RenderTools::ShadowProxy::addProxy ( ProxyType  type,
const Vec3 size,
const Vec3 color,
const RendernodePtr  node,
const Mat4 matrix 
) [static]

Definition at line 64 of file ShadowProxy.cpp.

PropertyPtr RenderTools::ShadowProxy::create ( const XMLNodePtr xml = XMLNodePtr()  )  [static]

Definition at line 30 of file ShadowProxy.cpp.

static void RenderTools::ShadowProxy::createProperties ( void   )  [static]

void RenderTools::ShadowProxy::deleteAssociatedProxies ( string  path  )  [static]

Definition at line 256 of file ShadowProxy.cpp.

void RenderTools::ShadowProxy::deleteAssociatedProxies ( const RendernodePtr  node  )  [static]

Definition at line 246 of file ShadowProxy.cpp.

AABB RenderTools::ShadowProxy::getAABB ( const Vec3 offset = Vec3()  ) 

Definition at line 475 of file ShadowProxy.cpp.

static CameraPtr RenderTools::ShadowProxy::getAssociatedCamera ( void   )  [static]

const RendernodePtr RenderTools::ShadowProxy::getAssociatedRendernode ( void   )  const

Definition at line 479 of file ShadowProxy.cpp.

const Vec3 & RenderTools::ShadowProxy::getColor ( void   )  const

Definition at line 467 of file ShadowProxy.cpp.

Vec2 RenderTools::ShadowProxy::getGridSize ( void   )  [static]

Definition at line 60 of file ShadowProxy.cpp.

const Mat4 & RenderTools::ShadowProxy::getLocal ( void   )  const

Definition at line 471 of file ShadowProxy.cpp.

SamplerPtr RenderTools::ShadowProxy::getMap ( void   )  [static]

Definition at line 48 of file ShadowProxy.cpp.

Vec2 RenderTools::ShadowProxy::getMapSize ( void   )  [static]

Definition at line 52 of file ShadowProxy.cpp.

Vec2 RenderTools::ShadowProxy::getMapSize2 ( void   )  [static]

Definition at line 56 of file ShadowProxy.cpp.

Vec3 RenderTools::ShadowProxy::getSize ( const Vec3 offset = Vec3()  )  const

Definition at line 459 of file ShadowProxy.cpp.

const int RenderTools::ShadowProxy::getType ( void   )  const

Definition at line 455 of file ShadowProxy.cpp.

const string RenderTools::ShadowProxy::getTypeName ( bool  ofComponent = false  )  const [virtual]

Definition at line 44 of file ShadowProxy.cpp.

void RenderTools::ShadowProxy::onInitialize ( void   )  [static]

the number of gridcells in the viewport (cellsize 16)

the minimum size of the map to accomodate for the cells as they are 3x3 pixels and can hold 3x3x4 individual proxies

the power-of-two texture size

the actual cell size

associate the sampler with the uniform

associate the map sizes with the uniforms

Definition at line 74 of file ShadowProxy.cpp.

void RenderTools::ShadowProxy::project ( void   )  [static]

get the offset uniform, we HAVE to have a valid active rendergroup

and the proxyOffset uniform MUST be declared

if we have all that, we get the offset values TODO: fix this ! a string is not a stream(!)

Todo:
eliminate cells not covered by the convex hull of the projected box

TODO: add the warped proxies !

Definition at line 150 of file ShadowProxy.cpp.

void RenderTools::ShadowProxy::render ( void   ) 

Definition at line 483 of file ShadowProxy.cpp.

void RenderTools::ShadowProxy::render ( bool  showGrid  )  [static]

Definition at line 275 of file ShadowProxy.cpp.

int RenderTools::ShadowProxy::retrieveIndex ( const RendernodePtr  node  )  [static]

Definition at line 266 of file ShadowProxy.cpp.

void RenderTools::ShadowProxy::setCamera ( const CameraPtr  camera  )  [static]

Definition at line 70 of file ShadowProxy.cpp.

void RenderTools::ShadowProxy::setColor ( const Vec3 color  ) 

void RenderTools::ShadowProxy::setSize ( const Vec3 size  ) 

Definition at line 463 of file ShadowProxy.cpp.


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

Generated on Wed Jan 26 00:15:37 2011 for RenderTools by  doxygen 1.5.8