Landscape Paint tool causes black tiles on terrain

Thanks for your tips guys, but still no luck. I recompiled the shaders a lot, rebuild everything all the time but it still overwrites the section with the selected texture layer. its as if the information are stored in the layerInfo nodes, so as soon as I draw on the terrain that section gets the color information of that layerinfo, so it makes that whole section this selected color. When I now delete those layerinfo’s it goes back to before I started drawing manually, so the base terrain texture is there but the drawn parts are gone.