I’m trying to set an orthographic lens for an alternate graphics buffer which is applied to a texture as in the teapot tutorial. I can’t figure out which object to call the setLens() method on, though.
#we now get buffer thats going to hold the texture of our new scene altBuffer=mainWindow.makeTextureBuffer("hello", 256, 256) #now we have to setup a new scene graph to make this scene altRender=NodePath("new render") #this takes care of setting up ther camera properly self.lens = OrthographicLens() self.lens.setFilmSize(20,15) self.altCam=base.makeCamera(altBuffer) self.altCam.setLens(lens) self.altCam.reparentTo(altRender) self.altCam.setPos(0,-10,0)
I’ve tried the setLens(lens) method on the altCam object but it returns: AttributeError: ‘libpanda.NodePath’ object has no attribute ‘setLens’
Is this the wrong object or am I possibly doing something else wrong?
Any help would be appreciated, thanks,