From: Thomas Geymayer Date: Tue, 3 Jul 2012 13:48:11 +0000 (+0200) Subject: Add missing glx.h include and fix some warnings. X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=5eac7974c90910f6bfac445847817865b122051d;p=simgear.git Add missing glx.h include and fix some warnings. --- diff --git a/simgear/canvas/ShivaVG/src/shDefs.h b/simgear/canvas/ShivaVG/src/shDefs.h index d6e57a78..d0f3bb84 100644 --- a/simgear/canvas/ShivaVG/src/shDefs.h +++ b/simgear/canvas/ShivaVG/src/shDefs.h @@ -159,6 +159,7 @@ SHfloat getMaxFloat(); #if defined(VG_API_LINUX) #include #include + #include #elif defined(VG_API_MACOSX) #include #include diff --git a/simgear/canvas/ShivaVG/src/shGeometry.c b/simgear/canvas/ShivaVG/src/shGeometry.c index 71ab463b..3a711b37 100644 --- a/simgear/canvas/ShivaVG/src/shGeometry.c +++ b/simgear/canvas/ShivaVG/src/shGeometry.c @@ -347,7 +347,7 @@ static void shSubdivideSegment(SHPath *p, VGPathSegment segment, void shFlattenPath(SHPath *p, SHint surfaceSpace) { SHint contourStart = -1; - SHint surfSpace = surfaceSpace; +// SHint surfSpace = surfaceSpace; SHint *userData[2]; SHint processFlags = SH_PROCESS_SIMPLIFY_LINES | diff --git a/simgear/canvas/ShivaVG/src/shPaint.c b/simgear/canvas/ShivaVG/src/shPaint.c index 2e1ba4ad..406a889b 100644 --- a/simgear/canvas/ShivaVG/src/shPaint.c +++ b/simgear/canvas/ShivaVG/src/shPaint.c @@ -405,7 +405,7 @@ int shDrawLinearGradientMesh(SHPaint *p, SHVector2 *min, SHVector2 *max, SHVector2 c, ux, uy; SHVector2 cc, uux, uuy; - SHMatrix3x3 *m; + SHMatrix3x3 *m = 0; SHMatrix3x3 mi; SHint invertible; SHVector2 corners[4]; @@ -521,7 +521,7 @@ int shDrawRadialGradientMesh(SHPaint *p, SHVector2 *min, SHVector2 *max, SHVector2 c, f; SHVector2 cf; - SHMatrix3x3 *m; + SHMatrix3x3 *m = 0; SHMatrix3x3 mi; SHint invertible; SHVector2 corners[4]; @@ -722,7 +722,7 @@ int shDrawRadialGradientMesh(SHPaint *p, SHVector2 *min, SHVector2 *max, int shDrawPatternMesh(SHPaint *p, SHVector2 *min, SHVector2 *max, VGPaintMode mode, GLenum texUnit) { - SHMatrix3x3 *m; + SHMatrix3x3 *m = 0; SHMatrix3x3 mi; SHfloat migl[16]; SHint invertible; diff --git a/simgear/canvas/ShivaVG/src/shParams.c b/simgear/canvas/ShivaVG/src/shParams.c index 3ed90fe8..2535c149 100644 --- a/simgear/canvas/ShivaVG/src/shParams.c +++ b/simgear/canvas/ShivaVG/src/shParams.c @@ -839,9 +839,9 @@ static void shSetParameter(VGContext *context, VGHandle object, SHResourceType rtype, VGint ptype, SHint count, const void *values, SHint floats) { - SHfloat fvalue = 0.0f; +// SHfloat fvalue = 0.0f; SHint ivalue = 0; - VGboolean bvalue = VG_FALSE; +// VGboolean bvalue = VG_FALSE; int i; /* Check for negative count */ @@ -852,9 +852,9 @@ static void shSetParameter(VGContext *context, VGHandle object, /* Pre-convert first value for non-vector params */ if (count == 1) { - fvalue = shParamToFloat(values, floats, 0); +// fvalue = shParamToFloat(values, floats, 0); ivalue = shParamToInt(values, floats, 0); - bvalue = (ivalue ? VG_TRUE : VG_FALSE); +// bvalue = (ivalue ? VG_TRUE : VG_FALSE); } switch (rtype) diff --git a/simgear/canvas/ShivaVG/src/shPipeline.c b/simgear/canvas/ShivaVG/src/shPipeline.c index a03ced05..1e07bc56 100644 --- a/simgear/canvas/ShivaVG/src/shPipeline.c +++ b/simgear/canvas/ShivaVG/src/shPipeline.c @@ -148,7 +148,7 @@ static void shDrawBoundBox(VGContext *c, SHPath *p, VGPaintMode mode) static void shDrawPaintMesh(VGContext *c, SHVector2 *min, SHVector2 *max, VGPaintMode mode, GLenum texUnit) { - SHPaint *p; + SHPaint *p = 0; SHVector2 pmin, pmax; SHfloat K = 1.0f; @@ -199,7 +199,7 @@ VGboolean shIsTessCacheValid (VGContext *c, SHPath *p) { SHfloat nX, nY; SHVector2 X, Y; - SHMatrix3x3 mi, mchange; + SHMatrix3x3 mi;//, mchange; VGboolean valid = VG_TRUE; if (p->cacheDataValid == VG_FALSE) { @@ -214,7 +214,7 @@ VGboolean shIsTessCacheValid (VGContext *c, SHPath *p) else { /* TODO: Compare change matrix for any scale or shear */ - MULMATMAT( c->pathTransform, mi, mchange ); +// MULMATMAT( c->pathTransform, mi, mchange ); SET2( X, mi.m[0][0], mi.m[1][0] ); SET2( Y, mi.m[0][1], mi.m[1][1] ); nX = NORM2( X ); nY = NORM2( Y );