Slicing a 3D scene for 2D parallax

It’s been too long since I posted any tutorial stuff. I’m working on a specific thing to do with Jettomero this week and needed to create a dynamic diorama scene without being able to use my game shaders – since the final product will have limited use of shaders/lighting. Since I wanted to keep the look of the game intact I decided it would be best if I used 2D layers for this. Here’s a little sample of the view in Blender3D.

I could have rendered out individual objects into 2D, but this would have not only been time-consuming, but the lighting/shadows and perspective would be difficult to fake. So I used a full scene from the game in Unity3D. It took me a while to find a planet and arrangement that I liked (since it’s all procedural) but I eventually got something that I thought would work.

Here you can see everything is in 3D, but all I really want is a single perspective where I can do some basic panning and zooming. The next step was to cut out all the elements I didn’t need. I removed the skybox as it is easy to add back later, and I also disabled all particles and trails since they’re too dynamic for a looping diorama. I changed the background to white for easy removal later but I could have used any flat colour to key it out.

Now everything is ready for slicing. The most important thing is to avoid slicing down the middle of any small objects, since the parallax will break if those 2 pieces get pulled too far apart. To create each slice I adjust the near and far clipping plane. In this way I can isolate specific 3D sections of the scene and then export a screen capture. Below you can see the back side of the planet, which has a bunch of objects on the backside of the planet too, but these will be blocked by the front layers in the final composition.

I made 3 scene slices, plus a separate layer for Jettomero, which will give me a few more options for animating the diorama layer. Using the magic wand in photoshop it’s easy for me to remove the white space from the background. I add all the layers into a single document.

I export each layer into it’s own file. Then I bring everything into Blender3D. I create planes for each layer and arrange them with some depth – the more space between each layer the heavier the parallax effect will be, (or you can get a similar result by changing the FOV on the camera). Too much depth will completely distort the scene so it needs some careful tuning. I also added a few little drone ships into their own planes which will be able to be animated separately in addition to providing a stronger sense of depth.

That’s essentially all there is to it. It took me several tries to get a scene that worked well since certain elements didn’t always work so well with the layered depth. I’m not sure what other practical applications this kind of thing would have for other people but hopefully you’ve found some of this interesting or helpful. As always, please feel free to message me if you have any questions about the process.