Пример #1
0
        public static Boundbox Read(BinaryReader br)
        {
            Boundbox box = new Boundbox();

            box.min = new Vector3D(br.ReadSingle(), br.ReadSingle(), br.ReadSingle());
            box.max = new Vector3D(br.ReadSingle(), br.ReadSingle(), br.ReadSingle());
            return(box);
        }
Пример #2
0
        public static Model Read(BinaryReader br)
        {
            Model model = new Model();

            model.bound    = Boundbox.Read(br);
            model.origin   = new Vector3D(br.ReadSingle(), br.ReadSingle(), br.ReadSingle());
            model.node_id0 = br.ReadInt32();
            model.node_id1 = br.ReadInt32();
            model.node_id2 = br.ReadInt32();
            model.node_id3 = br.ReadInt32();
            model.numleafs = br.ReadInt32();
            model.face_id  = br.ReadInt32();
            model.face_num = br.ReadInt32();
            return(model);
        }