Euphoria
|
Classes | |
struct | SphereObject |
struct | DiffuseMaterial |
struct | MetalMaterial |
struct | DielectricMaterial |
struct | Camera |
struct | ScatterResult |
struct | Material |
struct | Collision |
struct | Object |
struct | Scene |
Functions | |
std::shared_ptr< Object > | create_sphere (const Sphere &sphere, const vec3f &position, std::shared_ptr< raytracer::Material > material) |
Rgb | to_rgb (const unit3f &normal) |
vec3f | get_random_vec3_in_unit_sphere (Random *random) |
vec3f | get_reflected (const vec3f &v, const unit3f &normal) |
std::optional< vec3f > | get_refracted (const unit3f &uv, const unit3f &normal, float ni) |
float | calc_fresnel_factor (float cosine, float ref_idx) |
std::shared_ptr< Material > | create_diffuse_material (const Rgb &albedo) |
std::shared_ptr< Material > | create_metal_material (const Rgb &albedo, float fuzz) |
std::shared_ptr< Material > | create_dielectric_material (const Rgb &albedo, float refractive_index) |
Rgb | get_color (const Scene &scene, const UnitRay3f &ray, Random *random, int depth) |
Rgb | correct_color_using_gamma2 (const Rgb &color) |
void | raytrace (Image *aimage, const raytracer::Scene &scene, int number_of_samples) |
std::shared_ptr< Object > | create_sphere (const Sphere &sphere, const vec3f &position, std::shared_ptr< Material > material) |
Function Documentation
◆ calc_fresnel_factor()
float eu::core::raytracer::calc_fresnel_factor | ( | float | cosine, |
float | ref_idx | ||
) |
Definition at line 248 of file raytracer.cc.
◆ correct_color_using_gamma2()
Definition at line 460 of file raytracer.cc.
◆ create_dielectric_material()
std::shared_ptr< Material > eu::core::raytracer::create_dielectric_material | ( | const Rgb & | albedo, |
float | refractive_index | ||
) |
Definition at line 356 of file raytracer.cc.
◆ create_diffuse_material()
Definition at line 328 of file raytracer.cc.
◆ create_metal_material()
std::shared_ptr< Material > eu::core::raytracer::create_metal_material | ( | const Rgb & | albedo, |
float | fuzz | ||
) |
Definition at line 341 of file raytracer.cc.
◆ create_sphere() [1/2]
std::shared_ptr<Object> eu::core::raytracer::create_sphere | ( | const Sphere & | sphere, |
const vec3f & | position, | ||
std::shared_ptr< Material > | material | ||
) |
◆ create_sphere() [2/2]
std::shared_ptr<Object> eu::core::raytracer::create_sphere | ( | const Sphere & | sphere, |
const vec3f & | position, | ||
std::shared_ptr< raytracer::Material > | material | ||
) |
Definition at line 80 of file raytracer.cc.
◆ get_color()
Rgb eu::core::raytracer::get_color | ( | const Scene & | scene, |
const UnitRay3f & | ray, | ||
Random * | random, | ||
int | depth | ||
) |
Definition at line 371 of file raytracer.cc.
◆ get_random_vec3_in_unit_sphere()
Definition at line 136 of file raytracer.cc.
◆ get_reflected()
Definition at line 171 of file raytracer.cc.
◆ get_refracted()
std::optional<vec3f> eu::core::raytracer::get_refracted | ( | const unit3f & | uv, |
const unit3f & | normal, | ||
float | ni | ||
) |
Definition at line 227 of file raytracer.cc.
◆ raytrace()
void eu::core::raytracer::raytrace | ( | Image * | aimage, |
const raytracer::Scene & | scene, | ||
int | number_of_samples | ||
) |
Definition at line 466 of file raytracer.cc.
◆ to_rgb()
Definition at line 125 of file raytracer.cc.