-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
grad map implementing: only constant matte
- Loading branch information
Showing
29 changed files
with
479 additions
and
43 deletions.
There are no files selected for viewing
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,142 @@ | ||
// mat_cbox | ||
Surface cbox-white : Matte { | ||
Kd : Constant { | ||
//v { 0.725, 0.71, 0.68 } | ||
v { 0.5, 0.5, 0.5 } | ||
requires_grad { true } | ||
render_grad_map { true } | ||
range { 0.00001, 0.99999 } | ||
} | ||
} | ||
|
||
|
||
Surface cbox-green : Matte { | ||
Kd : Constant { | ||
//v { 0.14, 0.45, 0.091 } | ||
v { 0.5, 0.5, 0.5 } | ||
requires_grad { true } | ||
range { 0.00001, 0.99999 } | ||
} | ||
} | ||
|
||
Surface cbox-red : Matte { | ||
Kd : Constant { | ||
//v { 0.63, 0.065, 0.05 } | ||
v { 0.5, 0.5, 0.5 } | ||
requires_grad { true } | ||
range { 0.00001, 0.99999 } | ||
} | ||
} | ||
|
||
// shape_cbox | ||
Shape cbox-ceiling : Mesh { | ||
file { "../../meshes/cbox-parts/ceiling.obj" } | ||
surface { @cbox-white } | ||
} | ||
|
||
Shape cbox-floor : Mesh { | ||
file { "../../meshes/cbox-parts/floor.obj" } | ||
surface { @cbox-white } | ||
} | ||
|
||
Shape cbox-left-wall : Mesh { | ||
file { "../../meshes/cbox-parts/left-wall.obj" } | ||
surface { @cbox-red } | ||
} | ||
|
||
Shape cbox-right-wall : Mesh { | ||
file { "../../meshes/cbox-parts/right-wall.obj" } | ||
surface { @cbox-green } | ||
} | ||
|
||
Shape cbox-back-wall : Mesh { | ||
file { "../../meshes/cbox-parts/back-wall.obj" } | ||
surface { @cbox-white } | ||
} | ||
|
||
|
||
Shape cbox-light : Mesh { | ||
file { "../../meshes/cbox-parts/light.obj" } | ||
light : Diffuse { | ||
emission : Constant { | ||
//v { 10, 10, 10 } | ||
v { 45.0, 45.0, 45.0 } | ||
} | ||
} | ||
} | ||
|
||
Shape cbox-tall-box : Mesh { | ||
file { "../../meshes/cbox-parts/tall-box.obj" } | ||
surface { @cbox-white } | ||
} | ||
|
||
Shape cbox-short-box : Mesh { | ||
file { "../../meshes/cbox-parts/short-box.obj" } | ||
surface { @cbox-white } | ||
} | ||
|
||
|
||
Shape cbox : Group { | ||
shapes { | ||
@cbox-left-wall, | ||
@cbox-ceiling, | ||
@cbox-floor, | ||
@cbox-right-wall, | ||
@cbox-back-wall, | ||
@cbox-tall-box, | ||
@cbox-short-box, | ||
@cbox-light | ||
} | ||
} | ||
|
||
Film film : Color { | ||
resolution { 1024 } | ||
exposure { 0 } | ||
} | ||
|
||
FIlm display : Display { | ||
base { @film } | ||
} | ||
|
||
Camera camera : Pinhole { | ||
position { 0.0, 1.0, 5.0 } | ||
fov { 27.8 } | ||
spp { 1024 } | ||
film { @display } | ||
file { "../../renders/cbox-diff.exr" } | ||
filter : Gaussian { | ||
radius { 1 } | ||
} | ||
target : Image { | ||
file { "../../renders/cbox-ref.exr" } | ||
} | ||
} | ||
|
||
//Integrator pt : MegaRadiativeDiff { | ||
Integrator pt : MegaReplayDiff { | ||
sampler : Independent {} | ||
depth { 10 } | ||
rr_depth { 5 } | ||
|
||
display_camera_index { 0 } | ||
save_process { true } | ||
save_grad_map { true } | ||
save_finite_diff { true } | ||
loss : L2 {} | ||
iterations { 10 } | ||
|
||
optimizer : Adam { | ||
learning_rate { 0.03 } | ||
} | ||
} | ||
|
||
render { | ||
spectrum : sRGB {} | ||
cameras { | ||
@camera | ||
} | ||
shapes { | ||
@cbox | ||
} | ||
integrator { @pt } | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.