Loading...
Searching...
No Matches
shaderNodeDiscoveryResult.h
Go to the documentation of this file.
1//
2// Copyright 2025 Pixar
3//
4// Licensed under the terms set forth in the LICENSE.txt file available at
5// https://openusd.org/license.
6//
7
8#ifndef PXR_USD_SDR_NODE_DISCOVERY_RESULT_H
9#define PXR_USD_SDR_NODE_DISCOVERY_RESULT_H
10
17
18#include "pxr/usd/sdr/declare.h"
19#include "pxr/usd/ndr/nodeDiscoveryResult.h"
20
21PXR_NAMESPACE_OPEN_SCOPE
22
29 const SdrVersion& version,
30 const std::string& name,
31 const TfToken& family,
33 const TfToken& sourceType,
34 const std::string& uri,
35 const std::string& resolvedUri,
36 const std::string &sourceCode=std::string(),
37 const SdrTokenMap &metadata=SdrTokenMap(),
38 const std::string& blindData=std::string(),
42 name(name),
46 uri(uri),
52 { }
53
61
66
73 std::string name;
74
81
89
96
101 std::string uri;
102
109 std::string resolvedUri;
110
115 std::string sourceCode;
116
123 SdrTokenMap metadata;
124
128 std::string blindData;
129
138
149 name,
150 family,
153 uri,
156 metadata,
157 blindData,
159 );
160 }
161
169 const NdrNodeDiscoveryResult& result
170 ) {
172 result.identifier,
173 NdrToSdrVersion(result.version),
174 result.name,
175 result.family,
176 result.discoveryType,
177 result.sourceType,
178 result.uri,
179 result.resolvedUri,
180 result.sourceCode,
181 result.metadata,
182 result.blindData,
183 result.subIdentifier
184 );
185 }
186};
187
188typedef std::vector<SdrShaderNodeDiscoveryResult> SdrShaderNodeDiscoveryResultVec;
189
190PXR_NAMESPACE_CLOSE_SCOPE
191
192#endif // PXR_USD_SDR_NODE_DISCOVERY_RESULT_H
SdrVersion.
Definition: declare.h:73
Token for efficient comparison, assignment, and hashing of known strings.
Definition: token.h:71
Represents the raw data of a node, and some other bits of metadata, that were determined via a NdrDis...
std::string uri
The node's origin.
TfToken subIdentifier
The subIdentifier is associated with a particular asset and refers to a specific definition within th...
NdrVersion version
The node's version.
NdrTokenMap metadata
The node's metadata collected during the discovery process.
std::string sourceCode
The node's entire source code.
TfToken family
The node's family.
TfToken discoveryType
The node's discovery type.
TfToken sourceType
The node's source type.
std::string name
The node's name.
std::string resolvedUri
The node's fully-resolved URI.
std::string blindData
An optional detail for the parser plugin.
NdrIdentifier identifier
The node's identifier.
Represents the raw data of a node, and some other bits of metadata, that were determined via a SdrDis...
std::string uri
The node's origin.
TfToken subIdentifier
The subIdentifier is associated with a particular asset and refers to a specific definition within th...
SdrShaderNodeDiscoveryResult(const SdrIdentifier &identifier, const SdrVersion &version, const std::string &name, const TfToken &family, const TfToken &discoveryType, const TfToken &sourceType, const std::string &uri, const std::string &resolvedUri, const std::string &sourceCode=std::string(), const SdrTokenMap &metadata=SdrTokenMap(), const std::string &blindData=std::string(), const TfToken &subIdentifier=TfToken())
Constructor.
std::string sourceCode
The node's entire source code.
TfToken family
The node's family.
TfToken discoveryType
The node's discovery type.
SdrTokenMap metadata
The node's metadata collected during the discovery process.
TfToken sourceType
The node's source type.
std::string name
The node's name.
static SdrShaderNodeDiscoveryResult FromNdrNodeDiscoveryResult(const NdrNodeDiscoveryResult &result)
Helper function to translate NdrNodeDiscoveryResult to SdrShaderNodeDiscoveryResult values.
std::string resolvedUri
The node's fully-resolved URI.
std::string blindData
An optional detail for the parser plugin.
SdrIdentifier identifier
The node's identifier.
NdrNodeDiscoveryResult ToNdrNodeDiscoveryResult() const
Helper function to translate SdrShaderNodeDiscoveryResult to NdrNodeDiscoveryResult values.
SdrVersion version
The node's version.
SDR_API NdrVersion SdrToNdrVersion(SdrVersion version)
Helper function to translate SdrVersion to NdrVersion.
SDR_API SdrVersion NdrToSdrVersion(NdrVersion version)
Helper function to translate NdrVersion to SdrVersion.