[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [33973] trunk/blender/source/blender: Silence more compiler warnings.
gsr b3d
gsr.b3d at infernal-iceberg.com
Fri Dec 31 21:01:38 CET 2010
Revision: 33973
http://projects.blender.org/plugins/scmsvn/viewcvs.php?view=rev&root=bf-blender&revision=33973
Author: gsrb3d
Date: 2010-12-31 21:01:38 +0100 (Fri, 31 Dec 2010)
Log Message:
-----------
Silence more compiler warnings.
Modified Paths:
--------------
trunk/blender/source/blender/blenkernel/intern/customdata.c
trunk/blender/source/blender/blenkernel/intern/font.c
trunk/blender/source/blender/blenlib/intern/math_color.c
trunk/blender/source/blender/editors/curve/editcurve.c
trunk/blender/source/blender/editors/space_logic/logic_window.c
Modified: trunk/blender/source/blender/blenkernel/intern/customdata.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/customdata.c 2010-12-31 15:09:05 UTC (rev 33972)
+++ trunk/blender/source/blender/blenkernel/intern/customdata.c 2010-12-31 20:01:38 UTC (rev 33973)
@@ -611,7 +611,7 @@
static void mdisp_apply_weight(int S, int corners, int x, int y, int face_side,
float crn_weight[4][2], float *u_r, float *v_r)
{
- float u, v, xl, yl;
+ float u = 0.f, v = 0.f, xl, yl;
float mid1[2], mid2[2], mid3[2];
mdisp_rot_crn_to_face(S, corners, face_side, x, y, &u, &v);
Modified: trunk/blender/source/blender/blenkernel/intern/font.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/font.c 2010-12-31 15:09:05 UTC (rev 33972)
+++ trunk/blender/source/blender/blenkernel/intern/font.c 2010-12-31 20:01:38 UTC (rev 33973)
@@ -670,7 +670,7 @@
VFont *vfont, *oldvfont;
VFontData *vfd= NULL;
Curve *cu;
- CharInfo *info, *custrinfo;
+ CharInfo *info = NULL, *custrinfo;
TextBox *tb;
VChar *che;
struct chartrans *chartransdata=NULL, *ct;
Modified: trunk/blender/source/blender/blenlib/intern/math_color.c
===================================================================
--- trunk/blender/source/blender/blenlib/intern/math_color.c 2010-12-31 15:09:05 UTC (rev 33972)
+++ trunk/blender/source/blender/blenlib/intern/math_color.c 2010-12-31 20:01:38 UTC (rev 33973)
@@ -112,7 +112,7 @@
void rgb_to_ycc(float r, float g, float b, float *ly, float *lcb, float *lcr, int colorspace)
{
float sr,sg, sb;
- float y, cr, cb;
+ float y = 128.f, cr = 128.f, cb = 128.f;
sr=255.0f*r;
sg=255.0f*g;
@@ -144,11 +144,12 @@
}
-/* YCC input have a range of 16-235 and 16-240 exepect with JFIF_0_255 where the range is 0-255 */
+/* YCC input have a range of 16-235 and 16-240 except with JFIF_0_255 where the range is 0-255 */
/* RGB outputs are in the range 0 - 1.0f */
+/* FIXME comment above must be wrong because BLI_YCC_ITU_BT601 y 16.0 cr 16.0 -> r -0.7009 */
void ycc_to_rgb(float y, float cb, float cr, float *lr, float *lg, float *lb, int colorspace)
{
- float r,g,b;
+ float r = 128.f, g = 128.f, b = 128.f;
switch (colorspace) {
case BLI_YCC_ITU_BT601 :
@@ -182,7 +183,7 @@
if (sscanf(hexcol, "%02x%02x%02x", &ri, &gi, &bi)==3) {
*r = ri / 255.0f;
- *g = gi / 255.0f;
+ *g = gi / 255.0f;
*b = bi / 255.0f;
CLAMP(*r, 0.0f, 1.0f);
CLAMP(*g, 0.0f, 1.0f);
Modified: trunk/blender/source/blender/editors/curve/editcurve.c
===================================================================
--- trunk/blender/source/blender/editors/curve/editcurve.c 2010-12-31 15:09:05 UTC (rev 33972)
+++ trunk/blender/source/blender/editors/curve/editcurve.c 2010-12-31 20:01:38 UTC (rev 33973)
@@ -3928,7 +3928,7 @@
Curve *cu= obedit->data;
ListBase *nubase= curve_get_editcurve(obedit);
Nurb *nu, *nu1=0, *nu2=0;
- BezTriple *bezt;
+ BezTriple *bezt = NULL;
BPoint *bp;
float *fp, offset;
int a, ok= 0;
Modified: trunk/blender/source/blender/editors/space_logic/logic_window.c
===================================================================
--- trunk/blender/source/blender/editors/space_logic/logic_window.c 2010-12-31 15:09:05 UTC (rev 33972)
+++ trunk/blender/source/blender/editors/space_logic/logic_window.c 2010-12-31 20:01:38 UTC (rev 33973)
@@ -3691,7 +3691,7 @@
bArmatureActuator *aa = (bArmatureActuator *) act->data;
Object *ob = (Object *)ptr->id.data;
PointerRNA pose_ptr, pchan_ptr;
- PropertyRNA *bones_prop;
+ PropertyRNA *bones_prop = NULL;
if(ob->type != OB_ARMATURE){
uiItemL(layout, "Actuator only available for armatures", ICON_NULL);
More information about the Bf-blender-cvs
mailing list