Skip to content

Commit 8e20697

Browse files
johnhaddonyannci
authored andcommitted
USDScene : Fix compatibility with USD 21.08
`GetPrimInMaster()` was deprecated in USD 20.11, when `GetPrimInPrototype()` was added. It was removed in USD 21.08.
1 parent dac816d commit 8e20697

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

contrib/IECoreUSD/src/IECoreUSD/USDScene.cpp

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,10 @@ using namespace IECoreUSD;
9393
#define HasAuthoredValue HasAuthoredValueOpinion
9494
#endif
9595

96+
#if USD_VERSION < 2011
97+
#define GetPrimInPrototype GetPrimInMaster
98+
#endif
99+
96100
namespace
97101
{
98102

@@ -105,7 +109,7 @@ void appendPrimOrMasterPath( const pxr::UsdPrim &prim, IECore::MurmurHash &h )
105109
{
106110
if( prim.IsInstanceProxy() )
107111
{
108-
append( prim.GetPrimInMaster().GetPrimPath(), h );
112+
append( prim.GetPrimInPrototype().GetPrimPath(), h );
109113
}
110114
else
111115
{

0 commit comments

Comments
 (0)