Event when Skybox renders on screen.

Software: Away3D 4.x

Avatar
Jerome Maurey-Delaunay, Moderator
Posted: 25 October 2011 10:22 PM   Total Posts: 17

Hi,

While working on a new site that uses Away3D 4, I noticed quite a lag between the assets being loaded (6 jpg images) and the Skybox being rendered.

Is there an event we can listen to that would let us know when rendering on screen starts?

Ideally this would allow for a nicer flow when transitioning between skyboxes.

Did I mention performance is amazing!? I didn’t? Well it’s flipping amazing!

Cheers,

J.

   

Richard Olsson, Administrator
Posted: 28 October 2011 08:58 PM   Total Posts: 1192   [ # 1 ]

Your code is adding the skybox (it’s most likely not coming from any external files, because I don’t believe there is any file format support in Away3D that can define a skybox) so you should already know when the sky box is being added.

Rendering “starts” the first time you invoke View3D.render(). If you are loading something, and are invoking render() while loading, the loading/parsing should only minimally interfere with the rendering. If you need to know when everything has finished loading, listen for LoaderEvent.RESOURE_COMPLETE on the loader you’re using.

   

Avatar
Jerome Maurey-Delaunay, Moderator
Posted: 29 October 2011 12:38 AM   Total Posts: 17   [ # 2 ]

Hi Richard,

The assets are loaded via Gaia. Once the page loads the 3D component gets the bitmapdata for each panel, compose a CubeMap and then passes that to the Skybox.

In the flow, I blur the current frame. Gaia Loads its stuff, does the above and then fades out the blurred bitmap. Between the fade and the new SkyBox showing there is a lag. I think it might be something we need to live with. I’ll send you the preview link on Skype.

By the way, I had to implement an FP10 version of the FP11 code and it was quite a minimal task to get this to work in Away3D 3.6. Once again kudos to the dev team for making this quite seamless! You guys rock.

Cheers,

Jerome.

   
   

X

Away3D Forum

Member Login

Username

Password

Remember_me



X