Skip to main content

Experiments with Textures - Part I

As mentioned in my previous post, the development on my game is going through an almost complete overhaul. Everything from textures to models are getting changed or optimized. However the level layout remains pretty much the same for now. Moreover I've taken a liking to the 3rd person view, so I'll most probably end up using that as the default view in the game. I feel that it kind of gives a better sense of the scale of the level. I may add an optional 1st person view later on.

Anyways my initial search for a new texture for the walls from some of the popular free texture sites ended up in vain, as I didn't get anything satisfactory. But somehow after almost a day of searching, I ended up in deviant art. And there I found the perfect texture in the gallery of the user AGF81. It was a seamless texture and had a pretty good variation in the size of bricks. Plus it came in a power of two resolution, which means I didn't have to do any cropping or resizing in order to import it into UDK. Also AGF81 was kind enough to let everyone use his textures for their personal uses. A thousand thanks to him. You can find his page in the link given below. He has lots of good textures in his gallery.

http://agf81.deviantart.com/

So basically this is the texture that I've selected for the walls. The color doesn't match the one I want, but I've already managed to change it in UDK's Material Editor. So that's not a problem.


Stone Texture from DeviantArt

The texture is pretty good by itself, it has some good details that can be extracted into normal and height maps. But as I realized during my previous iterations, when you directly apply it to a static mesh in UDK, it will look like some poster that is stuck on top of some rock rather than actual bricks. I didn't want to make the same mistake again. So I thought about ways to make it more realistic, and then the idea struck me. I could get the normal and height map from it using CrazyBump and rather than directly using it in UDK, I could first use it on a plane mesh in Blender. I could then amplify the details on the plane using the displacement modifier. Of course the mesh had to be a very high-poly in order to get the fine details right. I could then bake the details onto a low-poly version of the mesh using xNormal. Below are the original normal and height maps that I made using CrazyBump.

Original Normal Map

Original Height Map
                                                                 
Using them on the high poly plane mesh in Blender, and then baking the textures into the low poly version using xNromal, I was able to generate my new normal map, height map and ambient occlusion map.


Enhanced Normal Map

Enhanced Height Map

Enhanced A.O. map


I tested out these new textures on a plane mesh in Blender to see the rendered results before proceeding any further. Both using the default Blender Render as well as the Cycles Render. 


Blender Render 

Cycles Render (Used A.O. map and controller specular effects, hence less concentrated reflection)

I was pretty satisfied with the results. But just out of curiosity, I applied the same process once more to see if it would provide better results.

Another pass in Blender Render

There seems to be a noticeable increase in depth, but it kind of became overkill. There were just too many unnecessarily amplified distortions. So I just decided to stick with previous version. It had the right amount of beauty. This one seemed like it had an obvious layer of additional make-up. So basically I got my normal map, height map and A.O. map ready for use in the game. I made some changes to the original diffuse texture as well, but I'll give a detailed description about that in the next post. This post has already become a bit lengthy. Alright so that's it for now. Goodbye.

Popular posts from this blog

Unreal Engine 4 Tutorial: Smooth Zoom using Mouse Wheel for Top Down Template

Well, I had already written a tutorial for implementing Smooth Zoom functionality for Top Down Template. But it was based on keyboard inputs. Since most Top Down PC games use mouse wheel for zoom, I decided to make a tutorial for the same. The core logic here is the same as the one implemented by Ryan Jon for the custom camera in his RTS Community Project. If anyone's interested, they can get the code for the RTS Community Project here:

UE4 RTS Community Project

Anyways, he has replaced the default camera for the characters with a general camera since that's more ideal for developing an RTS game. Since a basic Top Down game with a single playable character does not need a separate custom camera, I decided to implement the same functionality for the default player camera in UE4's Top Down Template. So let's get down to it.

First of all we need to make a custom curve from the content browser. We will be using this curve to define the smooth camera movement while zooming …

Unreal Engine 4 Tutorial #4: Basic HUD Based Command UI for Top Down Turn Based Games

Hi, welcome back for the next tutorial. And in this tutorial, I'll be explaining how to create a basic Command UI for top down turn based games using HUD blueprints. By the time we reach the end of the tutorial, we'll have a Command UI with movement and fire action commands, and a player character that responds to the commands. Here's a screenshot showing the end product: 


Oh, and this tutorial is gonna be quite big, compared to earlier ones. So I advise everyone to go through the screenshots, before reading through. If it's clear, there's no need to read through the whole thing, partly because I've written this with a beginner audience target in mind. Ofcourse, if you have doubts, I hope they will be clarified in the written description. If not, feel free to ask me in the comments.
So let's get started. Again, I'll be starting with the top down template. First of all, we need to create a new HUD blueprint. If you're a beginner, you can find this by f…

Unreal Engine 4 Tutorial #3: Unit Selection Decals for RTS Games

Hi, welcome back for another UE4 Tutorial. This time, I'll be walking you through how to set up unit selection decals for RTS games. So the decals need to be visible, when a particular unit is selected, and set to hidden as soon as the unit is deselected. For this tutorial, I'm gonna start off from the Unreal Top Down Template.

First of all, I'll be changing the default controls a bit. Instead of using left mouse button to move the units, I'll be using right mouse button for character movement. I already have a decal texture, that I created in GIMP. If you don't have one, you could get my decal texture from the link below:
DropBox: Character Selection Decal Texture
So once you have the texture ready, next step is to set up your decal material. For creating a decal material, we need to set the 'Material Domain' in the details panel to 'Deferred Decal'. I'm also setting the blend mode to 'Emissive' in my case. Then we multiply the texture wit…