1 | <?php |
||
26 | class RingMethods |
||
27 | { |
||
28 | |||
29 | /** |
||
30 | * The ring geometry defines a flat ring, like a CD. |
||
31 | * Note that because it is flat, |
||
32 | * only a single side of the ring will be rendered if side: double is not specified on the material component. |
||
33 | */ |
||
34 | const DEFAULTS = array( |
||
35 | /* Radius of the inner hole of the ring. */ |
||
36 | 'radiusInner' => 1, |
||
37 | /* Radius of the outer edge of the ring. */ |
||
38 | 'radiusOuter' => 1, |
||
39 | /* Number of segments. A higher number means the ring will be more round */ |
||
40 | 'segmentsTheta' => 32, |
||
41 | /* Number of triangles within each face defined by segmentsTheta. */ |
||
42 | 'segmentsPhi' => 8, |
||
43 | /* Starting angle in degrees. */ |
||
44 | 'thetaStart' => 0, |
||
45 | /* Central angle in degrees. */ |
||
46 | 'thetaLength' => 360 |
||
47 | ); |
||
48 | |||
49 | /** |
||
50 | * Radius of the inner hole of the ring. |
||
51 | * |
||
52 | * @param &array $dom_attributes |
||
|
|||
53 | * @param float|int $radiusInner |
||
54 | * @return void |
||
55 | */ |
||
56 | 1 | public function radiusInner(array &$dom_attributes, float $radiusInner) |
|
60 | |||
61 | /** |
||
62 | * Radius of the outer edge of the ring. |
||
63 | * |
||
64 | * @param &array $dom_attributes |
||
65 | * @param float|int $radiusOuter |
||
66 | * @return void |
||
67 | */ |
||
68 | 1 | public function radiusOuter(array &$dom_attributes, float $radiusOuter) |
|
72 | |||
73 | /** |
||
74 | * Central angle in degrees. |
||
75 | * |
||
76 | * @param &array $dom_attributes |
||
77 | * @param float|int $thetaLength |
||
78 | * @return void |
||
79 | */ |
||
80 | 1 | public function thetaLength(array &$dom_attributes, float $thetaLength) |
|
84 | |||
85 | /** |
||
86 | * Starting angle in degrees. |
||
87 | * |
||
88 | * @param &array $dom_attributess |
||
89 | * @param float|int $thetaStart |
||
90 | * @return void |
||
91 | */ |
||
92 | 1 | public function thetaStart(array &$dom_attributes, float $thetaStart) |
|
96 | |||
97 | /** |
||
98 | * Number of segments. |
||
99 | * A higher number means the ring will be more round. |
||
100 | * |
||
101 | * @param &array $dom_attributes |
||
102 | * @param int $segmentsTheta |
||
103 | * @return void |
||
104 | */ |
||
105 | 1 | public function segmentsTheta(array &$dom_attributes, int $segmentsTheta) |
|
109 | |||
110 | /** |
||
111 | * Number of triangles within each face defined by segmentsTheta. |
||
112 | * |
||
113 | * @param &array $dom_attributes |
||
114 | * @param int $segmentsPhi |
||
115 | * @return void |
||
116 | */ |
||
117 | 1 | public function segmentsPhi(array &$dom_attributes, int $segmentsPhi) |
|
121 | } |
||
122 |
This check marks PHPDoc comments that could not be parsed by our parser. To see which comment annotations we can parse, please refer to our documentation on supported doc-types.