2 * Copyright 2006-2008, Haiku.
3 * Distributed under the terms of the MIT License.
6 * Artur Wyszynski <harakash@gmail.com>
11 #include <GradientConic.h>
15 BGradientConic::BGradientConic()
17 fData
.conic
.cx
= 0.0f
;
18 fData
.conic
.cy
= 0.0f
;
19 fData
.conic
.angle
= 0.0f
;
25 BGradientConic::BGradientConic(const BPoint
& center
, float angle
)
27 fData
.conic
.cx
= center
.x
;
28 fData
.conic
.cy
= center
.y
;
29 fData
.conic
.angle
= angle
;
35 BGradientConic::BGradientConic(float cx
, float cy
, float angle
)
39 fData
.conic
.angle
= angle
;
46 BGradientConic::Center() const
48 return BPoint(fData
.conic
.cx
, fData
.conic
.cy
);
54 BGradientConic::SetCenter(const BPoint
& center
)
56 fData
.conic
.cx
= center
.x
;
57 fData
.conic
.cy
= center
.y
;
63 BGradientConic::SetCenter(float cx
, float cy
)
72 BGradientConic::Angle() const
74 return fData
.conic
.angle
;
80 BGradientConic::SetAngle(float angle
)
82 fData
.conic
.angle
= angle
;