1 /* Dia -- an diagram creation/manipulation program
2 * Support for computing bounding boxes
3 * Copyright (C) 2001 Cyrille Chepelov
5 * This program is free software; you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation; either version 2 of the License, or
8 * (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
25 typedef struct _PolyBBExtras PolyBBExtras
;
27 struct _PolyBBExtras
{
28 real start_long
, start_trans
;
30 real end_long
, end_trans
;
33 typedef struct _LineBBExtras LineBBExtras
;
35 struct _LineBBExtras
{
36 real start_long
, start_trans
;
37 real end_long
, end_trans
;
40 typedef struct _ElementBBExtras ElementBBExtras
;
41 struct _ElementBBExtras
{
45 void bicubicbezier2D_bbox(const Point
*p0
,const Point
*p1
,
46 const Point
*p2
,const Point
*p3
,
47 const PolyBBExtras
*extra
,
50 void line_bbox(const Point
*p1
, const Point
*p2
,
51 const LineBBExtras
*extra
,
54 void rectangle_bbox(const Rectangle
*rin
,
55 const ElementBBExtras
*extra
,
58 void circle_bbox(const Point
*centre
, real radius
,
61 void ellipse_bbox(const Point
*centre
, real width
, real height
,
62 const ElementBBExtras
*extra
,
64 void polyline_bbox(const Point
*pts
, int numpoints
,
65 const PolyBBExtras
*extra
, gboolean closed
,
67 void polybezier_bbox(const BezPoint
*pts
, int numpoints
,
68 const PolyBBExtras
*extra
, gboolean closed
,
71 #endif /* BOUNDINGBOX_H */