Add a world generator based on another raytracer file format I made in the past and add a crude tool to run it.

it does not render properly, there are some major differences between both engine especially in the material definition. Will need more work, but is not urgent.
This commit is contained in:
Godzil
2020-02-22 15:16:25 +00:00
parent 4d4c4a7453
commit c9021974f6
4 changed files with 335 additions and 225 deletions

View File

@@ -10,6 +10,7 @@
#define DORAYME_WORLDBUILDER_H
#include <world.h>
#include <camera.h>
/* Let's keep a single header for now, will see later */
@@ -22,7 +23,30 @@ public:
/* Not implemented yet */
class Hw3File : public World
{
private:
Matrix transformStack[50];
uint32_t transStackCount;
public:
double currentAmbient;
double currentShininess;
double currentSpecular;
double currentDiffuse;
double currentEmission;
double currentReflective;
double currentTransparency;
double currentRefIndex;
Colour currentColour;
Matrix cam;
double camFoV;
public:
Matrix getTransformMatrix();
void popTransformMatrix();
void pushTransformMatrix();
void applyTransformMatrix(Matrix t);
Hw3File(const char *filename);
};