@@ -20,6 +20,15 @@ def __init__(self, origin, basis, dims):
2020 self .basis = basis
2121 self .dims = dims
2222
23+ self .faces = [
24+ [0 , 1 , 3 , 2 ],
25+ [4 , 5 , 7 , 6 ],
26+ [0 , 1 , 5 , 4 ],
27+ [2 , 3 , 7 , 6 ],
28+ [0 , 2 , 6 , 4 ],
29+ [1 , 3 , 7 , 5 ],
30+ ]
31+
2332 combinations = np .array (np .meshgrid ([0 , 1 ], [0 , 1 ], [0 , 1 ])).T .reshape (- 1 , 3 )
2433 scaled_combinations = combinations * dims
2534
@@ -37,14 +46,6 @@ def __init__(self, origin, basis, dims):
3746 move_vectors = unit_move_dirs * 0.0015
3847 self .path_vertices = self .vertices + move_vectors
3948
40- self .faces = [
41- [0 , 1 , 3 , 2 ], # Bottom face
42- [4 , 5 , 7 , 6 ], # Top face
43- [0 , 1 , 5 , 4 ], # Front face
44- [2 , 3 , 7 , 6 ], # Back face
45- [0 , 2 , 6 , 4 ], # Left face
46- [1 , 3 , 7 , 5 ], # Right face
47- ]
4849 self .quads = self .compute_quads ()
4950
5051 def __repr__ (self ):
@@ -87,31 +88,31 @@ def paths(self, cam):
8788scene = Scene (
8889 [
8990 Rhombohedron (
90- origin = np .array ([0.0 , 0.0 , 0.0 ]),
91+ origin = np .array ([0.0 , 0.0 , 0.2 ]),
9192 basis = np .array (
9293 [
93- [0.9 , 0.5 , 0.0 ],
94+ [0.45 , 0.2 , - 0.3 ],
9495 [- 0.3 , 1.0 , 0.0 ],
95- [- 0.5 , 0.25 , - 0.7 ],
96+ [- 0.5 , 0.0 , - 0.2 ],
9697 ]
9798 ),
98- dims = np .array ([1 .0 , 1.0 , 1.0 ]),
99+ dims = np .array ([2 .0 , 0.5 , 1.0 ]),
99100 ),
100101 Rhombohedron (
101- origin = np .array ([2 .0 , 0.0 , - 2.0 ]),
102+ origin = np .array ([1 .0 , 0.0 , - 2.0 ]),
102103 basis = np .array (
103104 [
104105 [- 0.9 , 0.5 , 0.0 ],
105106 [0.3 , 1.0 , 0.5 ],
106107 [1.5 , 0.25 , - 0.7 ],
107108 ]
108109 ),
109- dims = np .array ([1.0 , 1.0 , 1.0 ]),
110+ dims = np .array ([1.0 , 1.0 , 0.8 ]),
110111 ),
111112 ]
112113)
113114
114- eye = np .array ([0 , 0.4 , 5 ])
115+ eye = np .array ([0 , - 0.5 , 5 ])
115116focus = np .array ([0 , 0.4 , 0 ])
116117up = np .array ([0 , 1 , 0 ])
117118
0 commit comments