1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-16 17:59:56 +00:00
openmw/components/sceneutil/attach.hpp

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

34 lines
1 KiB
C++
Raw Normal View History

#ifndef OPENMW_COMPONENTS_SCENEUTIL_ATTACH_H
#define OPENMW_COMPONENTS_SCENEUTIL_ATTACH_H
2022-08-21 16:53:38 +00:00
#include <string_view>
#include <osg/ref_ptr>
namespace osg
{
class Node;
class Group;
2021-11-02 17:01:22 +00:00
class Quat;
}
namespace Resource
{
class SceneManager;
}
namespace SceneUtil
{
/// Clone and attach parts of the \a toAttach scenegraph to the \a master scenegraph, using the specified filter and
/// attachment node. If the \a toAttach scene graph contains skinned objects, we will attach only those (filtered by
/// the \a filter). Otherwise, just attach all of the toAttach scenegraph to the attachment node on the master
/// scenegraph, with no filtering.
/// @note The master scene graph is expected to include a skeleton.
/// @return A newly created node that is directly attached to the master scene graph
2022-08-21 16:53:38 +00:00
osg::ref_ptr<osg::Node> attach(osg::ref_ptr<const osg::Node> toAttach, osg::Node* master, std::string_view filter,
osg::Group* attachNode, Resource::SceneManager* sceneManager, const osg::Quat* attitude = nullptr);
}
#endif