Currently textures in Minetest are repeating, for example here all cobblestone nodes are visually made up of the same small stones positioned in the same way everywhere:
Here is the same image with stochastic texture sampling used for all nodes:
Whether stochastic texture sampling looks good depends on the texture, some parameters and opinion. In this case, it looks bad for the mese lamp (in my opinion) because the mese lamp texture should repeat.
I partly implemented stochastic texture sampling in Minetest some time ago and didn't continue because I don't know if it's worth the code complexity.
More screenshots: https://forum.minetest.net/viewtopic.ph ... 24#p423224
The code can be found on this branch in my Minetest fork: https://github.com/HybridDog/minetest/t ... e_sampling
In addition to stochastic texture sampling in Minetest, I have implemented a demonstration program in a single HTML page: https://hybriddog.github.io/stochastic_ ... ling_demo/
(source: https://github.com/HybridDog/stochastic ... ling_demo/)
It allows testing the algorithm with any SDR texture, for example default_stone.png:
It is also possible to implement the algorithm with SVG filters, which I have tried at https://codeberg.org/HybridDog/sts-svg
With stochastic texture sampling, it is possible to re-use only high frequency details of textures, which makes nodes look more natural, adds visual variety, and prevents artifacts which are visible when a wall of the same node is watched from far away.Stochastic Texture Sampling
- Hybrid Dog
- Member
- Posts: 2853
- Joined: Thu Nov 01, 2012 12:46
- GitHub: HybridDog
Stochastic Texture Sampling
Last edited by Hybrid Dog on Sun Apr 13, 2025 10:34, edited 2 times in total.
Re: Stochastic Texture Sampling
Looks cool! I know there is also seed related textures, called global textures, but MTG doesn't use them.
Who is online
Users browsing this forum: No registered users and 0 guests