merged generateSparse and generateSkin into one function

Hi!
First I want to stress that I am a newbie in github, git, as well as CuraEngine.
Looking at the code to learn how it works, it appeared to me that the functions "genrateSparse" an "generateSkin" do pretty much the same to find out about upskins and downskins.

Am I wrong to think that these could/should be combined to reduce code duplication as well as increase the efficiency?
This is different between skin an sparse. But I don't think it has to be treated differently...