PixarAnimationStudios / OpenUSD

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

uszip broken ? #757

Open zhoub opened 5 years ago

zhoub commented 5 years ago

Description of Issue

Regression of usdzip commandline

Steps to Reproduce

The following command line which creates USDZ package

usdzip --arkitAsset Cone.usdc Cone.usdz ColorMap.png

always reports

usdzip: error: Specify either inputFiles or an asset (via --asset or --arkitAsset, not both.

18.03 worked.

Consider the source code

    if args.asset and args.arkitAsset:
        parser.error("Specify either --asset or --arkitAsset, not both.")

    elif (args.arkitAsset or args.asset) and len(inputFiles)>0:
        parser.error("Specify either inputFiles or an asset (via --asset or "
                     "--arkitAsset, not both.")

It means when arguments contain arkitAsset or asset with external files, it reports error, this is an strange logic.

System Information (OS, Hardware)

Any

Package Versions

19.01

Build Flags

spiffmon commented 5 years ago

Hi Bo, I don’t think the logic is strange, and the error tells you the problem, though possibly we could provide a deeper explanation.

With —asset or —arkitAsset, we perform dependency analysis on the single given USD file, finding and including all the USD and image files that it references, recursively. So there’s no need to include any other files on the command line, we believe.

On Sat, Jan 26, 2019 at 11:04 PM Bo Zhou notifications@github.com wrote:

Description of Issue

The following command line which creates USDZ package

usdzip --arkitAsset Cone.usdc Cone.usdz ColorMap.png

always reports

usdzip: error: Specify either inputFiles or an asset (via --asset or --arkitAsset, not both.

18.03 worked.

Consider the source code

if args.asset and args.arkitAsset:
    parser.error("Specify either --asset or --arkitAsset, not both.")

elif (args.arkitAsset or args.asset) and len(inputFiles)>0:
    parser.error("Specify either inputFiles or an asset (via --asset or "
                 "--arkitAsset, not both.")

It means when arguments contain arkitAsset or asset with external files, it reports error, this is an strange logic. Steps to Reproduce

1.

System Information (OS, Hardware)

Any Package Versions

19.01 Build Flags

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/PixarAnimationStudios/USD/issues/757, or mute the thread https://github.com/notifications/unsubscribe-auth/AF7qaCjvhVYCPIM25eA5mSnos5hl07Cuks5vHU-NgaJpZM4aUk2g .

-- --spiffiPhone

jtran56 commented 5 years ago

Filed as internal issue #USD-5048.