24#ifndef PXR_USD_USD_SHADE_UTILS_H
25#define PXR_USD_USD_SHADE_UTILS_H
28#include "pxr/usd/usdShade/api.h"
29#include "pxr/usd/usdShade/types.h"
30#include "pxr/usd/sdf/path.h"
31#include "pxr/usd/usd/attribute.h"
39PXR_NAMESPACE_OPEN_SCOPE
56 UsdShadeAttributeType sourceType);
67 static std::pair<TfToken, UsdShadeAttributeType>
81 const UsdShadeAttributeType type);
127 bool shaderOutputsOnly =
false);
132 bool shaderOutputsOnly =
false);
135PXR_NAMESPACE_CLOSE_SCOPE
A path value used to locate objects in layers or scenegraphs.
This is a small-vector class with local storage optimization, the local storage can be specified via ...
Token for efficient comparison, assignment, and hashing of known strings.
This class encapsulates a shader or node-graph output, which is a connectable attribute representing ...
This class contains a set of utility functions used when authoring and querying shading networks.
static USDSHADE_API std::string GetPrefixForAttributeType(UsdShadeAttributeType sourceType)
Returns the namespace prefix of the USD attribute associated with the given shading attribute type.
static USDSHADE_API UsdShadeAttributeType GetType(const TfToken &fullName)
Given the full name of a shading attribute, returns its shading attribute type.
static USDSHADE_API TfToken GetFullName(const TfToken &baseName, const UsdShadeAttributeType type)
Returns the full shading attribute name given the basename and the shading attribute type.
static USDSHADE_API UsdShadeAttributeVector GetValueProducingAttributes(UsdShadeOutput const &output, bool shaderOutputsOnly=false)
This is an overloaded member function, provided for convenience. It differs from the above function o...
static USDSHADE_API std::pair< TfToken, UsdShadeAttributeType > GetBaseNameAndType(const TfToken &fullName)
Given the full name of a shading attribute, returns it's base name and shading attribute type.
static USDSHADE_API UsdShadeAttributeVector GetValueProducingAttributes(UsdShadeInput const &input, bool shaderOutputsOnly=false)
Find what is connected to an Input or Output recursively.
static USDSHADE_API SdfPath GetConnectedSourcePath(const UsdShadeConnectionSourceInfo &srcInfo)
For a valid UsdShadeConnectionSourceInfo, return the complete path to the source property; otherwise ...
A compact struct to represent a bundle of information about an upstream source attribute.
TfToken class for efficient string referencing and hashing, plus conversions to and from stl string c...