doubleray
Version:
WASM raytracer
55 lines (51 loc) • 1.02 kB
JSON
{
"camera": {
"loc": [5, 0, 0],
"dir": [-1, 0, 0],
"rot": [0, 0, 1],
"depth": 6
},
"global": {
"color": [0.0, 0.0, 4.4],
"c": 10,
"scale":166.6666666,
"refract_shadows":false
},
"spheres": [{
"rad": 1,
"loc": [-1, 0, 0],
"ambient": 0.4,
"specular": 1.46,
"reflected": 0,
"transmitted": 0.0,
"diffuse": [0.9, 0.0, 0.0],
"n": 32
},
{
"rad": 0.3,
"loc": [-0.1, 0, 1.1],
"ambient": 0.1,
"specular": 1.46,
"reflected": 0,
"transmitted": 0.0,
"diffuse": [0.8, 0.8, 0.8],
"n": 32
},
{
"rad": 10,
"loc": [-4, 0, -11],
"ambient": 0.4,
"specular": 0,
"reflected": 1,
"transmitted": 0.0,
"diffuse": [0.4, 0.4, 0.4],
"n": 1
}
],
"lights": [{
"dir": [-0.6, 0, -1],
"color": [20, 20, 20]
}
],
"comment": "I was also testing ambient shading here. This looks better with the broken (multiply) ambient equation"
}