2 * Cairo Performance Test Framework
3 * (c) 2012 Samsung Electronics, Inc.
6 * Measures rendering performance for image, gl backends
8 * This software is a confidential and proprietary information of Samsung
9 * Electronics, Inc. ("Confidential Information"). You shall not disclose such
10 * Confidential Information and shall use it only in accordance with the terms
11 * of the license agreement you entered into with Samsung Electronics.
13 * Author: Dongyeon Kim <dy5.kim@samsung.com>
18 void clearCairo(cairo_t *cr, double width, double height)
20 cairo_set_source_rgba(cr, 1, 1, 1, 1);
21 cairo_rectangle(cr, 0.0, 0.0, width, height);
25 void cairoSquare(cairo_t *cr, double x, double y, double length)
27 cairo_rectangle(cr, x, y, length, length);
31 void cairoSquareStroke(cairo_t *cr, double x, double y, double length)
33 cairo_rectangle(cr, x, y, length, length);
37 void cairoCircle(cairo_t *cr, double x, double y, double radius)
39 cairo_arc(cr, x, y, radius, 0.0, 2.0 * M_PI);
43 void cairoCircleStroke(cairo_t *cr, double x, double y, double radius)
45 cairo_arc(cr, x, y, radius, 0.0, 2.0 * M_PI);
49 void cairoTriangle(cairo_t *cr, double x, double y, double side)
51 cairo_move_to(cr, x, y);
52 cairo_line_to(cr, x + side, y + side);
53 cairo_line_to(cr, x, y + side);
58 void cairoTriangleStroke(cairo_t *cr, double x, double y, double side)
60 cairo_move_to(cr, x, y);
61 cairo_line_to(cr, x + side, y);
62 cairo_line_to(cr, x, y + side);