Author Topic: Multiple Viewports  (Read 3260 times)

Offline nether

  • byte
  • *
  • Posts: 1
    • View Profile
Multiple Viewports
« on: January 25, 2008, 02:16:27 am »
Hello,

I'm trying to use JPCT to create a simulator for my robotics team.  On the robot are a couple cameras.  Is there a way in which I can have the cameras on the robot read in rendered graphics as well as the one that I am seeing on my screen?  If I can get that to work, I believe it will be a short step to display all 3 of the scenes on the screen simultaneously in the gui.

Thanks for reading,
Jason

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: Multiple Viewports
« Reply #1 on: January 25, 2008, 08:03:34 am »
You can create multiple FrameBuffers and execute the "render sequence" (i.e. clear, render, draw, update, display) for each of them using the same world with a different Camera-instance. You have to change the World's camera for each render, but apart from that, it's should be easy.
« Last Edit: January 27, 2008, 02:22:51 pm by EgonOlsen »