#include <eggRenderMode.h>
Inheritance diagram for EggRenderMode:
Public Types | |
enum | AlphaMode { AM_unspecified, AM_off, AM_on, AM_blend, AM_blend_no_occlude, AM_ms, AM_ms_mask, AM_binary, AM_dual } |
enum | DepthWriteMode { DWM_unspecified, DWM_off, DWM_on } |
enum | DepthTestMode { DTM_unspecified, DTM_off, DTM_on } |
Public Member Functions | |
EggRenderMode () | |
EggRenderMode (const EggRenderMode ©) | |
EggRenderMode & | operator= (const EggRenderMode ©) |
void | write (ostream &out, int indent_level) const |
Writes the attributes to the indicated output stream in Egg format. | |
void | set_alpha_mode (AlphaMode mode) |
Specifies precisely how the transparency for this geometry should be achieved, or if it should be used. | |
AlphaMode | get_alpha_mode () const |
Returns the alpha mode that was set, or AM_unspecified if nothing was set. | |
void | set_depth_write_mode (DepthWriteMode mode) |
Specifies whether writes should be made to the depth buffer (assuming the rendering backend provides a depth buffer) when rendering this geometry. | |
DepthWriteMode | get_depth_write_mode () const |
Returns the depth_write mode that was set, or DWM_unspecified if nothing was set. | |
void | set_depth_test_mode (DepthTestMode mode) |
Specifies whether this geometry should be tested against the depth buffer when it is drawn (assuming the rendering backend provides a depth buffer). | |
DepthTestMode | get_depth_test_mode () const |
Returns the depth_test mode that was set, or DTM_unspecified if nothing was set. | |
void | set_draw_order (int order) |
Sets the "draw-order" flag associated with this object. | |
int | get_draw_order () const |
Returns the "draw-order" flag as set for this particular object. | |
bool | has_draw_order () const |
Returns true if the draw-order flag has been set for this particular object. | |
void | clear_draw_order () |
Removes the draw-order flag from this particular object. | |
void | set_bin (const string &bin) |
Sets the "bin" string for this particular object. | |
string | get_bin () const |
Returns the bin name that has been set for this particular object, if any. | |
bool | has_bin () const |
Returns true if a bin name has been set for this particular object. | |
void | clear_bin () |
Removes the bin name that was set for this particular object. | |
bool | operator== (const EggRenderMode &other) const |
bool | operator!= (const EggRenderMode &other) const |
bool | operator< (const EggRenderMode &other) const |
Static Public Member Functions | |
AlphaMode | string_alpha_mode (const string &string) |
Returns the AlphaMode value associated with the given string representation, or AM_unspecified if the string does not match any known AlphaMode value. | |
DepthWriteMode | string_depth_write_mode (const string &string) |
Returns the DepthWriteMode value associated with the given string representation, or DWM_unspecified if the string does not match any known DepthWriteMode value. | |
DepthTestMode | string_depth_test_mode (const string &string) |
Returns the DepthTestMode value associated with the given string representation, or DWM_unspecified if the string does not match any known DepthTestMode value. | |
TypeHandle | get_class_type () |
void | init_type () |
Private Attributes | |
AlphaMode | _alpha_mode |
DepthWriteMode | _depth_write_mode |
DepthTestMode | _depth_test_mode |
int | _draw_order |
bool | _has_draw_order |
string | _bin |
Static Private Attributes | |
TypeHandle | _type_handle |
It's intended to be a base class for egg objects that can have these properties set.
This class cannot inherit from EggObject, because it causes problems at the EggPolygon level with multiple appearances of the EggObject base class. And making EggObject a virtual base class is just no fun.
Definition at line 56 of file eggRenderMode.h.
|
Definition at line 64 of file eggRenderMode.h. |
|
Definition at line 80 of file eggRenderMode.h. Referenced by get_depth_write_mode(), and EggLoader::setup_bucket(). |
|
Definition at line 76 of file eggRenderMode.h. |
|
Definition at line 31 of file eggRenderMode.I. References _has_draw_order. |
|
Definition at line 48 of file eggRenderMode.I. References _alpha_mode, _depth_test_mode, _depth_write_mode, _draw_order, _has_draw_order, and INLINE. |
|
Removes the bin name that was set for this particular object. See set_bin(). Definition at line 326 of file eggRenderMode.I. |
|
Removes the draw-order flag from this particular object. See set_draw_order(). Definition at line 254 of file eggRenderMode.I. |
|
Returns the alpha mode that was set, or AM_unspecified if nothing was set. See set_alpha_mode(). Definition at line 186 of file eggRenderMode.I. References _has_draw_order, and INLINE. |
|
Returns the bin name that has been set for this particular object, if any. See set_bin(). Definition at line 296 of file eggRenderMode.I. |
|
Reimplemented in EggBin, EggCurve, EggGroup, EggNurbsCurve, EggNurbsSurface, EggPoint, EggPolygon, EggPrimitive, EggSurface, and EggTexture. Definition at line 122 of file eggRenderMode.h. |
|
Returns the depth_test mode that was set, or DTM_unspecified if nothing was set. Definition at line 138 of file eggRenderMode.I. References _alpha_mode. Referenced by EggGroup::determine_alpha_mode(), and EggPrimitive::determine_depth_write_mode(). |
|
Returns the depth_write mode that was set, or DWM_unspecified if nothing was set. Definition at line 100 of file eggRenderMode.I. References _depth_test_mode, DepthTestMode, and INLINE. |
|
Returns the "draw-order" flag as set for this particular object. See set_draw_order(). Definition at line 224 of file eggRenderMode.I. |
|
Returns true if a bin name has been set for this particular object. See set_bin(). Definition at line 311 of file eggRenderMode.I. Referenced by EggGroup::determine_depth_write_mode(). |
|
Returns true if the draw-order flag has been set for this particular object. See set_draw_order(). Definition at line 239 of file eggRenderMode.I. Referenced by EggPrimitive::determine_depth_test_mode(). |
|
Reimplemented in EggBin, EggCurve, EggGroup, EggNurbsCurve, EggNurbsSurface, EggPoint, EggPolygon, EggPrimitive, EggSurface, and EggTexture. Definition at line 125 of file eggRenderMode.h. |
|
Definition at line 338 of file eggRenderMode.I. |
|
Definition at line 100 of file eggRenderMode.cxx. References _has_draw_order. |
|
Definition at line 60 of file eggRenderMode.I. References _depth_write_mode, and INLINE. Referenced by EggTexture::EggTexture(). |
|
Definition at line 71 of file eggRenderMode.cxx. References _draw_order. |
|
Specifies precisely how the transparency for this geometry should be achieved, or if it should be used. The default, AM_unspecified, is to use transparency if the geometry has a color whose alpha value is non-1, or if it has a four-channel texture applied; otherwise, AM_on forces transparency on, and AM_off forces it off. The other flavors of transparency are specific ways to turn on transparency, which may or may not be supported by a particular rendering backend. Definition at line 169 of file eggRenderMode.I. References _has_draw_order, and INLINE. |
|
Sets the "bin" string for this particular object. This names a particular bin in which the object should be rendered. The exact meaning of a bin is implementation defined, but generally a GeomBin matching each bin name must also be specifically added to the rendering engine (e.g. the CullTraverser) in use for this to work. See also set_draw_order(). Definition at line 281 of file eggRenderMode.I. |
|
Specifies whether this geometry should be tested against the depth buffer when it is drawn (assuming the rendering backend provides a depth buffer). Note that this is different, and independent from, the depth_write mode. Definition at line 121 of file eggRenderMode.I. References _alpha_mode, and INLINE. |
|
Specifies whether writes should be made to the depth buffer (assuming the rendering backend provides a depth buffer) when rendering this geometry.
Definition at line 83 of file eggRenderMode.I. |
|
Sets the "draw-order" flag associated with this object. This specifies a particular order in which objects of this type should be drawn, within the specified bin. If a bin is not explicitly specified, "fixed" is used. See also set_bin(). Definition at line 208 of file eggRenderMode.I. |
|
Returns the AlphaMode value associated with the given string representation, or AM_unspecified if the string does not match any known AlphaMode value.
Definition at line 141 of file eggRenderMode.cxx. References AM_dual. |
|
Returns the DepthTestMode value associated with the given string representation, or DWM_unspecified if the string does not match any known DepthTestMode value.
Definition at line 203 of file eggRenderMode.cxx. References AM_binary, AM_dual, and AM_ms_mask. |
|
Returns the DepthWriteMode value associated with the given string representation, or DWM_unspecified if the string does not match any known DepthWriteMode value.
Definition at line 178 of file eggRenderMode.cxx. |
|
Writes the attributes to the indicated output stream in Egg format.
Reimplemented in EggGroup, EggNurbsCurve, EggNurbsSurface, EggPoint, EggPolygon, and EggTexture. Definition at line 40 of file eggRenderMode.cxx. |
|
Definition at line 113 of file eggRenderMode.h. Referenced by EggRenderMode(), get_depth_test_mode(), and set_depth_test_mode(). |
|
Definition at line 118 of file eggRenderMode.h. Referenced by get_draw_order(), and set_draw_order(). |
|
Definition at line 115 of file eggRenderMode.h. Referenced by EggRenderMode(), and get_depth_write_mode(). |
|
Definition at line 114 of file eggRenderMode.h. Referenced by EggRenderMode(), and operator=(). |
|
Definition at line 116 of file eggRenderMode.h. Referenced by EggRenderMode(), and operator==(). |
|
Definition at line 117 of file eggRenderMode.h. Referenced by EggRenderMode(), get_alpha_mode(), operator<(), and set_alpha_mode(). |
|
Reimplemented in EggBin, EggCurve, EggGroup, EggNurbsCurve, EggNurbsSurface, EggPoint, EggPolygon, EggPrimitive, EggSurface, and EggTexture. Definition at line 27 of file eggRenderMode.cxx. |