[Papervision3D] Load external swf with scene and viewport

John Barcklay j.barcklay at gmail.com
Mon Oct 18 08:28:40 PDT 2010


Hi guys! I would like to know if it's possible to load a external swf
containing a Papervison3D scene and a viewport (without camera) to a main
swf containing himself a scene, a camera and a viewport.
In my project I want to load an external swf in the main swf an use the same
camera for the main and the external swf, just switch the viewport and the
scene. I would like to know how to do this please.

I use this to load my external swf in my main class:
private function switchScene():void
{
var ur:URLRequest = null;
var lc:LoaderContext = null;
 currScene =  filepath + "/" + navName[currentNumber] + ".swf";
 ur = new URLRequest(currScene);
 lc = new LoaderContext();
lc.applicationDomain = ApplicationDomain.currentDomain;
 ldr =  new Loader();
ldr.contentLoaderInfo.addEventListener(Event.COMPLETE, sceneLoaded);
ldr.contentLoaderInfo.addEventListener(ProgressEvent.PROGRESS,
sceneProgressHandler);
ldr.load(ur, lc);
return;
}

I have a problem with this :
ldr.content.scene

and this :

ldr.content.viewport

Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://osflash.org/pipermail/papervision3d_osflash.org/attachments/20101018/d4b78be2/attachment.html>


More information about the Papervision3D mailing list