Skip to main content
Known Participant
March 2, 2020
Question

3D transformations from Animate to AIR

  • March 2, 2020
  • 0 replies
  • 324 views

(Please note: I'm not familiar with 3D transformations.)

 

What I'm doing is the following:

I have "flat" objects (videos, movie clips) on the stage of an XFL file.

In Animate, I apply 3D transformations to these objects, via the Transform panel / 3D Rotation.

I also adjust the perspective angle from the Properties panel (which seems to affect not only the selected object, but all objects having a 3D rotation) until I get the desired rendering.

When I compile the whole clip (into a SWC, Ctrl+Enter), I view the resulting SWF: the perspective is fine, just as in authoring mode, the video is playing and it is rendered in the proper perspective.

 

Then I import the clips from the generated SWC into an AIR app.

Then the rendering is not as expected: the objects' perspective seems to be either unaffected (video), or wrong (movie clips), as if they were following another perspective.

 

So I assume that there are some global 3D / perspective settings that were embedded in the SWF in the first place, and that these settings are lost in the process (Animate > SWC > AIR), and need to be declared in AS3 within the AIR app...?

 

I've tried the following code:

root.transform.perspectiveProjection.projectionCenter = new Point(640, 400); 
root.transform.perspectiveProjection.fieldOfView = 114;

as an attempt to replicate the 3D view & position settings from the XFL, but it doesn't work.

 

I've also tried various settings for the <renderMode> node in the manifest, but it doesn't work either.

 

Any advice?

This topic has been closed for replies.