#pragma once

#define NUM_RENDER_THREADS 2
#define PIXEL_STEP 1
#define TILE_SIZE 10
#define MAX_DEPTH 4 //maximum recursion depth
#define EPSILON 0.00001
//#define SAVE_INTERMEDIARY
#ifdef SAVE_INTERMEDIARY
	#define RENDER_TEMPDIR_NAME string("render")
	#define RENDER_TEMPDIR_SCENE (RENDER_TEMPDIR_NAME+string("/scenetemp.txt"))
#endif
#define SPEED
#define USING_BVH

//#define OUTPUT_BVH_HEATMAP
//#define OUTPUT_T
#ifdef OUTPUT_T
	#define OUTPUT_T_NEAR 1.5
	#define OUTPUT_T_FAR 11.0
	#define OUTPUT_T_R 0.0
	#define OUTPUT_T_G 1.0
	#define OUTPUT_T_B 0.0
#endif
//#define OUTPUT_NORMAL
//#define OUTPUT_REFLECTION
//#define OUTPUT_REFRACTION //TODO
//#define OUTPUT_ABS
//#define OUTPUT_UV_DIFFUSE

#define ALLOW_AMBIENT
#define ALLOW_DIFFUSE
#define ALLOW_SPECULAR
#define ALLOW_SHADOWS
//#define ALLOW_REFLECTIONS
//#define ALLOW_REFRACTIONS
#define ALLOW_BACKGROUND

#define SAMPLES_SHADOW_DEFAULT 1
#define SAMPLE_TEXTURE_DEFAULT 4
#if SAMPLE_TEXTURE_DEFAULT==1
	#define SAMPLE_TEXTURE_DEFAULT_NEAREST
#elif SAMPLE_TEXTURE_DEFAULT==2
	#define SAMPLE_TEXTURE_DEFAULT_BILINEAR
#elif SAMPLE_TEXTURE_DEFAULT==3
	#define SAMPLE_TEXTURE_DEFAULT_BICUBIC
#elif SAMPLE_TEXTURE_DEFAULT==4
	#define SAMPLE_TEXTURE_DEFAULT_GAUSS
	#define SAMPLES_GAUSS_DEFAULT 4
#endif

#define NUM_RANDOM_DISTR 50 //How many subpixel/aperture sample distributions to generate?
#define NUM_RANDOM_SAMPLES 1000 //The number of samples to generate for the light
#define NUM_POW_TABLE 1000 //How big is the pow cache?

#define MAX_IMAGE_WIDTH 8192
#define MAX_IMAGE_HEIGHT 8192
#define MAX_IMAGE_SAMPLES 65536

#define DEBUG_TOKENS