1 /* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=8 sts=2 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef MOZILLA_GFX_AA_STROKE_H
8 #define MOZILLA_GFX_AA_STROKE_H
14 enum class LineCap
{ Round
, Square
, Butt
};
15 enum class LineJoin
{ Round
, Miter
, Bevel
};
34 Stroker
* aa_stroke_new(const StrokeStyle
* style
,
35 OutputVertex
* output_ptr
= nullptr,
36 size_t output_capacity
= 0);
37 void aa_stroke_move_to(Stroker
* s
, float x
, float y
, bool closed
);
38 void aa_stroke_line_to(Stroker
* s
, float x
, float y
, bool end
);
39 void aa_stroke_curve_to(Stroker
* s
, float c1x
, float c1y
, float c2x
, float c2y
,
40 float x
, float y
, bool end
);
41 void aa_stroke_close(Stroker
* s
);
42 VertexBuffer
aa_stroke_finish(Stroker
* s
);
43 void aa_stroke_vertex_buffer_release(VertexBuffer vb
);
44 void aa_stroke_release(Stroker
* s
);
47 } // namespace AAStroke
49 #endif // MOZILLA_GFX_AA_STROKE_H