Basic real time rendering raytracing in C/C++