headers/bsd: Add sys/queue.h.
[haiku.git] / src / tests / servers / app / painter / ShapeConverter.h
blobfcfa3f9d4f08d3c697d3ee5109a31a54dd1053bd
1 /*
2 * Copyright 2005, Stephan Aßmus <superstippi@gmx.de>. All rights reserved.
3 * Distributed under the terms of the MIT License.
5 * Simple BShape to agg::path_storage converter, implemented as BShapeIterator.
7 */
10 #ifndef SHAPE_CONVERTER_H
11 #define SHAPE_CONVERTER_H
13 #include <Shape.h>
15 #include <agg_path_storage.h>
17 #include "Transformable.h"
19 class BPoint;
21 // TODO: test if this actually works
23 class ShapeConverter : public BShapeIterator,
24 public Transformable {
25 public:
26 ShapeConverter();
27 ShapeConverter(agg::path_storage* path);
28 virtual ~ShapeConverter() {};
30 void SetPath(agg::path_storage* path);
32 virtual status_t IterateMoveTo(BPoint* point);
33 virtual status_t IterateLineTo(int32 lineCount, BPoint* linePts);
34 virtual status_t IterateBezierTo(int32 bezierCount, BPoint* bezierPts);
35 virtual status_t IterateClose();
37 private:
38 agg::path_storage* fPath;
41 #endif // SHAPE_CONVERTER_H