opened
dgovil
username_0
The current exporter behavior writes out frames as if the USD is a the current scenes uiUnits, but does not actually set the fps attributes in the exported layer. This causes downstream readers to treat it as 24fps as is default.

This change adds both TimeCodesPerSecond and FramesPerSecond, if the exporter is exporting animation. This will allow downstream readers to playback at the correct timing.

As a side note...it is surprising that MTimeUnit doesn't have an API method to convert to float values. Would be great in the future if that was exposed, rather than resorting to a hardcoded mapping here.
Add FPS metadata to exported usd files if non static
issue
created
kxl-adsk
username_1
I glance over the changes and notice a change in formatting - we have configured clang-format for maya-usd repository and pull-request authors are required to apply clang-format (using version 10.0.0) to the modified files. Can you please make sure to do it for all your open PRs?
comment
created
dgovil
username_0
@username_1 Are you seeing any formatting changes in particular? 

I'm not sure I see the formatting issues after running clang-format manually again (did this for all the PRs). I ran `clang-format -i` on the modified `.cpp` and `.h` files, and the files were identical.  Additionally I have clang format running as part of my CLion setup and it's not detecting any style infractions.

Also tried running the command specified in [your PR](https://github.com/Autodesk/maya-usd/pull/890) `find -E . -regex "$(echo '.*('$(echo $(cat .clang-format-include) | tr ' ' '\|')')')" -exec clang-format -i {} \+` , however that modified a bunch of files that are not part of any of my PRs:

```
        modified:   lib/mayaUsd/fileio/transformWriter.cpp
        modified:   lib/mayaUsd/render/vp2RenderDelegate/proxyRenderDelegate.cpp
        modified:   lib/mayaUsd/render/vp2RenderDelegate/render_delegate.h
        modified:   lib/mayaUsd/render/vp2RenderDelegate/render_param.h
        modified:   lib/mayaUsd/ufe/UsdAttributes.cpp
        modified:   lib/mayaUsd/ufe/UsdRotatePivotTranslateUndoableCommand.h
        modified:   lib/mayaUsd/ufe/UsdRotateUndoableCommand.h
        modified:   lib/mayaUsd/ufe/UsdScaleUndoableCommand.h
        modified:   lib/mayaUsd/ufe/UsdTranslateUndoableCommand.h
        modified:   lib/usd/translators/nurbsSurfaceWriter.cpp
        modified:   lib/usd/utils/SIMD.h
        modified:   plugin/al/lib/AL_USDMaya/AL/usdmaya/Global.h
        modified:   plugin/al/lib/AL_USDMaya/AL/usdmaya/nodes/ProxyShape.h
        modified:   plugin/al/mayautils/AL/maya/event/MayaEventManager.cpp
        modified:   plugin/al/mayautils/AL/maya/event/MayaEventManager.h
        modified:   plugin/al/mayautils/AL/maya/utils/FileTranslatorOptions.cpp
        modified:   plugin/al/mayautils/AL/maya/utils/FileTranslatorOptions.h
        modified:   plugin/al/translators/Mesh.cpp
        modified:   plugin/pxr/maya/lib/usdMaya/referenceAssembly.cpp
```

For reference, I'm using your clang format file from bb0704ab6cfde7f158419837a98a8a5aa477814d
My clang-format version is 11.0.0 on a Mac. Is it possible that our clang formats are configured differently perhaps?
comment
created
kxl-adsk
username_1
It's the change in utils.h where I was expecting indentation - https://github.com/Autodesk/maya-usd/pull/913/files#diff-68214d17766b3d5a5678b676f7939a4d4899e99d1f5152a8a8c0e24e933d7078R575

But the more important is the version of clang-format. You mentioned version **11.0.0** but we ask developers to all use version **10.0.0.** This is because different versions produce different results for the same clang-format configuration file.
comment
created
dgovil
username_0
I tried formatting the files again with clang-format 10 (downloaded from the link in https://github.com/Autodesk/maya-usd/pull/890 since homebrew no longer has a recipe for 10 available) and it's still not marking these files as needing changes. Running it across the entirety of the repo did show a different set of modified files than clang-format 11 so that does show the versions vary quite a bit.

Just to confirm though, if you run clang-format on this branch, does it change `utils.h`? I just want to verify if it's an issue in the config versus something on our end here. 

Here are the results of running clang-format 10 across the whole repo on my end:

[formatting.patch.txt](https://github.com/Autodesk/maya-usd/files/5531933/formatting.patch.txt)

```
	modified:   lib/mayaUsd/ufe/UsdAttributes.cpp
	modified:   plugin/al/mayautils/AL/maya/event/MayaEventManager.cpp
	modified:   plugin/al/mayautils/AL/maya/event/MayaEventManager.h
	modified:   plugin/al/mayautils/AL/maya/utils/FileTranslatorOptions.cpp
```
comment
created
kxl-adsk
username_1
Re `utils.h` - you are right, I must have looked at it too quickly.

Re clang-format version and what's currently still showing up after running it. Indeed, we still have 4 files that are not showing a difference after you run clang-format v10.0.0 on the entire repo. We have discovered just recently that in some cases, clang-format may have to be applied more than once. I will open a PR for the remaining files.
comment
created
dgovil
username_0
Ok great to know it's not some deeper issue. I'll move around the unittests per the other PR and then update this one.
comment
created
dgovil
username_0
Okay, updated the test location. Hopefully should be good to go, but let me know if you see anything else of concern. I'll update the other PRs shortly too.
comment