Classes | Macros | Functions
raytracer.cpp File Reference
#include "raytracer.h"
Include dependency graph for raytracer.cpp:

Go to the source code of this file.

Classes

struct  raytracer_params
 

Macros

#define expect(a)
 
#define expect_s(a, s)
 
#define jo_expect_array(a)   (a!=0 && json_object_is_type(a, json_type_array))
 
#define jo_expect_array_size(a, n)   ( (a!=0) && (json_object_is_type(a, json_type_array)&& (jo_array_length(a)==n)))
 
#define jo_expect_array_size_min(a, n)   ( (a!=0) && (json_object_is_type(a, json_type_array)&& (jo_array_length(a)>=n)))
 
#define jo_expect_object(a)   (a!=0 && json_object_is_type(a, json_type_object))
 
#define jo_expect_string(a)   (a!=0 && json_object_is_type(a, json_type_string))
 

Functions

double cosine_between_angles (double a1, double a2)
 
bool load_env_from_json (Environment &env, JO jo)
 
int main (int argc, const char **argv)
 

Macro Definition Documentation

#define expect (   a)
Value:
if(!a) { \
sm_error("Invalid format: \n\t %s \n", #a); \
return false; \
}
void sm_error(const char *msg,...)
Definition: logging.c:49

Definition at line 132 of file raytracer.cpp.

#define expect_s (   a,
 
)
Value:
if(!a) { \
sm_error("Invalid format: %s \n\t %s \n", s, #a); \
return false; \
}
void sm_error(const char *msg,...)
Definition: logging.c:49

Definition at line 137 of file raytracer.cpp.

#define jo_expect_array (   a)    (a!=0 && json_object_is_type(a, json_type_array))

Definition at line 125 of file raytracer.cpp.

#define jo_expect_array_size (   a,
 
)    ( (a!=0) && (json_object_is_type(a, json_type_array)&& (jo_array_length(a)==n)))

Definition at line 128 of file raytracer.cpp.

#define jo_expect_array_size_min (   a,
 
)    ( (a!=0) && (json_object_is_type(a, json_type_array)&& (jo_array_length(a)>=n)))

Definition at line 129 of file raytracer.cpp.

#define jo_expect_object (   a)    (a!=0 && json_object_is_type(a, json_type_object))

Definition at line 126 of file raytracer.cpp.

#define jo_expect_string (   a)    (a!=0 && json_object_is_type(a, json_type_string))

Definition at line 127 of file raytracer.cpp.

Function Documentation

double cosine_between_angles ( double  a1,
double  a2 
)

Definition at line 142 of file raytracer.cpp.

bool load_env_from_json ( Environment env,
JO  jo 
)

Definition at line 147 of file raytracer.cpp.

int main ( int  argc,
const char **  argv 
)

Definition at line 17 of file raytracer.cpp.



csm
Author(s): Andrea Censi
autogenerated on Tue May 11 2021 02:18:23