use G_SQRT2 to make circlemagic a constant value so we can initialize the

2004-06-19  Sven Neumann  <sven@gimp.org>

	* app/vectors/gimpbezierstroke.c (arcto_ellipsesegment): use
	G_SQRT2 to make circlemagic a constant value so we can initialize
	the array on declaration. Fixes bug #144632.
This commit is contained in:
Sven Neumann 2004-06-19 09:20:36 +00:00 committed by Sven Neumann
parent 496f42fd5c
commit ef5d371d83
2 changed files with 12 additions and 6 deletions

View File

@ -1,3 +1,9 @@
2004-06-19 Sven Neumann <sven@gimp.org>
* app/vectors/gimpbezierstroke.c (arcto_ellipsesegment): use
G_SQRT2 to make circlemagic a constant value so we can initialize
the array on declaration. Fixes bug #144632.
2004-06-19 Sven Neumann <sven@gimp.org>
* devel-docs/parasites.txt: document "exif-data" parasite.

View File

@ -1514,12 +1514,12 @@ arcto_ellipsesegment (gdouble radius_x,
gdouble phi1,
GimpCoords *ellips)
{
gdouble phi_s, phi_e;
GimpCoords template = { 0, 0, 1, 0.5, 0.5, 0.5 };
gdouble circlemagic = 4 * (sqrt(2) - 1) / 3;
gdouble y[4] = { 0.0, circlemagic, 1.0, 1.0 };
gdouble h0, h1;
gdouble t0, t1;
gdouble phi_s, phi_e;
GimpCoords template = { 0, 0, 1, 0.5, 0.5, 0.5 };
const gdouble circlemagic = 4.0 * (G_SQRT2 - 1.0) / 3.0;
gdouble y[4] = { 0.0, circlemagic, 1.0, 1.0 };
gdouble h0, h1;
gdouble t0, t1;
g_return_if_fail (ellips != NULL);