Skip to content
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

avm2: Store PerspectiveProjection to DisplayObject #19670

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

cookie-s
Copy link
Contributor

@cookie-s cookie-s commented Mar 1, 2025

Continued from #19532 .

DisplayObject stores Option<PerspectiveProjection> through Transform so we can remove HAS_PERSPECTIVE_PROJECTION_STUB flag from display objects.

The test from_shumway/avm2/flash/geom/perspectiveprojection passes now.

Limitation

PerspectiveProjection is stored in Transform, but it's not used in rendering at all. (Hence, we cannot remove stub_setters)

@cookie-s cookie-s force-pushed the perspective-projection-storage branch 6 times, most recently from 3d16d8c to 19168c2 Compare March 2, 2025 17:35
cookie-s added 7 commits March 2, 2025 17:36
Stage and root have their own initial PerspectiveProjection value, and
it's also used when attempting to set `null`.
* Remove FIXME for TestTranformUpdate()
* Add four more test cases
It's now unused because ruffle_render::Transform stores Option<PerspectiveProjection>.
It's very hard to verify this value with any test while
PerspectiveProjection rendering is not implemented. However, this change
makes the most sense.
@cookie-s cookie-s force-pushed the perspective-projection-storage branch from 19168c2 to af96e50 Compare March 2, 2025 17:43
@cookie-s cookie-s marked this pull request as ready for review March 2, 2025 17:56
@Lord-McSweeney Lord-McSweeney added A-avm2 Area: AVM2 (ActionScript 3) T-fix Type: Bug fix (in something that's supposed to work already) waiting-on-review Waiting on review from a Ruffle team member labels Mar 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-avm2 Area: AVM2 (ActionScript 3) T-fix Type: Bug fix (in something that's supposed to work already) waiting-on-review Waiting on review from a Ruffle team member
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants