Creating the Parallax Effect With the Power of OSL and JIWindowbox

Art Maknev told us about a new tool called wParallax, discussed its advantages, and showed us how wParallax uses OSL and a wonderful script called JIWindowbox to create realistic fake interiors.

Introduction

My name is Art Maknev, I am an Archviz 3D Artist with over 14 years of experience in the CG industry. Ever since graduating from an Architectural University (in 2006, Michigan, USA), my first job was in a 3D company, making renders for real-estate projects, this is what I enjoy doing the most. Over the years I have worked with The7thArt, Skidmore Owings & Merrill, Visualhouse, and BBG-BBGM, all based in New York, Eve-Images, and XOIO based in Germany. More recently, I have decided to change my life a bit and move from the US to Europe while doing freelance work for international companies. Currently, I work in Berlin, Germany.

The wParallax Project

wParallax started as a hobby project in 2020 during the coronavirus quarantine times. I was always fascinated with the parallax effect in video games, such as Spiderman and Forza Horizon 4, and was wondering if such a thing was possible in 3ds Max for the Archviz industry. This technology could save a huge amount of time and money when making exterior visualization.

To my surprise, I found one person who has written an OSL shader that replicates the same exact effect! The OSL shader is called JIWindowbox and it was created by Julius Ihle. However, there was a big issue with the original script for longer parallax effects (walls were getting really distorted) and this issue has kind of stopped me from playing with the shader for some time until David McDonnell posted a windowAspect fix on Facebook, it was a game-changer, now it was possible to create really long spaces without wall distortions.

The process of making the visuals for wParallax took quite a bit of time, I had to recreate 3D spaces, have nice furnishings and realistic lighting, it was also important to try different angles and create further fake perspective tricks in those visuals (extra rooms within rooms). In the end, I also figured that it would be great to create both night and day versions of the same space, which would give some flexibility for Archviz projects.

Also, some scenes are converted from CGtrendy libraries, which I and my friend have started, those scenes are modeled to be low poly and clean, for quick merging. We plan to release more scenes together for wParallax and CGtrendy soon.

Implementing OSL and JIWindowbox

The best part about OSL (Open Shading Language) is that it can be implemented in different software and render engines, 3ds Max, Cinema4D, Blender, Vray, Corona, Octane, etc. And the beauty of JIWindowbox OSL Shader is that it only needs one EXR texture to create the parallax effect, you just connect its self-illumination slot, and it's done.

The EXR texture can be easily adjusted in Photoshop, so you can simply change different furniture, add people/curtains, etc. Then resave it as an EXR again and render, it will automatically update with new furnishings, so in that way, I was able to create different room types, offices, and shops. You just have to follow the EXR file layout, there are 9 boxes, each box indicates the specific spot for curtain, furniture, floor, wall, etc.  

It is very easy to use OSL shader, you basically just open the OSL and load the EXR file, it really is a 2 step process. You can view a quick tutorial here:

The System's Advantages

The main advantage is that it is super fast to populate a building and at the same time it keeps the file size very small compared to the traditional method, that is why it is used so successfully in the video game industry.

There is also a workaround for software or render engines that do not support OSL yet (Sketchup, Lumion, Cinema4D + Vray/Corona). That is not a problem, there is an option to use the "unwrapped box" that comes with the free scene or purchased files, you can simply apply the same EXR texture to that box and you get a very similar effect like on a plane, this trick also works well in Unreal Engine:

Modification Options

Besides the standard OSL shader options of moving and hiding objects, the shader can be expanded into a very advanced setup in 3ds Max (2019 and above). For example, here is a video by Eloi Andaluz Fulla, he managed to add a lot of variation to a single EXR map with the use of various OSL nodes:

Future Plans

There are some exciting new updates coming very soon, thanks to Pixamoon and Marko Margeta for their coding support! 

The original JIWindowbox OSL only supported one curtain layer and one furniture layer, however, these guys were able to add two additional layers. So now it will be possible to have two furniture layers and an extra layer to add people, to create an even stronger parallax illusion. Pixamoon has also achieved some remarkable effect with transparency, it was requested by many people. With this option you will be able to hide walls, this is very useful for office buildings.

Many people have asked about Unreal Engine support, and honestly, I didn't believe it was possible until Marko has shown me his progress. He has successfully recreated a shader in Unreal based on the original OSL of JIWindowbox. The result is almost exactly like in 3ds Max and other software! I hope that this shader will be available for download very soon, Marko is still implementing final touches and waiting for approval from Unreal Marketplace. Once his shader is available, hopefully, it will be useful for the game industry as well!

In the coming future, there will be more collections of EXR maps coming, new retail, lobbies, and even a People Pack. We are working together with Humano to convert some of their high-quality 3D people into a 2D People pack to work nicely with wParallax maps, you will be able to turn the people layer on/off just like the furniture layer.

So stay tuned, more is coming soon! 

Art Maknev, 3D Artist

Interview conducted by Arti Sergeev

Join discussion

Comments 0

    You might also like

    We need your consent

    We use cookies on this website to make your browsing experience better. By using the site you agree to our use of cookies.Learn more