Support Forum       G3D Web Page     
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
G3D::RefractionHint Class Reference

Values for UniversalSurface::GPUGeom::refractionHint. More...

Public Types

enum  Value {
  NONE,
  DYNAMIC_FLAT,
  DYNAMIC_FLAT_OIT,
  RAY_TRACE
}
 

Public Member Functions

 RefractionHint (const G3D::String &x)
 
 RefractionHint (char v)
 
 RefractionHint (int v)
 
 RefractionHint (const G3D::Any &a)
 
 RefractionHint ()
 
 RefractionHint (const Value v)
 
void deserialize (G3D::BinaryInput &b)
 
unsigned int hashCode () const
 
 operator int () const
 
bool operator!= (const RefractionHint ::Value other) const
 
bool operator!= (const RefractionHint other) const
 
RefractionHint operator+ (const int x) const
 
RefractionHintoperator++ ()
 
RefractionHintoperator+= (const int x)
 
RefractionHint operator- (const int x) const
 
RefractionHintoperator-- ()
 
RefractionHintoperator-= (const int x)
 
bool operator< (const RefractionHint other) const
 
bool operator< (const Value other) const
 
bool operator<= (const Value other) const
 
bool operator<= (const RefractionHint other) const
 
RefractionHintoperator= (const G3D::Any &a)
 
bool operator== (const RefractionHint ::Value other) const
 
bool operator== (const RefractionHint other) const
 
bool operator> (const RefractionHint other) const
 
bool operator> (const Value other) const
 
bool operator>= (const RefractionHint other) const
 
bool operator>= (const Value other) const
 
void serialize (G3D::BinaryOutput &b) const
 
G3D::Any toAny () const
 
const char * toString () const
 

Static Public Member Functions

static const char * classname ()
 
static int count ()
 
static Value nthValue (int n)
 
static const char * toString (int i, Value &v)
 

Public Attributes

enum G3D::RefractionHint::Value value
 

Detailed Description

Values for UniversalSurface::GPUGeom::refractionHint.

Member Enumeration Documentation

◆ Value

Enumerator
NONE 

No refraction; a translucent object will appear as if it had the same index of refraction as the surrounding medium and objects will be undistorted in the background.

DYNAMIC_FLAT 

Use a static environment map (cube or paraboloid) for computing transmissivity.

Use a dynamically rendered 2D environment map; distort the background. This looks good for many scenes but avoids the cost of rendering a cube map for DYNAMIC_ENV. UniversalSurface considers this hint to mean that blending is not required, so G3D::Renderer::cullAndSort will categorize UniversalSurface with this hint as opaque and a G3D::Renderer will send them to the RenderPassType::UNBLENDED_SCREEN_SPACE_REFRACTION_SAMPLES pass.

DYNAMIC_FLAT_OIT 

Combine DYNAMIC_FLAT mode with order-independent transparency.

UniversalSurface considers this hint to require blending, so G3D::Renderer::cullAndSort will categorize send UniversalSurface with this hint as transparent and a Renderer will then send them to the RenderPassType::SINGLE_PASS_UNORDERED_BLENDED_SAMPLES pass.

See also
DefaultRenderer::setOrderIndependentTransparency
DefaultRenderer::cullAndSort
RAY_TRACE 

Use a dynamically rendered 2D environment map that is re-captured per transparent object.

This works well for transparent objects that are separated by a significant camera space z distance but overlap in screen space. Render a dynamic environment map True ray tracing.

Constructor & Destructor Documentation

◆ RefractionHint() [1/6]

G3D::RefractionHint::RefractionHint ( const G3D::String x)
inlineexplicit

◆ RefractionHint() [2/6]

G3D::RefractionHint::RefractionHint ( const G3D::Any a)
inlineexplicit

◆ RefractionHint() [3/6]

G3D::RefractionHint::RefractionHint ( char  v)
inlineexplicit

◆ RefractionHint() [4/6]

G3D::RefractionHint::RefractionHint ( )
inline

◆ RefractionHint() [5/6]

G3D::RefractionHint::RefractionHint ( const Value  v)
inline

◆ RefractionHint() [6/6]

G3D::RefractionHint::RefractionHint ( int  v)
inlineexplicit

Member Function Documentation

◆ classname()

static const char* G3D::RefractionHint::classname ( )
inlinestatic

◆ count()

static int G3D::RefractionHint::count ( )
inlinestatic

◆ deserialize()

void G3D::RefractionHint::deserialize ( G3D::BinaryInput b)
inline

◆ hashCode()

unsigned int G3D::RefractionHint::hashCode ( ) const
inline

◆ nthValue()

static Value G3D::RefractionHint::nthValue ( int  n)
inlinestatic

◆ operator int()

G3D::RefractionHint::operator int ( ) const
inline

◆ operator!=() [1/2]

bool G3D::RefractionHint::operator!= ( const RefractionHint  other) const
inline

◆ operator!=() [2/2]

bool G3D::RefractionHint::operator!= ( const RefractionHint ::Value  other) const
inline

◆ operator+()

RefractionHint G3D::RefractionHint::operator+ ( const int  x) const
inline

◆ operator++()

RefractionHint& G3D::RefractionHint::operator++ ( )
inline

◆ operator+=()

RefractionHint& G3D::RefractionHint::operator+= ( const int  x)
inline

◆ operator-()

RefractionHint G3D::RefractionHint::operator- ( const int  x) const
inline

◆ operator--()

RefractionHint& G3D::RefractionHint::operator-- ( )
inline

◆ operator-=()

RefractionHint& G3D::RefractionHint::operator-= ( const int  x)
inline

◆ operator<() [1/2]

bool G3D::RefractionHint::operator< ( const Value  other) const
inline

◆ operator<() [2/2]

bool G3D::RefractionHint::operator< ( const RefractionHint  other) const
inline

◆ operator<=() [1/2]

bool G3D::RefractionHint::operator<= ( const RefractionHint  other) const
inline

◆ operator<=() [2/2]

bool G3D::RefractionHint::operator<= ( const Value  other) const
inline

◆ operator=()

RefractionHint& G3D::RefractionHint::operator= ( const G3D::Any a)
inline

◆ operator==() [1/2]

bool G3D::RefractionHint::operator== ( const RefractionHint ::Value  other) const
inline

◆ operator==() [2/2]

bool G3D::RefractionHint::operator== ( const RefractionHint  other) const
inline

◆ operator>() [1/2]

bool G3D::RefractionHint::operator> ( const RefractionHint  other) const
inline

◆ operator>() [2/2]

bool G3D::RefractionHint::operator> ( const Value  other) const
inline

◆ operator>=() [1/2]

bool G3D::RefractionHint::operator>= ( const RefractionHint  other) const
inline

◆ operator>=() [2/2]

bool G3D::RefractionHint::operator>= ( const Value  other) const
inline

◆ serialize()

void G3D::RefractionHint::serialize ( G3D::BinaryOutput b) const
inline

◆ toAny()

G3D::Any G3D::RefractionHint::toAny ( ) const
inline

◆ toString() [1/2]

const char* G3D::RefractionHint::toString ( ) const
inline

◆ toString() [2/2]

static const char* G3D::RefractionHint::toString ( int  i,
Value v 
)
inlinestatic

Member Data Documentation

◆ value

enum G3D::RefractionHint::Value G3D::RefractionHint::value

documentation generated on Wed Nov 24 2021 08:01:59 using doxygen 1.8.15