use collected animation data at multiverse use creator

This commit is contained in:
Bo Zhou 2022-03-22 11:21:26 +09:00
parent ca5017f730
commit ae9e34bc62

View file

@ -44,15 +44,9 @@ class CreateMultiverseUsd(plugin.Creator):
self.data["writeUsdAttributes"] = False
self.data["timeVaryingTopology"] = False
self.data["customMaterialNamespace"] = ''
self.data["numTimeSamples"] = 1
self.data["timeSamplesSpan"] = 0.0
# The attributes below are about animated cache.
self.data["writeTimeRange"] = True
self.data["timeRangeNumTimeSamples"] = 0
self.data["timeRangeSamplesSpan"] = 0.0
# Add animation data
animation_data = lib.collect_animation_data(True)
self.data["timeRangeStart"] = animation_data["frameStart"]
self.data["timeRangeEnd"] = animation_data["frameEnd"]
self.data["timeRangeIncrement"] = animation_data["step"]
self.data["timeRangeFramesPerSecond"] = animation_data["fps"]
self.data.update(animation_data)