Skip to content

Commit

Permalink
Remove some unused functions
Browse files Browse the repository at this point in the history
All of these are unused since af9fbd1 "Introduce a new compositor
architecture". Since no one complained yet, I guess that means that we don't
need these any more. :-)

This was noticed while looking into the build log provided by
http://lists.cairographics.org/archives/cairo/2012-April/022993.html

Signed-off-by: Uli Schlachter <psychon@znc.in>
  • Loading branch information
Uli Schlachter committed May 5, 2012
1 parent 748dcde commit 494cfd7
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 80 deletions.
36 changes: 0 additions & 36 deletions src/cairo-botor-scan-converter.c
Original file line number Diff line number Diff line change
Expand Up @@ -2128,42 +2128,6 @@ botor_add_edge (cairo_botor_scan_converter_t *self,
return CAIRO_STATUS_SUCCESS;
}

static cairo_status_t
_cairo_botor_scan_converter_add_edge (void *converter,
const cairo_point_t *p1,
const cairo_point_t *p2,
int top, int bottom,
int dir)
{
cairo_botor_scan_converter_t *self = converter;
cairo_edge_t edge;

edge.line.p1 = *p1;
edge.line.p2 = *p2;
edge.top = top;
edge.bottom = bottom;
edge.dir = dir;

return botor_add_edge (self, &edge);
}

static cairo_status_t
_cairo_botor_scan_converter_add_polygon (void *converter,
const cairo_polygon_t *polygon)
{
cairo_botor_scan_converter_t *self = converter;
cairo_status_t status;
int i;

for (i = 0; i < polygon->num_edges; i++) {
status = botor_add_edge (self, &polygon->edges[i]);
if (unlikely (status))
return status;
}

return CAIRO_STATUS_SUCCESS;
}

static void
_cairo_botor_scan_converter_destroy (void *converter)
{
Expand Down
44 changes: 0 additions & 44 deletions src/cairo-path-stroke-polygon.c
Original file line number Diff line number Diff line change
Expand Up @@ -232,50 +232,6 @@ join_is_clockwise (const cairo_stroke_face_t *in,
return _cairo_slope_compare (&in->dev_vector, &out->dev_vector) < 0;
}

static cairo_int64_t
distance_from_face (const cairo_stroke_face_t *face,
const cairo_point_t *p,
cairo_bool_t negate)
{
int32_t dx = (p->x - face->point.x);
int32_t dy = (p->y - face->point.y);
cairo_int64_t d;

d = _cairo_int64_sub (_cairo_int32x32_64_mul (dx, face->dev_vector.dy),
_cairo_int32x32_64_mul (dy, face->dev_vector.dx));
if (negate)
d = _cairo_int64_negate (d);
return d;
}

static cairo_int64_t
distance_along_face (const cairo_stroke_face_t *face,
const cairo_point_t *p)
{
int32_t dx = (p->x - face->point.x);
int32_t dy = (p->y - face->point.y);
return _cairo_int64_add (_cairo_int32x32_64_mul (dx, face->dev_vector.dx),
_cairo_int32x32_64_mul (dy, face->dev_vector.dy));
}

static void
compute_inner_joint (cairo_point_t *p1, cairo_int64_t d_p1,
const cairo_point_t *p2, cairo_int64_t d_p2,
cairo_int64_t half_line_width)
{
int32_t dx = p2->x - p1->x;
int32_t dy = p2->y - p1->y;

half_line_width = _cairo_int64_sub (half_line_width, d_p1);
d_p2 = _cairo_int64_sub (d_p2, d_p1);

p1->x += _cairo_int_96by64_32x64_divrem (_cairo_int64x32_128_mul (half_line_width, dx),
d_p2).quo;

p1->y += _cairo_int_96by64_32x64_divrem (_cairo_int64x32_128_mul (half_line_width, dy),
d_p2).quo;
}

static void
inner_join (struct stroker *stroker,
const cairo_stroke_face_t *in,
Expand Down

0 comments on commit 494cfd7

Please sign in to comment.