Hello,
To make the loaded object to have specular surface, I tried to change the metallic and specular property of the loaded material.
cur_mat, _ = UsdShade.MaterialBindingAPI(prim).ComputeBoundMaterial()
cur_mat.GetInput("metallic_constant").Set(1.0)
cur_mat.GetInput("specular_level").Set(1.0)
UsdShade.MaterialBindingAPI(prim).Bind(cur_mat, UsdShade.Tokens.strongerThanDescendants)
But error happens when calling Set:
Used null prim - UsdExpiredPrimAccessError thrown:
-> Usd_ThrowExpiredPrimAccessError at /buildAgent/work/ac88d7d902b57417/USD/pxr/usd/usd/primData.cpp:257 from
#0 0x00007f0295d6242d in pxrInternal_v0_22__pxrReserved__::UsdAttribute::GetTypeName() const+0x5d
#1 0x00007f02119f0762 in boost::python::objects::caller_py_function_impl<boost::python::detail::caller<bool (*)(pxrInternal_v0_22__pxrReserved__::UsdShadeInput const&, boost::python::api::object, pxrInternal_v0_22__pxrReserved__::UsdTimeCode const&), boost::python::default_call_policies, boost::mpl::vector4<bool, pxrInternal_v0_22__pxrReserved__::UsdShadeInput const&, boost::python::api::object, pxrInternal_v0_22__pxrReserved__::UsdTimeCode const&> > >::operator()(_object*, _object*)+0xc2
#2 0x00007f02a43342ed in boost::python::objects::function::call(_object*, _object*) const+0x33d
#3 0x00007f02a433ac9b in boost::python::detail::exception_handler::operator()(boost::function0<void> const&) const+0x4b
#4 0x00007f025f63dd43 in boost::detail::function::function_obj_invoker2<boost::_bi::bind_t<bool,