diff --git a/panda/src/graph/matrixTransition.I b/panda/src/graph/matrixTransition.I index 825c3eb6a4..bba9829bf2 100644 --- a/panda/src/graph/matrixTransition.I +++ b/panda/src/graph/matrixTransition.I @@ -183,7 +183,7 @@ internal_compare_to(const NodeTransition *other) const { // For now, we compare componentwise. It makes paranoid_wrt more // sensible, and it doesn't seem to make a big different to // performance. - return _matrix.compare_to(ot->_matrix, 0.001); + return _matrix.compare_to(ot->_matrix, 0.00001); // Uncomment this line instead to compare matrices pointerwise. // return this - other; diff --git a/panda/src/testbed/demo.cxx b/panda/src/testbed/demo.cxx index b8b3e9590c..ccddb87510 100644 --- a/panda/src/testbed/demo.cxx +++ b/panda/src/testbed/demo.cxx @@ -333,6 +333,18 @@ event_fkey(CPT_Event event) { } } +static void +event_B(CPT_Event event) { + if (selected_node.has_arcs()) { + // List everything under the selected bounding volume and + // recompute the volume. + selected_node.ls(); + selected_node.analyze(); + + selected_node.arc()->force_bound_stale(); + } +} + static void enable_highlight() { if (highlight_render_node == NULL) { @@ -552,6 +564,7 @@ void demo_keys(EventHandler&) { event_handler.add_hook("f7", event_fkey); event_handler.add_hook("f8", event_fkey); event_handler.add_hook("f9", event_fkey); + event_handler.add_hook("B", event_B); event_handler.add_hook("L", event_L); event_handler.add_hook("k", event_k);