mirror of
https://github.com/panda3d/panda3d.git
synced 2025-09-28 07:48:37 -04:00
Merge remote-tracking branch 'origin/release/1.10.x'
This commit is contained in:
commit
f0446a6e9c
@ -391,7 +391,7 @@ cp_dependency(ShaderMatInput inp) {
|
|||||||
dep |= SSD_colorscale;
|
dep |= SSD_colorscale;
|
||||||
}
|
}
|
||||||
if (inp == SMO_attr_fog || inp == SMO_attr_fogcolor) {
|
if (inp == SMO_attr_fog || inp == SMO_attr_fogcolor) {
|
||||||
dep |= SSD_fog;
|
dep |= SSD_fog | SSD_frame;
|
||||||
}
|
}
|
||||||
if ((inp == SMO_model_to_view) ||
|
if ((inp == SMO_model_to_view) ||
|
||||||
(inp == SMO_view_to_model) ||
|
(inp == SMO_view_to_model) ||
|
||||||
|
@ -1532,6 +1532,14 @@ has_tag(const std::string &key) const {
|
|||||||
return _cdata->_tag_data.find(key) >= 0;
|
return _cdata->_tag_data.find(key) >= 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the "into" collide mask for this node.
|
||||||
|
*/
|
||||||
|
INLINE CollideMask PandaNodePipelineReader::
|
||||||
|
get_into_collide_mask() const {
|
||||||
|
return _cdata->_into_collide_mask;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the union of all into_collide_mask() values set at CollisionNodes
|
* Returns the union of all into_collide_mask() values set at CollisionNodes
|
||||||
* at this level and below.
|
* at this level and below.
|
||||||
|
@ -2910,11 +2910,21 @@ get_component(NodePathComponent *parent, PandaNode *child_node,
|
|||||||
// First, walk through the list of NodePathComponents we already have on the
|
// First, walk through the list of NodePathComponents we already have on the
|
||||||
// child, looking for one that already exists, referencing the indicated
|
// child, looking for one that already exists, referencing the indicated
|
||||||
// parent component.
|
// parent component.
|
||||||
Paths::const_iterator pi;
|
for (NodePathComponent *child : child_node->_paths) {
|
||||||
for (pi = child_node->_paths.begin(); pi != child_node->_paths.end(); ++pi) {
|
if (child->get_next(pipeline_stage, current_thread) == parent) {
|
||||||
if ((*pi)->get_next(pipeline_stage, current_thread) == parent) {
|
|
||||||
// If we already have such a component, just return it.
|
// If we already have such a component, just return it.
|
||||||
return (*pi);
|
// But before we do, we have to make sure it's not in the middle of being
|
||||||
|
// destructed.
|
||||||
|
#ifdef HAVE_THREADS
|
||||||
|
if (child->ref_if_nonzero()) {
|
||||||
|
PT(NodePathComponent) result;
|
||||||
|
result.cheat() = child;
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
// If we're not building with threading, increment as normal.
|
||||||
|
return child;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2952,11 +2962,21 @@ get_top_component(PandaNode *child_node, bool force, int pipeline_stage,
|
|||||||
|
|
||||||
// Walk through the list of NodePathComponents we already have on the child,
|
// Walk through the list of NodePathComponents we already have on the child,
|
||||||
// looking for one that already exists as a top node.
|
// looking for one that already exists as a top node.
|
||||||
Paths::const_iterator pi;
|
for (NodePathComponent *child : child_node->_paths) {
|
||||||
for (pi = child_node->_paths.begin(); pi != child_node->_paths.end(); ++pi) {
|
if (child->is_top_node(pipeline_stage, current_thread)) {
|
||||||
if ((*pi)->is_top_node(pipeline_stage, current_thread)) {
|
|
||||||
// If we already have such a component, just return it.
|
// If we already have such a component, just return it.
|
||||||
return (*pi);
|
// But before we do, we have to make sure it's not in the middle of being
|
||||||
|
// destructed.
|
||||||
|
#ifdef HAVE_THREADS
|
||||||
|
if (child->ref_if_nonzero()) {
|
||||||
|
PT(NodePathComponent) result;
|
||||||
|
result.cheat() = child;
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
#else
|
||||||
|
// If we're not building with threading, increment as normal.
|
||||||
|
return child;
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -902,6 +902,7 @@ public:
|
|||||||
INLINE std::string get_tag(const std::string &key) const;
|
INLINE std::string get_tag(const std::string &key) const;
|
||||||
INLINE bool has_tag(const std::string &key) const;
|
INLINE bool has_tag(const std::string &key) const;
|
||||||
|
|
||||||
|
INLINE CollideMask get_into_collide_mask() const;
|
||||||
INLINE CollideMask get_net_collide_mask() const;
|
INLINE CollideMask get_net_collide_mask() const;
|
||||||
INLINE const RenderAttrib *get_off_clip_planes() const;
|
INLINE const RenderAttrib *get_off_clip_planes() const;
|
||||||
INLINE const BoundingVolume *get_bounds() const;
|
INLINE const BoundingVolume *get_bounds() const;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user