This document is for a version of USD that is under development. See this page for the current release.
All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
relationshipSpec.h File Reference
+ Include dependency graph for relationshipSpec.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  SdfRelationshipSpec
 A property that contains a reference to one or more SdfPrimSpec instances. More...
 

Functions

SDF_API SdfRelationshipSpecHandle SdfCreateRelationshipInLayer (const SdfLayerHandle &layer, const SdfPath &relPath, SdfVariability variability=SdfVariabilityVarying, bool isCustom=false)
 Convenience function to create a relationshipSpec on a primSpec at the given path, and any necessary parent primSpecs, in the given layer.
 
SDF_API bool SdfJustCreateRelationshipInLayer (const SdfLayerHandle &layer, const SdfPath &relPath, SdfVariability variability=SdfVariabilityVarying, bool isCustom=false)
 Convenience function to create a relationshipSpec on a primSpec at the given path, and any necessary parent primSpecs, in the given layer.
 

Function Documentation

◆ SdfCreateRelationshipInLayer()

SDF_API SdfRelationshipSpecHandle SdfCreateRelationshipInLayer ( const SdfLayerHandle &  layer,
const SdfPath relPath,
SdfVariability  variability = SdfVariabilityVarying,
bool  isCustom = false 
)

Convenience function to create a relationshipSpec on a primSpec at the given path, and any necessary parent primSpecs, in the given layer.

If a relationshipSpec already exists at the given path, author variability and custom according to passed arguments and return a relationship spec handle.

Any newly created prim specs have SdfSpecifierOver and an empty type (as if created by SdfJustCreatePrimInLayer()). relPath must be a valid prim property path (see SdfPath::IsPrimPropertyPath()). Return false and issue an error if we fail to author the required scene description.

◆ SdfJustCreateRelationshipInLayer()

SDF_API bool SdfJustCreateRelationshipInLayer ( const SdfLayerHandle &  layer,
const SdfPath relPath,
SdfVariability  variability = SdfVariabilityVarying,
bool  isCustom = false 
)

Convenience function to create a relationshipSpec on a primSpec at the given path, and any necessary parent primSpecs, in the given layer.

If a relationshipSpec already exists at the given path, author variability and custom according to passed arguments and return a relationship spec handle.

Any newly created prim specs have SdfSpecifierOver and an empty type (as if created by SdfJustCreatePrimInLayer()). relPath must be a valid prim property path (see SdfPath::IsPrimPropertyPath()). Return false and issue an error if we fail to author the required scene description.

Differs only from SdfCreateRelationshipInLayer only in that a bool, not a handle, is returned.