#include <MirrorShader.h>
Definition at line 16 of file MirrorShader.h.
Public Member Functions | |
MirrorShader (Scene *scene, const ColorRGBA &reflection) | |
Initializes the shader with the scene and the basic reflection. | |
~MirrorShader () | |
ColorRGBA | Shade (Ray &ray) |
The ray is mirrored and traced back. After that it is multiplied with the reflection color. | |
Private Attributes | |
ColorRGBA | reflection |
The color of the reflection. |
Initializes the shader with the scene and the basic reflection.
Definition at line 30 of file MirrorShader.h.
MirrorShader::~MirrorShader | ( | ) | [inline] |
Definition at line 33 of file MirrorShader.h.
The ray is mirrored and traced back. After that it is multiplied with the reflection color.
ray | The ray, that hits a surface that is associated with this shader. |
Implements Shader.
Definition at line 40 of file MirrorShader.h.
References Ray::bounces, Ray::dir, Dot(), Primitive::GetNormal(), Ray::hit, Infinity, Ray::org, Scene::RayTrace(), reflection, Shader::scene, Ray::t, Ray::u, and Ray::v.
ColorRGBA MirrorShader::reflection [private] |
The color of the reflection.
ColorRGBA reflection
Definition at line 23 of file MirrorShader.h.
Referenced by Shade().