RESOLVED: Setting the swf background

Software: Away3D 4.x

wagster, Member
Posted: 13 October 2011 02:17 PM   Total Posts: 68

Hi - I think I have myself tied up in knots here”

I want a radial gradient background behind my 3d model.  I’ve tried putting a MovieClip behind the View3D, but that always pops up on top.  Am I right in thinking that DisplayObjects can go infront of the View3D, but not behind it?

In that case, my only real option is to create some sort of SkyBox and rotate it so it always faces away from the camera - right?  Or is there a better way?

   

Avatar
Apprentice, Jr. Member
Posted: 13 October 2011 03:05 PM   Total Posts: 45   [ # 1 ]

You’re right:
http://help.adobe.com/en_US/FlashPlatform/beta/reference/actionscript
/3/flash/display/Stage3D.html (read the top few lines)

I guess what you could do is make a plane in front of the camera (at about the .far value) that always faces the camera and exactly covers the camera view.

   

wagster, Member
Posted: 13 October 2011 06:04 PM   Total Posts: 68   [ # 2 ]

Or alternatively:

Class public class View3D
Inheritance View3D Inheritance flash.display.Sprite

Public Properties
 
  backgroundImage : BitmapData

Thanks AwayDudes!

   

Avatar
Alejandro Santander, Administrator
Posted: 14 October 2011 04:32 AM   Total Posts: 414   [ # 3 ]

That’s right, you can use view.backgroundImage = someBitmapData;

GPU stuff rendered by Stage3D is always behind the usual flash display tree, so you cannot put any 2D graphics behind a view. The only alternative Away3D offers at the moment is to set the backgroundImage or bacgroundColor.

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X