Papervision basicview setup

2 messages Options
Embed this post
Permalink
David Di Biase

Papervision basicview setup

Reply Threaded More More options
Print post
Permalink
Hi there,

Somewhat silly question but for the life of me I can't find the solution. Basically I'd like to setup a BasicView to take up the entire stage but I'm getting some weird issues.

First of all my doc class is not extending a sprite (as I see most PV examples doing). Not sure if that's effecting my results. Here is a sample of my code:

public class eniac extends Application {

    import org.papervision3d.cameras.CameraType;
    import org.papervision3d.objects.primitives.Plane;
    import org.papervision3d.materials.MovieMaterial;
    import org.papervision3d.render.BasicRenderEngine;
    import org.papervision3d.view.BasicView;

    private function initEngine():void {
         view = new BasicView(stage.stageWidth, stage.stageHeight, true, true, CameraType.FREE);
         addChild(view);
    }
}


Basically, it's placing everything on stage but the viewport is being positioned incorrectly ie. the top left of the viewport is centering in the middle of the stage. I'm not exactly sure what may be wrong.

Thanks in advance!

Dave

_______________________________________________
Papervision3D mailing list
[hidden email]
http://osflash.org/mailman/listinfo/papervision3d_osflash.org
David Di Biase

Re: Papervision basicview setup

Reply Threaded More More options
Print post
Permalink
Nevermind, got this resolved. Was something silly with how the stage was setup by a previous coder.

On Thu, Oct 8, 2009 at 5:39 PM, David Di Biase <[hidden email]> wrote:
Hi there,

Somewhat silly question but for the life of me I can't find the solution. Basically I'd like to setup a BasicView to take up the entire stage but I'm getting some weird issues.

First of all my doc class is not extending a sprite (as I see most PV examples doing). Not sure if that's effecting my results. Here is a sample of my code:

public class eniac extends Application {

    import org.papervision3d.cameras.CameraType;
    import org.papervision3d.objects.primitives.Plane;
    import org.papervision3d.materials.MovieMaterial;
    import org.papervision3d.render.BasicRenderEngine;
    import org.papervision3d.view.BasicView;

    private function initEngine():void {
         view = new BasicView(stage.stageWidth, stage.stageHeight, true, true, CameraType.FREE);
         addChild(view);
    }
}


Basically, it's placing everything on stage but the viewport is being positioned incorrectly ie. the top left of the viewport is centering in the middle of the stage. I'm not exactly sure what may be wrong.

Thanks in advance!

Dave


_______________________________________________
Papervision3D mailing list
[hidden email]
http://osflash.org/mailman/listinfo/papervision3d_osflash.org