Today, I'm very short on time so I'll explain things quite briefly (Anyway, you may ask me anything on the comments if you ever have any doubt).
First off, this material was aimed to be used on walls of the houses. The problem was that my houses was pretty low poly, that could be good from a performance view, but I was planing to use vertex color and to use that technique you need a mesh well tessellated... So I went to Maya and I rearranged the topology in order to have more vertex. (From 292 tris to 861... I think some of my teachers would kill me for that polycount).
If you want to give it a try, you may u any tessellated mesh (A cube or a plane will do the job).
Once I've got my mesh and textures imported into Unreal, I started tampering with the material... the beginning was just a basic master material like this one.
Though it seem pretty scary and complex at first glance, it is truly very basic network. These are in fact, 2 materials merged in a single one. We are lerping the input for every channel using the red color from the vertex. Also, as an extra and because this is aimed for painting houses, I added a parameter to control the color of the plaster material. This is how it actually looks like.
Right now our material is not bad, in fact, the material I made for my demo in UDK was pretty similar, but if you keep an eye on real world, cracked wall don't have that smooth blend.
So, I launched photoshop and I made 3 difference clouds textures, packed them in a single texture...anyway, I've could have used the mask I made for the sea material but I dind't remember I already made one.
The noise mask texture I've used for blending |
Use this as your alpha for every mixing lerp |
As you see, the blending is way better, but I missed something more and, usually, you would expect that plaster cast some little shadow on the brick (after all, plaster is pretty thick and paint over the bricks).
First I tried to fake the shadow by just offsetting a little my mask and multiply it in the color, but the result was not good at all, so I discarded that. Since this was a gray colored mask, I realised i could use this as a heightmap, and even convert it as normal map.. And I discovered some nice little material functions in Unreal. I was tempted to use the NormalFromHeightmap function but the input was a Texture2D object and not a Float4 as I required. Then I found the NormalFromFunction node which is the same function but it accepted as input 3 Float3. These inputs are in fact the same input but with their UVs off-setted just a little.
This is how I implemented it.
As you see, I have cloned 3 times the code of the alpha mask and then offset the UVs just a little. The result of theses 3 functions was then merged into the NormalFromFunction node, having as a result a cheap, but good enought normal map which will be mixed with the lerped normals. The NormalFromFunction node is actually a material function shipped with UE4. You may as well check how it works inside by just double clicking on it, and even modify it (at your own risk).
NormalFromHeightmap and NormalFromFunction can be both used to generate normals maps on the fly |
And this is ending the result.
The alpha mask can also be used as a heightmap, and hence, with a little work you may also add some parallax or tessellation to your material. I didn't do it this time but that's something you may do it on your own.
Nice post!
ReplyDeleteI'm trying this out but not getting the results you are. Can I ask what you have your offset numbers set to in the procedural normal section? ie. The four scalar parameters on the far left
Or do you have higher res screenshots, I may also have some nodes completely wrong.
Cracked Wall Material ~ Yet Another Developer'S Blog >>>>> Download Now
Delete>>>>> Download Full
Cracked Wall Material ~ Yet Another Developer'S Blog >>>>> Download LINK
>>>>> Download Now
Cracked Wall Material ~ Yet Another Developer'S Blog >>>>> Download Full
>>>>> Download LINK Yp
Cracked Wall Material ~ Yet Another Developer'S Blog >>>>> Download Now
Delete>>>>> Download Full
Cracked Wall Material ~ Yet Another Developer'S Blog >>>>> Download LINK
>>>>> Download Now
Cracked Wall Material ~ Yet Another Developer'S Blog >>>>> Download Full
>>>>> Download LINK 0d
Hey, congrats for this cool post.
ReplyDeletePlease, please, please, could you share this material or a better screenshot? The results are way awesome but i am not getting any close.
THANKS A LOT!
You have discussed an interesting topic that everybody should know. for home repairs, wall crack repair, wall crack, fixing cracks in walls you can visit this site sunken floors and piers visit the site to know more about Buildfix Blog.
ReplyDeleteThis comment has been removed by the author.
ReplyDeletePleasant post!
ReplyDeleteI'm giving this a shot yet not getting the outcomes you are. Would i be able to ask what you have your balanced numbers set to in the procedural typical area? ie. The four scalar parameters on the extreme left
Wall Cracks Repair Riverside
ReplyDeleteAs the earth under a slab foundation floor swells and constricts with seasonal temperatures and water accumulation and drying, it'll alter the footing of the slab.
basement waterproofing syracuse ny
Bram Moolenaar is an active member of the open-source development community that released idm serial key (abbreviation for Vi IMproved) back in 1991, a text editor present on UNIX systems, as well as Windows, which unlike other software of this nature offers us different modes to enter the commands.
ReplyDeleteCracked Wall Material ~ Yet Another Developer'S Blog >>>>> Download Now
ReplyDelete>>>>> Download Full
Cracked Wall Material ~ Yet Another Developer'S Blog >>>>> Download LINK
>>>>> Download Now
Cracked Wall Material ~ Yet Another Developer'S Blog >>>>> Download Full
>>>>> Download LINK 3D