I am trying to get a natural looking landscape like the game Terraria. I use a cellular automaton to generate caves and 1d Perlin noise for surface. The result is something like this: my prototype
But this is not satisfactory to me because the original goal was to get something like that: what i want to get
I know that in the second case, Perlin noise is also used, but I have absolutely no idea how to achieve exactly this. Can someone suggest how I can achieve the second case with Perlin noise or not and/or give appropriate links on this topic ?