![]() This allowed me to specify textures for a grass floor, a rock wall and a cave roof. When texturing a mesh-based procedural terrain, I used a custom shader which calculated the normal vector of the surface in world space and used the relative weight of the x, y and z vectors to blend between three textures specified by the user. This was quite some time ago, so excuse the vagueness but. Obviously you can tweak the number of samples and relative weighting to get the effect you want.Ī separate technique I've used elsewhere is to use the normal of the surface to blend between three textures. ![]() That way, when you're up close, the detail is clearly visible and the lower amplitude blurs of lower octaves are barely visible, whilst at longer range, the lower frequency features -that span multiple tiles- tend to dominate. (You can read more about a related technique as used for generating procedural terrains here: - particularly "1.3.3 Making an Interesting Density Function" which mentions other ways to break up repetition like warping coordinates for higher octaves)īut the key takeaway is that you blend multiple copies of the (texture|noise) at different scales with varying weights.Īs an example, you might pick (pseudocode) color = texture_at(x, y) *. ![]() ![]() ![]() Apply multiple "octaves" of textures/noise to avoid repetition. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |