summaryrefslogtreecommitdiffstatsci
path: root/src/cairo-tests/stroke.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/cairo-tests/stroke.cpp')
-rw-r--r--src/cairo-tests/stroke.cpp19
1 files changed, 0 insertions, 19 deletions
diff --git a/src/cairo-tests/stroke.cpp b/src/cairo-tests/stroke.cpp
index 91e9f98..4e62d2c 100644
--- a/src/cairo-tests/stroke.cpp
+++ b/src/cairo-tests/stroke.cpp
@@ -71,33 +71,14 @@ static void drawShape(caskbench_context_t *ctx,double x,double y)
case 3:
// Triangle
- ctx->shape_args.numpoints = 3;
- ctx->shape_args.points = (double (*)[2]) malloc(ctx->shape_args.numpoints*2*(sizeof(double)));
- ctx->shape_args.points[0][0] = x;
- ctx->shape_args.points[0][1] = y+2*r;
- ctx->shape_args.points[1][0] = 2*r;
- ctx->shape_args.points[1][1] = 0;
- ctx->shape_args.points[2][0] = -r;
- ctx->shape_args.points[2][1] = -2*r;
cairoShapes[CB_SHAPE_TRIANGLE] (ctx,&ctx->shape_args);
- free (ctx->shape_args.points);
//cairo_fill (cr);
break;
case 4:
// Star
- ctx->shape_args.numpoints = 10;
- ctx->shape_args.points = (double (*)[2]) malloc(ctx->shape_args.numpoints*2*(sizeof(double)));
-
- for (p = 0; p < 10; p++ ) {
- int px = x + 2*r * star_points[p][0]/200.0;
- int py = y + 2*r * star_points[p][1]/200.0;
- ctx->shape_args.points[p][0] = px;
- ctx->shape_args.points[p][1] = py;
- }
cairoShapes[CB_SHAPE_STAR] (ctx,&ctx->shape_args);
//cairo_fill (cr);
- free (ctx->shape_args.points);
break;
default: