@@ -4,7 +4,8 @@ use std::io::BufReader;
44use std:: fs:: File ;
55use std:: path:: Path ;
66
7- use cgmath:: Transform as Transform_ ;
7+ use cgmath:: { Point3 , Transform as Transform_ } ;
8+ use collision:: Aabb3 ;
89use genmesh:: { Polygon , EmitTriangles , Triangulate , Vertex as GenVertex } ;
910use genmesh:: generators:: { self , IndexedPolygon , SharedVertex } ;
1011use gfx;
@@ -15,7 +16,6 @@ use image;
1516use mint;
1617use obj;
1718
18- use bound:: BoundingBox ;
1919use camera:: { Orthographic , Perspective } ;
2020use render:: { BackendFactory , BackendResources , GpuData , Vertex , ShadowFormat } ;
2121use scene:: { Color , Background , Group , Mesh , Sprite , Material ,
@@ -49,6 +49,11 @@ const QUAD: [Vertex; 4] = [
4949 } ,
5050] ;
5151
52+ const EMPTY_AABB3 : Aabb3 < f32 > = Aabb3 {
53+ min : Point3 { x : 0.0 , y : 0.0 , z : 0.0 } ,
54+ max : Point3 { x : 0.0 , y : 0.0 , z : 0.0 } ,
55+ } ;
56+
5257
5358impl From < SubNode > for Node {
5459 fn from ( sub : SubNode ) -> Self {
@@ -57,8 +62,8 @@ impl From<SubNode> for Node {
5762 world_visible : false ,
5863 transform : Transform_ :: one ( ) ,
5964 world_transform : Transform_ :: one ( ) ,
60- bounds : BoundingBox :: empty ( ) ,
61- world_bounds : BoundingBox :: empty ( ) ,
65+ bounds : EMPTY_AABB3 ,
66+ world_bounds : EMPTY_AABB3 ,
6267 parent : None ,
6368 scene_id : None ,
6469 sub_node : sub,
0 commit comments