1 // This is gel/vifa/vifa_bbox.h
2 #ifndef _VIFA_BBOX_H_
3 #define _VIFA_BBOX_H_
4 //-----------------------------------------------------------------------------
5 //:
6 // \file
7 // \brief Timestamped 2D bounding box
8 //
9 // The vifa_bbox class is a timestamped 2D bounding box (vgl/vgl_box_2d) used
10 // by the vifa_group_pgram class to efficiently compute the bounding box of a
11 // collection of lines.
12 //
13 // \author Mike Petersen, June 2003
14 //-----------------------------------------------------------------------------
15 
16 #include <vbl/vbl_ref_count.h>
17 #include <vbl/vbl_smart_ptr.h>
18 #include <vgl/vgl_box_2d.h>
19 #include <vul/vul_timestamp.h>
20 
21 
22 class vifa_bbox : public vul_timestamp,
23                   public vbl_ref_count,
24                   public vgl_box_2d<double>
25 {
26  public:
27   // Default constructor
28    inline vifa_bbox() = default;
29    // copy constructor - compiler-provided one sets ref_count to nonzero which
30    // is wrong -PVr
vifa_bbox(vifa_bbox const & b)31    inline vifa_bbox(vifa_bbox const &b)
32        : vul_timestamp(), vbl_ref_count(), vgl_box_2d<double>(b) {}
33 };
34 
35 typedef vbl_smart_ptr<vifa_bbox> vifa_bbox_sptr;
36 
37 #endif // _VIFA_BBOX_H_
38