PixarAnimationStudios / OpenUSD

Universal Scene Description
http://www.openusd.org
Other
6.14k stars 1.22k forks source link

SetMetaData does not work as experted on Mac #1435

Open zpgit opened 3 years ago

zpgit commented 3 years ago

Description of Issue

When I set the prim kind via prim.SetMetadata(pxr::SdfFieldKeys->Kind, pxr::TfToken("component")) It works well on Windows and I get something like this: Xform "MyPrim" ( kind = "component" ) The same code on Mac will generate the following case, I notice there is no quote for the "component". Xform "MyPrim" ( kind = component ) When I open this USD file via usdview, the usdview will crash with message like this: Error in 'pxrInternal_v0_21pxrReserved::Usd_CrateFile::CrateFile::_UnpackValue' at line 3767 in file E:\fork\USD-21.02\USD-21.02\pxr\usd\usd\crateFile.cpp : 'Attempted to unpack unsupported type enum value 0'.

Anyone experience this issue?

Steps to Reproduce

  1. Follow the description

System Information (OS, Hardware)

MacOS

Package Versions

Either version should reproduce.

Build Flags

jilliene commented 3 years ago

Filed as internal issue #USD-6551

xqtyler commented 3 years ago

Is is ok to not set component token type for prism?