fix edge condition when there are no transforms in the scene graph

This commit is contained in:
David Rose 2005-08-12 18:47:04 +00:00
parent cb5ee1cd82
commit 3172d9916b
6 changed files with 3 additions and 5 deletions

View File

@ -232,6 +232,7 @@ set_coordinate_system(CoordinateSystem cs) {
_coordinate_system)); _coordinate_system));
} }
_internal_transform = _cs_transform->compose(_external_transform); _internal_transform = _cs_transform->compose(_external_transform);
_transform_stale = true;
} }
//////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////
@ -280,6 +281,7 @@ reset() {
_has_scene_graph_color = false; _has_scene_graph_color = false;
_scene_graph_color_stale = false; _scene_graph_color_stale = false;
_transform_stale = true;
_color_blend_involves_color_scale = false; _color_blend_involves_color_scale = false;
_texture_involves_color_scale = false; _texture_involves_color_scale = false;
_vertex_colors_enabled = true; _vertex_colors_enabled = true;

View File

@ -327,12 +327,12 @@ protected:
Colorf _scene_graph_color; Colorf _scene_graph_color;
bool _has_scene_graph_color; bool _has_scene_graph_color;
bool _scene_graph_color_stale; bool _scene_graph_color_stale;
bool _transform_stale;
bool _color_blend_involves_color_scale; bool _color_blend_involves_color_scale;
bool _texture_involves_color_scale; bool _texture_involves_color_scale;
bool _vertex_colors_enabled; bool _vertex_colors_enabled;
bool _lighting_enabled; bool _lighting_enabled;
bool _clip_planes_enabled; bool _clip_planes_enabled;
bool _color_scale_enabled; bool _color_scale_enabled;
LVecBase4f _current_color_scale; LVecBase4f _current_color_scale;

View File

@ -86,7 +86,6 @@ DXGraphicsStateGuardian8(const FrameBufferProperties &properties) :
_d3d_device = NULL; _d3d_device = NULL;
_dx_is_ready = false; _dx_is_ready = false;
_transform_stale = false;
_vertex_blending_enabled = false; _vertex_blending_enabled = false;
_overlay_windows_supported = false; _overlay_windows_supported = false;
_tex_stats_retrieval_impossible = false; _tex_stats_retrieval_impossible = false;

View File

@ -192,7 +192,6 @@ protected:
bool _dx_is_ready; bool _dx_is_ready;
HRESULT _last_testcooplevel_result; HRESULT _last_testcooplevel_result;
bool _transform_stale;
bool _vertex_blending_enabled; bool _vertex_blending_enabled;
RenderBuffer::Type _cur_read_pixel_buffer; // source for copy_pixel_buffer operation RenderBuffer::Type _cur_read_pixel_buffer; // source for copy_pixel_buffer operation

View File

@ -787,7 +787,6 @@ reset() {
_point_size = 1.0f; _point_size = 1.0f;
_point_perspective = false; _point_perspective = false;
_transform_stale = false;
_vertex_blending_enabled = false; _vertex_blending_enabled = false;
report_my_gl_errors(); report_my_gl_errors();

View File

@ -298,7 +298,6 @@ protected:
float _point_size; float _point_size;
bool _point_perspective; bool _point_perspective;
bool _transform_stale;
bool _vertex_blending_enabled; bool _vertex_blending_enabled;
CPT(DisplayRegion) _actual_display_region; CPT(DisplayRegion) _actual_display_region;