Home Artists Posts Import Register
Join the new SimpleX Chat Group!

Content

Welcome to the blog post where I reveal the biggest secret of how I set up my foliage. I'm partly kidding because it's actually quite simple, it's not really a secret and it's relatively easy to replicate. For this tutorial we will use Blender and Unreal Engine. 

  • Mesh setup

To make the tutorial 100% replicatable, we will use this resource for free tree meshes.

https://forums.unrealengine.com/community/community-content-tools-and-tutorials/82804-free-trees-library 

My personal favorite is beech.

It doesn't matter what you use though, other free resources created extremely similar results. The target poly count is 3000-5000,

  • Spherical normal editing

Normal editing will allow the tree to look smooth, similar to what The Witness achieves. This reduces a lot of noise in the foliage, which creates the cel shaded look. I use Blender and I'm sure other programs have the same feature. 

Place the tree and a sphere with its center point at 0,0,0.  Selecting the tree, enable "Normal edit" under modifiers. Target the object to the sphere. 


Mix factor adjusts the strength of the normal edit. Importantly, I tend to set it at .8 to keep a bit of noise. 1.00 tends to simplify the mesh too much.

The result (Left- before Right- after)
Additional tutorial here on normal editing

  • Shadow sharpen

UE has a shadow sharpen feature under the directional light. Just crank that thing up and tadaaah! Cel shaded, smooth and fluffy trees without any post processing or advanced materials. 

I do like it without sharpen though, they both look good in different ways (´∀`)

  • Material breakdown


Disclaimer: Copying the parameters will not produce the same result. Please adjust them to your liking.

Overall structure


Let's start with color noise. This adds a subtle variation in color. Add a black and white noise texture in worldspace.


Demonstration


The lerp will feed into another lerp. This will control color falloff. Based on the player's distance, the trees will be less vibrant in thr background, blending into the mountains.
Is it necessary? Probably not but color theory 101 explains that important and closer objects should have higher contrast and saturation in color. 
 

Demonstration


It will finally be added with a texture with a solid color and into the base color. Feel free to change it to a constant for flexibility.


We can just input the alpha of the main texture into the opacity mask, but I'd rather optimize transparency and lerp it between a white alpha map. Based on the player's distance, the alpha will lessen, reducing overdraw. This was inspired by Unity's alpha cutoff, which UE apparently does not have.


Demonstration


Misc.

We're done!
Hopefully the tutorial is easy to follow, but if you are stuck on anything or things are too confusing, please contact me on Twitter or Patreon. I'll do my best to respond. 

Thank you for reading! (≧▽≦)

Files

Comments

No comments found for this post.