-
Notifications
You must be signed in to change notification settings - Fork 17
perf: opt playable asset #368
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
Conversation
WalkthroughThe recent updates to the Changes
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (invoked as PR comments)
Additionally, you can add CodeRabbit Configration File (
|
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.
Actionable comments posted: 0
Review Details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Files selected for processing (9)
- packages/effects-core/src/composition-source-manager.ts (3 hunks)
- packages/effects-core/src/composition.ts (1 hunks)
- packages/effects-core/src/engine.ts (1 hunks)
- packages/effects-core/src/fallback/migration.ts (4 hunks)
- packages/effects-core/src/plugins/cal/calculate-item.ts (2 hunks)
- packages/effects-core/src/plugins/cal/calculate-vfx-item.ts (4 hunks)
- packages/effects-core/src/plugins/cal/track.ts (1 hunks)
- packages/effects-core/src/plugins/particle/particle-system.ts (3 hunks)
- packages/effects-core/src/plugins/sprite/sprite-item.ts (3 hunks)
Files skipped from review due to trivial changes (1)
- packages/effects-core/src/composition.ts
Additional comments not posted (11)
packages/effects-core/src/plugins/cal/track.ts (1)
64-64
: Visibility ofaddClip
method changed to public.Ensure that this method is robust and handles all edge cases since it can now be accessed more broadly.
packages/effects-core/src/plugins/cal/calculate-item.ts (1)
80-85
: Refactored handling of clips within tracks.Ensure that all properties necessary for the correct functioning of clips are being set in the new
TimelineClip
instances.packages/effects-core/src/engine.ts (1)
98-103
: Added handling forjsonScene.animations
.Verify that
addEffectsObjectData
correctly processes eachanimationData
and that no animations are missed.packages/effects-core/src/composition-source-manager.ts (1)
Line range hint
87-115
: Improved handling ofsceneBindings
andtimelineAsset
.Ensure that
sceneBindings
is correctly initialized as an empty array when absent and thattimelineAsset
is properly loaded based on itsid
.packages/effects-core/src/plugins/cal/calculate-vfx-item.ts (1)
Line range hint
51-196
: EnhancedTransformAnimationPlayable
with new properties and methods.Verify that the new
data
property andonGraphStart
,processFrame
methods are correctly implemented and integrate well with existing functionalities.packages/effects-core/src/fallback/migration.ts (1)
Line range hint
423-515
: Updated handling ofdataType
values and creation of newPlayableAssetData
objects.Ensure that
dataType
values are correctly set for various components and that newPlayableAssetData
objects are created appropriately.packages/effects-core/src/plugins/sprite/sprite-item.ts (3)
18-18
: The updated imports align with the new class implementations and refactoring strategy.
111-111
: Updated method signature enhances type safety and clarity in data handling.
127-148
: Introduction ofSpriteColorPlayableAsset
class and related data types enhances modularity and clarity. Good use of decorators to define class responsibilities.packages/effects-core/src/plugins/particle/particle-system.ts (2)
645-650
: Adjust particle position based on editor scale ratio.Consider adding a comment explaining why this adjustment is necessary, as it helps maintain the code's readability and understandability.
745-748
: Adjust particle size based on editor scale ratio.Consider adding a comment explaining why this adjustment is necessary, as it helps maintain the code's readability and understandability.
Summary by CodeRabbit
New Features
editorScaleRatio
property in theComposition
class for better scaling control.TransformAnimationPlayable
andTransformAnimationPlayableAsset
classes for enhanced animation handling.Improvements
Engine
class to better handle animations withinjsonScene
.calculate-item.ts
.ParticleSystem
class based on the environment.Refactor
TimelineClip
instances.addClip
method inTrack
class to allow external access.