Terrain Layers Issues (Terrain alphamap texture must be in RGBA32 format)

I just upgraded to the latest version from 5.3.7 and I’m running into an issue with the new “Per Terrain Layer Modifications” stuff. I’ve added a couple terrain layers to the list and set them to “Unwalkable Surface” to exclude them from the scan, but when I press the scan button it doesn’t scan and gives me an error:

There was an error generating the graphs:
UnityEngine.Assertions.AssertionException: Terrain alphamap texture must be in RGBA32 format.
Assertion failure. Value was False

Is there something I’m missing here or is this a bug? I don’t know how to change the format of the alphamap (splatmap) textures, or if it’s even possible? Does it actually even really need to be RGBA32 format? The terrain in question seems to have two splatmaps under it in the project folder, both in ARGB8 format.

Also, I’m using Microsplat, but I don’t think that should effect the format of the splatmaps.

Additional details:

This is a Recast Graph (Voxel Size: 0.05, TileSize: 64)

Terrain width/length is 500 x 500

Heightmap Resolution is 513 x 513

Control Texture and Base Texture Resolution are 1024 x 1024

Ok, figured it out. It was only failing to scan in some scenes, but worked just fine in others. The ones that didn’t work were created in an older version of unity (2018 or 2019). These terrains were using an ARGB8 format instead of the RGBA8 format that the terrains in all the newer scenes were using. So, I guess at some point unity switched the terrain splatmaps from using ARGB to RGBA?

I fixed it by using the Terrain Toolkit to export the splatmaps from the old terrains, then just reapply them. This automatically put the splatmaps into the RGBA format and everything works as expected now. So, if anyone else runs into this issue, I guess that’s how to solve it.

1 Like

Thanks for posting your solution!