Start learning with our library of video tutorials taught by experts. Get started
Viewers: in countries Watching now:
Follow a practical guide to building 3D cityscapes for games. IAuthor Adam Crespi constructs a city block in 3ds Max utilizing low-polygon modeling and advanced texturing techniques. The course shows how to model common city elements such as buildings, intersections, curbs, and roofs and explains how to expand a city quickly and easily by reusing existing geometry in a modular way. The course also sheds light on simulating real-world detail with baking, lighting, and ambient occlusion techniques and offers a series of best practices for exporting to the Unity gaming engine.
When we are rendering ambient occlusion, we want to keep several things in mind so we get a successful bake of our occlusion. The first part of successful ambient occlusion actually starts with modeling. Objects need to be in the real size of the real world object. That is, this door is 10 feet tall. I model that as 10 feet tall in 3ds Max. To tune occlusion, I'll take my warehouse and for this example I have generated some ambient occlusion shaders here in the Material Editor. For games, we would actually use the Render to Texture dialog, but this allowed me to render and show this material a little more clearly.
To start, I have an AO moody material I'll assign to this warehouse. Ambient Occlusion can be placed in a mental ray shell, which is what I've done here for ease-of-use. In the Ambient Occlusion shader, there are several main factors we need to adjust. The first of these is the Max distance. Max distance in a scene is the distance at which objects cast and then stop casting occlusion on each other. I will render this example. In this rendering, that Max distance of 90 produces deep spreading shadows in the corners and on the base of the building.
Changing that distance to a Max distance of 24 produces far softer occlusion over a smaller area. For comparison, I'll change my Area to Render to a Region and make the region go over part of the garage door, wall, and window. When I hit Render again, we will see a dramatic difference. With the Occlusion Max distance at 24, we get slimmer lines of darkness in the corners and surfaces that were cloudier, such as the slide of the window here, are far clearer and brighter. I will move the region over, just to be able to show this a little closer to the camera.
Once we have decided on a Max distance, which is really affecting how does the gloom spread on the building, we want to look at Spread. For this comparison, I'll put my Max distance back up to 60. For the Spread, the higher that goes, the more the darkness spreads into that zone of occlusion determined by the Max distance. When I take the Spread down to say 0.3 and hit Render again, we will see the darkness really cluster in the corners. We get deeper, harder lines and not as much darkness spreading on the surface. If we look closely where the side wall, the ceiling and the window intersect, you can see this phenomenon.
The darkness is in the corners and curves nicely up to meet versus spreading across the wall. In addition to Spread and Max distance, we want to consider the Bright and Dark values. They don't have to be the black -and-white they start out as. This is an artistic choice. I will jump to Photoshop to illustrate this. In Photoshop, it's very common to take an occlusion map, such as I have several of here, and layer it over a diffuse map to get the proper darkness. This is a raw diffuse map where the color showing is really the raw diffuse channel of that material.
When I lay occlusion over it, I will set the occlusion as a Multiply blending mode. We can do this either here in the texture or in the game engine occasionally. Depending on the blending mode we choose and the Opacity, we get different looks in the occlusion. Changing that blending mode across to Color Burn produces gloom and spreading blackness. We may or may not want this so we need to play with it. Part of that is determined by what color that dark value is. In these renderings, my dark value started out as black.
Here's the raw occlusion. So multiplying the color I have by this gray and black produces that depth in the scene. I will go back to 3ds Max and make a change to this. In 3ds Max if I take the dark color from black and boost it up to a sepia tone, adjusting the Hue and Saturation to give me more of a warm brown. In this case, this will produce that brown in the corner as the maximum dark value. I will hit Render to show this.
When this multiplies over a texture, we will get a far different look and a less heavy rendering than that black. These are the three main things to keep track of in the occlusion when tuning the cinematic look. What does the max distance or how much does the occlusion spread across the objects? Where does the occlusion go? Clustered in the corners or spreading into that zone? And finally, what is the darkest color, because this will lay over another color? The samples in the ambient occlusion shader determine the quality. A low sample rate such as 16 produces dots in the occlusion.
We can start to see some dots right below this sill. We may not want that in our texture. Increasing the samples produces a better quality occlusion at a higher cost and rendering time. Upping the samples to 128 produces very smooth occlusion with an increase correspondingly. With samples of 128, the occlusion is nice and smooth. Ambient occlusion is a terrific tool for us to add more detail. What we need to do is to craft it. It's never just set in stone. We can always change things and what we want to think of as part of our conception or our thinking about the cinematic mood of our imagery when we are playing the game is how do we want to tune the occlusion? Were does it go, what color is it, and how do our corners look?
There are currently no FAQs about Creating Urban Game Environments in 3ds Max.
Access exercise files from a button right under the course name.
Search within course videos and transcripts, and jump right to the results.
Remove icons showing you already watched videos if you want to start over.
Make the video wide, narrow, full-screen, or pop the player out of the page into its own window.
Click on text in the transcript to jump to that spot in the video. As the video plays, the relevant spot in the transcript will be highlighted.