24 #ifndef PXR_USD_SDF_COPY_UTILS_H 25 #define PXR_USD_SDF_COPY_UTILS_H 30 #include "pxr/usd/sdf/api.h" 35 #include <boost/optional.hpp> 38 PXR_NAMESPACE_OPEN_SCOPE
76 const SdfLayerHandle& srcLayer,
const SdfPath& srcPath,
77 const SdfLayerHandle& dstLayer,
const SdfPath& dstPath);
101 const SdfLayerHandle& srcLayer,
const SdfPath& srcPath,
bool fieldInSrc,
102 const SdfLayerHandle& dstLayer,
const SdfPath& dstPath,
bool fieldInDst,
103 boost::optional<VtValue>* valueToCopy)>;
122 std::function<void(
const SdfLayerHandle&,
const SdfPath&)>;
125 const EditFunction& GetEditFunction()
const {
return _edit; }
152 bool(
const TfToken& childrenField,
153 const SdfLayerHandle& srcLayer,
const SdfPath& srcPath,
bool fieldInSrc,
154 const SdfLayerHandle& dstLayer,
const SdfPath& dstPath,
bool fieldInDst,
155 boost::optional<VtValue>* srcChildren,
156 boost::optional<VtValue>* dstChildren)>;
171 const SdfLayerHandle& srcLayer,
const SdfPath& srcPath,
bool fieldInSrc,
172 const SdfLayerHandle& dstLayer,
const SdfPath& dstPath,
bool fieldInDst,
173 boost::optional<VtValue>* valueToCopy);
188 const SdfLayerHandle& srcLayer,
const SdfPath& srcPath,
bool fieldInSrc,
189 const SdfLayerHandle& dstLayer,
const SdfPath& dstPath,
bool fieldInDst,
190 boost::optional<VtValue>* srcChildren,
191 boost::optional<VtValue>* dstChildren);
219 const SdfLayerHandle& srcLayer,
const SdfPath& srcPath,
220 const SdfLayerHandle& dstLayer,
const SdfPath& dstPath,
226 PXR_NAMESPACE_CLOSE_SCOPE
228 #endif // PXR_USD_SDF_COPY_UTILS_H A scene description container that can combine with other such containers to form simple component as...
SDF_API bool SdfShouldCopyChildren(const SdfPath &srcRootPath, const SdfPath &dstRootPath, const TfToken &childrenField, const SdfLayerHandle &srcLayer, const SdfPath &srcPath, bool fieldInSrc, const SdfLayerHandle &dstLayer, const SdfPath &dstPath, bool fieldInDst, boost::optional< VtValue > *srcChildren, boost::optional< VtValue > *dstChildren)
SdfShouldCopyChildrenFn used by the simple version of SdfCopySpec.
bool operator==(const SdfCopySpecsValueEdit &rhs) const
SdfCopySpecsValueEdit objects are not comparable, but must provide operator== to be stored in a VtVal...
Value containing an editing operation for SdfCopySpecs.
std::function< bool(SdfSpecType specType, const TfToken &field, const SdfLayerHandle &srcLayer, const SdfPath &srcPath, bool fieldInSrc, const SdfLayerHandle &dstLayer, const SdfPath &dstPath, bool fieldInDst, boost::optional< VtValue > *valueToCopy)> SdfShouldCopyValueFn
Return true if field should be copied from the spec at srcPath in srcLayer to the spec at dstPath in ...
Token for efficient comparison, assignment, and hashing of known strings.
std::function< bool(const TfToken &childrenField, const SdfLayerHandle &srcLayer, const SdfPath &srcPath, bool fieldInSrc, const SdfLayerHandle &dstLayer, const SdfPath &dstPath, bool fieldInDst, boost::optional< VtValue > *srcChildren, boost::optional< VtValue > *dstChildren)> SdfShouldCopyChildrenFn
Return true if childrenField and the child objects the field represents should be copied from the spe...
std::function< void(const SdfLayerHandle &, const SdfPath &)> EditFunction
Callback to apply a scene description edit to the specified layer and spec path.
A path value used to locate objects in layers or scenegraphs.
SDF_API bool SdfShouldCopyValue(const SdfPath &srcRootPath, const SdfPath &dstRootPath, SdfSpecType specType, const TfToken &field, const SdfLayerHandle &srcLayer, const SdfPath &srcPath, bool fieldInSrc, const SdfLayerHandle &dstLayer, const SdfPath &dstPath, bool fieldInDst, boost::optional< VtValue > *valueToCopy)
SdfShouldCopyValueFn used by the simple version of SdfCopySpec.
SdfSpecType
An enum that specifies the type of an object.
SDF_API bool SdfCopySpec(const SdfLayerHandle &srcLayer, const SdfPath &srcPath, const SdfLayerHandle &dstLayer, const SdfPath &dstPath)
Utility function for copying spec data at srcPath in srcLayer to destPath in destLayer.
Provides a container which may hold any type, and provides introspection and iteration over array typ...