3D Object Mode (third-person view)
Much like 2D sketches, you can safely assume that your 3D sketches will function the same in the Data Arena. 3D object mode refers to 3D sketches that are focused on looking at a particular scene or object of interest. The da_3D_object_demo_nasa_co2 example demonstrates this (can be found here or located in /local/examples/Processing/demos
in the DAVM file system). A 3D object mode template file is also available.
3D sketches in Processing make use of a hypothetical camera that has its own field of view and perspective. You might notice that objects placed to the far edges of your canvas become warped/distorted. To fix this, make use of Processing’s perspective()
function. You’ll find that the optimal settings on your personal development machine might not translate well to the Data Arena, so the best approach would be to set for your system and then tweak in the Data Arena. While the da_3D_object_demo_nasa_co2 example utilises the PeasyCam camera library, this isn’t a necessity for 3D sketches in this mode, and a camera library/object may or may not be appropriate for your project (the perspective()
function still works without defining a camera).
If you wish to integrate stereoscopic effects into your sketch, the solution isn’t as simple as alternate PGraphics contexts as mentioned previously. A contributed library called Camera3D is a fantastic stereoscopic renderer that also has its own over/under system integrated. Due to the nature of Processing’s architecture, performance can drop very quickly when creating full screen stereoscopic sketches. It does, however, operate well when using Camera3D for small sketch sizes. Processing isn’t built for the performance requirements of the Data Arena’s resolution unfortunately, but it’s always worth experimenting with your sketch anyway.