I have 13 material in my landscape painting. Althought it should be 12 because I added the black one as index-0 as a workaround for another painting issue I have.
I noticed that in my material window, I have the same problematic textures as in the painting window. I do not recall if it was always the same relation or not.