-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathBlur_Object_Pigment_For_mesh2.pov
114 lines (93 loc) · 2.64 KB
/
Blur_Object_Pigment_For_mesh2.pov
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
// ===== 1 ======= 2 ======= 3 ======= 4 ======= 5 ======= 6 ======= 7 ======= 8 ======= 9 ======= 10
/*
https://github.com/t-o-k/POV-Ray-gaussian-blur
Copyright (c) 2017 Tor Olav Kristensen, http://subcube.com
Use of this source code is governed by the GNU Lesser General Public License version 3,
which can be found in the LICENSE file.
*/
// ===== 1 ======= 2 ======= 3 ======= 4 ======= 5 ======= 6 ======= 7 ======= 8 ======= 9 ======= 10
#version 3.7;
#include "colors.inc"
#include "../Gaussian_Blur.inc"
global_settings {
assumed_gamma 1.0
}
// ===== 1 ======= 2 ======= 3 ======= 4 ======= 5 ======= 6 ======= 7 ======= 8 ======= 9 ======= 10
#declare X = 100;
#declare Y = 100;
#declare Z = 100;
#declare pCtr = <X, Y, Z>/2;
#declare Cube =
mesh2 {
vertex_vectors {
8,
<0, 0, 0> - pCtr,
<X, 0, 0> - pCtr,
<X, 0, Z> - pCtr,
<0, 0, Z> - pCtr,
<0, Y, 0> - pCtr,
<X, Y, 0> - pCtr,
<X, Y, Z> - pCtr,
<0, Y, Z> - pCtr
}
face_indices {
12,
<0, 1, 2>,
<0, 2, 3>,
<0, 4, 5>,
<0, 5, 1>,
<1, 5, 6>,
<1, 6, 2>,
<2, 6, 7>,
<2, 7, 3>,
<3, 7, 4>,
<3, 4, 0>,
<4, 7, 6>,
<4, 6, 5>
}
inside_vector y
}
#declare CubeWithHoles =
difference {
object { Cube }
object { Cube scale 0.6*<2, 1, 1> }
object { Cube scale 0.6*<1, 2, 1> }
object { Cube scale 0.6*<1, 1, 2> }
rotate +45*y
rotate degrees(atan2(sqrt(3), sqrt(2)))*x
rotate -45*y
}
// ===== 1 ======= 2 ======= 3 ======= 4 ======= 5 ======= 6 ======= 7 ======= 8 ======= 9 ======= 10
#declare StepSize = 1.4;
#declare NoOfSteps = 16;
#declare BlurredObjectPigment =
BlurObjectPigmentDirXYZ(
CubeWithHoles,
StepSize,
NoOfSteps
)
object {
CubeWithHoles
pigment {
pigment_pattern { BlurredObjectPigment }
pigment_map {
[ 0.10 color rgb <1.0, 1.0, 1.0> ]
[ 0.40 color rgb <1.0, 0.0, 0.5> ]
[ 0.46 color rgb <0.0, 0.0, 0.0> ]
[ 0.50 color rgb <0.0, 1.0, 0.5> ]
}
}
rotate 8*y
}
// ===== 1 ======= 2 ======= 3 ======= 4 ======= 5 ======= 6 ======= 7 ======= 8 ======= 9 ======= 10
light_source {
100*<1, 3, -10>
color White
}
camera {
location 100*<2, 0, -3>
look_at <0, 0, 0>
angle 45
}
background { color rgb <1, 2, 3>/60 }
// ===== 1 ======= 2 ======= 3 ======= 4 ======= 5 ======= 6 ======= 7 ======= 8 ======= 9 ======= 10