Mercurial > hg > xmms-sid
comparison src/xs_curve.c @ 936:79f20427c99d
Remove unused variable.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Mon, 19 Nov 2012 17:41:02 +0200 |
parents | 8b4c016802ea |
children | ede5374e9294 |
comparison
equal
deleted
inserted
replaced
935:6f53d0405d58 | 936:79f20427c99d |
---|---|
256 | 256 |
257 /* Draw each curve segment */ | 257 /* Draw each curve segment */ |
258 if (curve->nctlpoints > 5) | 258 if (curve->nctlpoints > 5) |
259 for (i = 0; i < curve->nctlpoints; i++, ++p0, ++p1, ++p2, ++p3) | 259 for (i = 0; i < curve->nctlpoints; i++, ++p0, ++p1, ++p2, ++p3) |
260 { | 260 { |
261 gint n; | |
262 gfloat k1, k2, a, b, c, d, x; | 261 gfloat k1, k2, a, b, c, d, x; |
263 | 262 |
264 if (p1->x == p2->x) | 263 if (p1->x == p2->x) |
265 continue; | 264 continue; |
266 | 265 |
284 k2 = (p3->y - p1->y) / (p3->x - p1->x); | 283 k2 = (p3->y - p1->y) / (p3->x - p1->x); |
285 } | 284 } |
286 | 285 |
287 xs_cubic_coeff(p1->x, p1->y, p2->x, p2->y, k1, k2, &a, &b, &c, &d); | 286 xs_cubic_coeff(p1->x, p1->y, p2->x, p2->y, k1, k2, &a, &b, &c, &d); |
288 | 287 |
289 for (x = p1->x; x <= p2->x; x += res, n++) | 288 for (x = p1->x; x <= p2->x; x += res) |
290 { | 289 { |
291 gfloat y = ((a * x + b) * x + c) * x + d; | 290 gfloat y = ((a * x + b) * x + c) * x + d; |
292 gint qx, qy; | 291 gint qx, qy; |
293 qx = CP_RADIUS + xs_project(x, curve->min_x, curve->max_x, width); | 292 qx = CP_RADIUS + xs_project(x, curve->min_x, curve->max_x, width); |
294 qy = CP_RADIUS + xs_project(y, curve->min_y, curve->max_y, height); | 293 qy = CP_RADIUS + xs_project(y, curve->min_y, curve->max_y, height); |