Real-Time Rendering: Good Enough Can Actually Be Great.
I just spent a week attending the Unreal Academy. This two-day event is designed to teach common people like myself the basics of Epic Games’ Unreal Engine. This particular conference was dedicated to professionals who work in areas such as architecture, automotive, design, and entertainment. Everyone got hands-on experience with the software along with a lot of expert instruction from Epic employees. My big takeaway from this event was that game engine rendering is getting really good. For me, it may be good enough to use as my main rendering technology, and that's great because the advantages of real time are significant.
I’m sure I’m not alone in pondering whether to switch to real-time rendering as a default workflow. The technology is certainly making big strides and can be used effectively in a number of different areas. Game engines and real time is certainly good enough for many projects, but is “good enough” for others good enough for your own project? Let’s take a look.
A Small Primer on Real-Time
Real-time rendering came out of the gaming world. The initial goal was to reproduce a 3D scene as quickly and realistically as possible so gamers could shoot monsters and do other fun game stuff. In the dark ages, this required a lot of little cheats and hacks to keep gameplay interactive. As graphics cards gained in speed, the realism of the scenes naturally got a lot better. Additionally, game creation got a lot easier over time thanks to gaming companies like Unity and Unreal developing and enhancing their authoring tools. We are now to the point where it’s fairly easy for an artist or designer to create fairly realistic scenes in a game engine. This speed and ease of use has allowed game engines to encroach on non-gaming applications such as design and visualization. This is creating an inflection point where the advantages of game engines may outweigh the additional quality gained by rendering offline.
Why Real-Time is Simply Better
There are some very distinct advantages for real time rendering. The most important of these center on speed. Being able to render frames quickly allows you to do a lot of things you can’t do with offline rendering. When real-time is an option, you can adjust materials, lights and cameras in a 3D scene and get immediate results. No need for test renders. This allows you to compose scenes quickly and efficiently.
Another benefit to speed is user interactivity, which allows for new methods of communicating information about your designs. You can do interactive walkthroughs in order to have your clients interact with a building or product. You can build interfaces to change colors and options on a whim. You can go further down the rabbit hole and communicate your ideas in VR so clients can get a visceral sense of a space or design. All of these ways to communicate are only possible in a real-time rendered environment.
The ability to do VR is a big advantage to real-time rendering.
Good Enough or Not Quite Enough?
Interactivity and speed are certainly nice things to have, but the end result still needs to look good. Visual quality is important, but how much visual quality do you actually need? Are you willing to trade a few rendering features for speed? That’s certainly up to you and your clients, but in most cases, it is possible to step into that grey area known as “good enough”. With that in mind, here’s a quick look at how game engines compare offline rendering.
Materials and Shaders - These are easy to create, and most of the interfaces look about the same as you’d find in a standard 3D Suite. Your materials can have multiple textures, effects, and nodes as well as incorporate a variety of shading models. For basic materials, the technology is functionally identical.
The trade-offs happen when materials get more advanced. Optical effects such as reflections are usually either pre-computed or cheated at render time using a 2D effect. True refractions are still a challenge. Another challenge is displacement mapping, which can take too much computing time and may need to be replaced by simpler methods. Advanced surfaces that use sub-surface scattering can be done using screen space effects.
Reflections Can Be Done Fairly Easily in Game Engines
Accurate Refractions, however, may be too much. This was rendered in Maxwell.
Lighting – Most types of lights are supported, which allows you to light your scenes as you see fit. Game engines are increasingly moving towards Physically Based Rendering (PBR) algorithms, so your results look a lot more realistic.
Lighting effects such as global illumination (GI) can still be a challenge. Pre-computing or baking your lighting offline is one option, and engines such as Unreal and Unity offer versions of real time GI, which exchanges a bit of quality for speedy results.
Cameras – Cameras are pretty much on par with offline rendering. Stereo cameras and VR are fairly straightforward. Camera effects such as depth of field can be achieved and the quality is pretty close, though, because it is a post-processing effect, they are not as accurate as they could be. Effects such as motion blur can also be achieved, though typically these are cheated in the game engine using an 2D effect. This is good for most cases, but may create issues if the object is moving in extreme directions.
Depth of Field can get pretty good. Still not perfect.
Color Space – Game engines such as Unreal now support linear color space, which allows for much more realistic final renders. Your lighting behaves as you’d expect in an offline renderer, making it much easier to compose lighting and effects.
Visual Effects – Game engines also offer a number of post-processing effects that usually happen in a compositing suite. Simple tasks such as color correction and tonemapping can add a cinematic look to a a scene. Volumetric effects such as fog can also be achieved.
So, while most of the major rendering features are supported, there are still a number of them which may need to be cheated by the game engine. These are typically effects that are compute-intensive, such as advanced lighting and cameras, as well as materials that require such features as displacement mapping, reflections, refractions, or translucency. If you absolutely need these features, you may have to stick with offline rendering if high quality is your goal.
If you can step nimbly around these problem areas, however, then real-time rendering will most certainly be good enough quality for most scenes.
Interactive Does Not Necessarily Mean Fast.
If you do decide to make the leap to real-time for your projects, you may be surprised at the changes in workflow required to make a scene truly interactive. In an offline rendering world, a large render farm can easily compensate for poorly constructed scenes. The difference between a V-Ray sequence taking a minute per frame to render versus two minutes may not be that big of a deal if you have a dozen CPUs working over a lunch break on the problem.
If you want true interactivity, however, it means that each frame has to render on your workstation immediately (or at least faster than the frame rate of your output.) In most cases, that means less than 1/30 or 1/24 of a second for video and film rates, perhaps even faster for stereo output or interactive gaming. Some games go as high as 90 fps. These speeds mean that you can’t just toss a V-Ray scene into a game engine and expect it to render quickly.
Getting this sort of speed requires preparation of the scene. You basically have to “gamify” your scenes. Geometry needs to be lighter. Lighting may need to be baked. Texture maps may need to be consolidated to reduce overhead. UV Mapping needs to be rational. Extraneous objects may need to be removed or hidden. All of these tasks take time and also require some new skills.
Once the assets are set up, however, everything starts to get faster. Lights can be placed and adjusted in real time, cameras can be moved, and furniture can be rearranged. If you’re working in an environment where there are a lot of iterations, then you can make changes fairly quickly.
If all you’re doing is still images or presentation videos, then you may not yet see much benefit from using game engine technology in your workflow. The real benefits come when you add levels of interactivity to the mix.
But is it Good Enough?
Personally, I think the quality of a top real-time engine is more than good enough to handle most day to day scenes. Yes, you may have to sacrifice some higher-end rendering effects to get there, but are those effects absolutely necessary? That’s really contingent on the project and the client. The advantages of a gaming engine, however, can add a lot of additional features and value to your work. Interactivity, both for the designer and the client, can have a far greater impact than a 100% accurate render.
Remember, rendering is just another form of communication. If the client understands the idea, then, great, it worked!
Regardless, the future will be increasingly interactive, and game engines will become more and more important. If you’re interested in this technology, but haven’t tried it, I would encourage you to do so. Both Unreal and Unity are free to try, so it’s easy to get your feet wet. If you need a little help getting started, we’ve got a lot of great courses on Unreal and Unity here at LinkedIn Learning.
CEO and Chief Revolutionary of Wood Computer
6 年Great article!? With speed improvements coming from the GPUs nowadays, especially CUDA-based architectures, it won't be long until "machinima" becomes a thing (again).? The virtual movie maker 10 years from now won't have to rely on learning BRDF or even what fresnel is; rather, re-creating Toy Story is already achievable today with a higher end PC and a penchant for putting time into Unity, Unreal and learning how to pass objects and materials to & fro from Maya or another DCC. [I suppose it'd be without Tom Hanks' voiceovers, but it'd probably be rendered better].? Best yet, it could be conceivably done in real-time.? It's almost like we're watching the invention of the movie camera all over again.? Exciting times!