mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-29 16:20:11 -04:00
Backport to 1.9: fix for distance sorting with gl-coordinate-system changed
This commit is contained in:
parent
83d54bcdaf
commit
a1338b9ac6
@ -49,6 +49,7 @@ This issue fixes several bugs that were still found in 1.9.2.
|
|||||||
* Fix error when trying to raise vectors to a power
|
* Fix error when trying to raise vectors to a power
|
||||||
* GLSL: fix error when legacy matrix generator inputs are mat3
|
* GLSL: fix error when legacy matrix generator inputs are mat3
|
||||||
* Now tries to preserve refresh rate when switching fullscreen on Windows
|
* Now tries to preserve refresh rate when switching fullscreen on Windows
|
||||||
|
* Fix back-to-front sorting when gl-coordinate-system is changed
|
||||||
|
|
||||||
------------------------ RELEASE 1.9.2 ------------------------
|
------------------------ RELEASE 1.9.2 ------------------------
|
||||||
|
|
||||||
|
@ -148,6 +148,10 @@ GraphicsStateGuardian(CoordinateSystem internal_coordinate_system,
|
|||||||
_coordinate_system = CS_invalid;
|
_coordinate_system = CS_invalid;
|
||||||
_internal_transform = TransformState::make_identity();
|
_internal_transform = TransformState::make_identity();
|
||||||
|
|
||||||
|
if (internal_coordinate_system == CS_default) {
|
||||||
|
_internal_coordinate_system = get_default_coordinate_system();
|
||||||
|
}
|
||||||
|
|
||||||
set_coordinate_system(get_default_coordinate_system());
|
set_coordinate_system(get_default_coordinate_system());
|
||||||
|
|
||||||
_data_reader = (GeomVertexDataPipelineReader *)NULL;
|
_data_reader = (GeomVertexDataPipelineReader *)NULL;
|
||||||
|
@ -5485,19 +5485,6 @@ make_geom_munger(const RenderState *state, Thread *current_thread) {
|
|||||||
return GeomMunger::register_munger(munger, current_thread);
|
return GeomMunger::register_munger(munger, current_thread);
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////
|
|
||||||
// Function: GLGraphicsStateGuardian::compute_distance_to
|
|
||||||
// Access: Public, Virtual
|
|
||||||
// Description: This function will compute the distance to the
|
|
||||||
// indicated point, assumed to be in eye coordinates,
|
|
||||||
// from the camera plane. The point is assumed to be
|
|
||||||
// in the GSG's internal coordinate system.
|
|
||||||
////////////////////////////////////////////////////////////////////
|
|
||||||
PN_stdfloat CLP(GraphicsStateGuardian)::
|
|
||||||
compute_distance_to(const LPoint3 &point) const {
|
|
||||||
return -point[2];
|
|
||||||
}
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////////
|
||||||
// Function: GLGraphicsStateGuardian::framebuffer_copy_to_texture
|
// Function: GLGraphicsStateGuardian::framebuffer_copy_to_texture
|
||||||
// Access: Public, Virtual
|
// Access: Public, Virtual
|
||||||
|
@ -336,8 +336,6 @@ public:
|
|||||||
virtual PT(GeomMunger) make_geom_munger(const RenderState *state,
|
virtual PT(GeomMunger) make_geom_munger(const RenderState *state,
|
||||||
Thread *current_thread);
|
Thread *current_thread);
|
||||||
|
|
||||||
virtual PN_stdfloat compute_distance_to(const LPoint3 &point) const;
|
|
||||||
|
|
||||||
virtual void clear(DrawableRegion *region);
|
virtual void clear(DrawableRegion *region);
|
||||||
|
|
||||||
virtual bool framebuffer_copy_to_texture
|
virtual bool framebuffer_copy_to_texture
|
||||||
|
Loading…
x
Reference in New Issue
Block a user