There is a limitation for terrain size? Because when the camera if far away from the origin, the paint operation don't work.
To avoid the black lines problem the only solution I found is to use only 4 textures with same brightness and tint.
I found a bug with the shadows baking, after this operation, when I paint, I can see a kind of square around the brush and textures are darker.