Respect clipDepth when reusing timeline instances#50
Open
asimetra wants to merge 1 commit into
Open
Conversation
Timeline instance deduplication treated matching symbol and depth as enough identity, but clip depth is serialized onto the instance only when it is created. When an asset places the same symbol at the same depth with a different clip depth, reusing the previous instance preserves stale mask range data. Constraint: SWF PlaceObject clip depth changes alter timeline mask semantics even when symbol and depth are unchanged Rejected: Refresh clipDepth on reused instances | that would blur update semantics with instance identity and could hide other create-time state differences Confidence: medium Scope-risk: narrow Directive: Keep AnimateLibrary and SWFLite dedupe predicates aligned for serialized timeline instance identity Tested: haxe rebuild.hxml
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This fixes a timeline instance reuse issue when the same character is placed at the same depth with a different
clipDepth.Previously, Animate and SWFLite timelines deduped instances by character id and depth only. However,
clipDepthis stored on the timeline instance when it is created. If a later placement reused the same instance with a differentclipDepth, the old mask range could be kept and masking would be applied incorrectly.The fix includes
clipDepthin the duplicate-instance match for both Animate and SWFLite timeline paths.I attached a small repro project with a minimal SWF asset. The SWF places character
100at depth7withoutclipDepth, then later places the same character at the same depth withclipDepth = 11.ClipDepthReuseRepro.zip