@wcb Can you provide repro steps for the bug that you’re describing with terrain texture refinement? Here’s what I tried, but I can’t reproduce it:
- Create a new level with the default 1024 x 1024 terrain.
- Add a terrain texture layer with a grass material.
- Open the terrain tool -> Layer Painter, and use the grass material to paint a blue A in the 0,0 corner, a green B in the 0,1024 corner, and a red C in the 1024,1024 corner.
- Choose “refine terrain texture tiles” from the terrain texture layer tool.
- Save the level.
I’m still seeing the correct colors and materials for A, B, and C in the different corners. Is there an additional step that I’m missing?
As to your question about what “refining” does, and whether or not it would help… When you’re painting with the terrain layer painter, the terrain brush is painting two separate channels of information - terrain color, and layer blend weights. These channels are controlled by the “color opacity” and “detail intensity” sliders. If you set color opacity to 0, you will just paint layer blend weights. If you set detail intensity to 0, you will just paint terrain color. The layer blend weights are stored with the heightmap data, with the weights stored per-vertex. The terrain color is stored into the terrain megatexture.
So… depending on what exactly you’re trying to “soften up”, you might need different approaches. Because the blend weights are per-vertex, the frequency of the weight data is controlled by the “meters per pixel” of the heightmap. This could be anywhere from 1 to 64, where 1 meter is the best resolution you’ll get. The texture blending itself is per-pixel, but the weights are extrapolated from the values at those 1-meter increments. The terrain color has a pixel resolution determined by the terrain megatexture tiles.
The terrain megatexture tiles can be seen in Terrain Editor -> Tools -> Export/Import Megaterrain. Each tile and its resolution is listed there. It defaults to a single tile of 512x512, which means that if your terrain is 1024x1024, you’re getting 2 meters per pixel. As you can see here, when painting with a radius of 0.5, the closest I can put my red dots on the grid is in 2 meter intervals:
Now, in the Export/Import Megaterrain dialog box, you can select the tile and choose “Change Tile Resolution” to set the tile as high as 2048x2048, which gives 0.5 meters per pixel. If I set my radius to 0.25 to make smaller dots, I can space my dots in 0.5 meter intervals:
To get even higher-resolution than this, I can go to Terrain Texture Layers -> File -> Refine Terrain Texture Tiles. This will split every megaterrain tile into 4. Here’s what that looks like before and after:
Now the terrain texture has 4096x4096 total resolution, or 0.25 meters per pixel. You can keep refining even further if you need even higher color resolution, and you can change the resolution on a per-tile basis to get varied resolution in different parts of the level.
This is all a long-winded way to say that refining the terrain texture should help if your issue is with color blockiness. You should also make sure to increase the resolution on the existing tile(s).