diff --git a/src/houdini/custom/USD/GEO_FileData.C b/src/houdini/custom/USD/GEO_FileData.C index 5e59052b..24294e00 100644 --- a/src/houdini/custom/USD/GEO_FileData.C +++ b/src/houdini/custom/USD/GEO_FileData.C @@ -165,8 +165,9 @@ GEO_FileData::Open(const std::string& filePath) } else { - gdh.allocateAndSet(new GU_Detail()); + orig_path_with_args = SdfLayer::CreateIdentifier(filePath, myCookArgs); + gdh.allocateAndSet(new GU_Detail()); GU_DetailHandleAutoWriteLock gdp_write_lock(gdh); GU_Detail *gdp = gdp_write_lock.getGdp(); auto status = gdp->load(filePath.c_str()); diff --git a/src/houdini/custom/USD/usd_plugins/usdHGeo/resources/plugInfo.json b/src/houdini/custom/USD/usd_plugins/usdHGeo/resources/plugInfo.json index 05f55507..907e9492 100644 --- a/src/houdini/custom/USD/usd_plugins/usdHGeo/resources/plugInfo.json +++ b/src/houdini/custom/USD/usd_plugins/usdHGeo/resources/plugInfo.json @@ -28,7 +28,8 @@ "bgeo", "sop", "gz", - "sc" + "sc", + "vdb" ], "formatId": "geo", "primary": true, diff --git a/src/houdini/custom/USDOP/HUSD_FieldWrapper.C b/src/houdini/custom/USDOP/HUSD_FieldWrapper.C index 6803bfa3..f0564562 100644 --- a/src/houdini/custom/USDOP/HUSD_FieldWrapper.C +++ b/src/houdini/custom/USDOP/HUSD_FieldWrapper.C @@ -19,6 +19,7 @@ #include #include #include +#include #include #include @@ -27,6 +28,7 @@ PXR_NAMESPACE_OPEN_SCOPE TF_DEFINE_PRIVATE_TOKENS(_tokens, ((vdbFieldPrimType, "OpenVDBAsset")) ((houdiniFieldPrimType, "HoudiniFieldAsset")) + ((volumePrimType, "Volume")) ); void @@ -40,6 +42,10 @@ HUSD_FieldWrapper::registerForRead() _tokens->vdbFieldPrimType, &HUSD_FieldWrapper::defineForRead); GusdPrimWrapper::registerPrimDefinitionFuncForRead( _tokens->houdiniFieldPrimType, &HUSD_FieldWrapper::defineForRead); + + // Also register Volume primitives so that they unpack to fields. + GusdPrimWrapper::registerPrimDefinitionFuncForRead( + _tokens->volumePrimType, &GusdXformWrapper::defineForRead); }); } diff --git a/src/houdini/lib/H_USD/HUSD/HUSD_Skeleton.C b/src/houdini/lib/H_USD/HUSD/HUSD_Skeleton.C index 54971142..e3194b8b 100644 --- a/src/houdini/lib/H_USD/HUSD/HUSD_Skeleton.C +++ b/src/houdini/lib/H_USD/HUSD/HUSD_Skeleton.C @@ -145,7 +145,6 @@ HUSDimportSkinnedGeometry(GU_Detail &gdp, const HUSD_AutoReadLock &readlock, for (exint i = 0, n = strings.size(); i < n; ++i) { SdfPath prim_path = HUSDgetSdfPath(strings[i]); - prim_path.MakeRelativePath(root_path); shapeattrib_h->replaceString( GA_StringIndexType(handles[i]), diff --git a/src/houdini/lib/H_USD/gusd/xformWrapper.h b/src/houdini/lib/H_USD/gusd/xformWrapper.h index 19985f0e..dd4775c7 100644 --- a/src/houdini/lib/H_USD/gusd/xformWrapper.h +++ b/src/houdini/lib/H_USD/gusd/xformWrapper.h @@ -99,7 +99,7 @@ class GusdXformWrapper : public GusdGroupBaseWrapper const SdfPath& path, const GusdContext& ctxt); - static GT_PrimitiveHandle + static GUSD_API GT_PrimitiveHandle defineForRead( const UsdGeomImageable& sourcePrim, UsdTimeCode time, GusdPurposeSet purposes );