-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Blender: Use transform cache to handle alembic camera updates #497
Blender: Use transform cache to handle alembic camera updates #497
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When loading alembic camera, the transform cache modifiers added into the camera as expected.
But there is some issues on updating camera, of which the camera doesn't get updated correctly through scene inventory manager.
2024-05-10.15-48-59.mp4
@moonyuet Could you check if there is any error in the console? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My bad, I loaded the published alembic from the folder where I performed delete old version before. (I realize after looking at the console)
Running callback: <bound method AssetLoader._load of []>
Alembic import of 'D:\sh_boss_proj\interior_lenny\lenny_bedroom\asset\publish\camera\cameraMain\v006\il_asset_cameraMain_v006.abc' took 0.6 ms
Done
Initialising WM_OT_avalon_manager...
Traceback (most recent call last):
File "D:\ayon-core\client\ayon_core\tools\sceneinventory\view.py", line 279, in <lambda>
lambda: self._show_version_dialog(items))
File "D:\ayon-core\client\ayon_core\tools\sceneinventory\view.py", line 695, in _show_version_dialog
self._update_containers(items, version)
File "D:\ayon-core\client\ayon_core\tools\sceneinventory\view.py", line 822, in _update_containers
update_container(item, item_version)
File "D:\ayon-core\client\ayon_core\pipeline\load\utils.py", line 514, in update_container
raise ValueError("Path {} doesn't exist".format(path))
ValueError: Path D:/sh_boss_proj\interior_lenny\lenny_bedroom\asset\publish\camera\cameraMain\v005\il_asset_cameraMain_v005.abc doesn't exist
I tested with the published alembic from other tasks, Looks good for me now!
@moonyuet ah not a problem 😄 Thanks for the review! |
Changelog Description
Use transform cache constraints to update alembic cameras.
Before, the camera was deleted and recreated. Now it updates the cache file.
Additional info
This PR should be compatible with existing alembic cameras loaded in the scene. When updating, it will create a new transform cache, if it doesn't find one.
To assign the right object path, it has been necessary a workaround to force Blender to evaluate the cache file loaded. This is because the list of object paths in the cache file is not available immediately when the file has been loaded (https://devtalk.blender.org/t/alembic-cachefile-list-of-object-paths-not-available-at-creation/21573).
Testing notes: