Fade in/Out in C++

Just in case you guys are still interested, this is quiet a simple solution: