Commit: d63b221f48649a55c085d564c0bf03917308d677
Author: Jason Wilkins
Date:   Sat Feb 15 15:46:40 2014 -0600
https://developer.blender.org/rBd63b221f48649a55c085d564c0bf03917308d677

Fixing more warnings given by llvm gcc on OSX.

===================================================================

M       source/blender/blenfont/intern/blf.c
M       source/blender/blenkernel/BKE_brush.h
M       source/blender/blenkernel/intern/displist.c
M       source/blender/blenkernel/intern/mball.c
M       source/blender/blenkernel/intern/mesh.c
M       source/blender/editors/include/ED_screen.h
M       source/blender/editors/include/ED_util.h
M       source/blender/editors/include/UI_interface.h
M       source/blender/editors/mesh/editmesh_select.c
M       source/blender/editors/sculpt_paint/paint_intern.h
M       source/blender/editors/space_view3d/drawanimviz.c
M       source/blender/editors/space_view3d/view3d_draw.c
M       source/blender/editors/space_view3d/view3d_intern.h
M       source/blender/gpu/intern/gpu_matrix.c
M       source/blender/python/generic/bgl.c
M       source/blender/python/intern/bpy_rna.c
M       source/blender/python/mathutils/mathutils_geometry.c
M       source/blender/render/intern/source/convertblender.c

===================================================================

diff --git a/source/blender/blenfont/intern/blf.c 
b/source/blender/blenfont/intern/blf.c
index 1dd6507..08c0f86 100644
--- a/source/blender/blenfont/intern/blf.c
+++ b/source/blender/blenfont/intern/blf.c
@@ -559,7 +559,7 @@ static void blf_draw__start(FontBLF *font)
 #if GPU_SAFETY && defined(WITH_GL_PROFILE_COMPAT)
        {
        GLenum param;
-       glGetTexEnviv(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, &param);
+       glGetTexEnviv(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, (GLint*)(&param));
        GPU_ASSERT(param == GL_MODULATE);
 
        GPU_ASSERT(gpuGetMatrixMode() == GL_MODELVIEW);
diff --git a/source/blender/blenkernel/BKE_brush.h 
b/source/blender/blenkernel/BKE_brush.h
index 64bd3bf..b84eb4f 100644
--- a/source/blender/blenkernel/BKE_brush.h
+++ b/source/blender/blenkernel/BKE_brush.h
@@ -41,6 +41,7 @@ struct Main;
 struct rctf;
 struct Scene;
 struct wmOperator;
+struct UnifiedPaintSettings;
 // enum CurveMappingPreset;
 
 
diff --git a/source/blender/blenkernel/intern/displist.c 
b/source/blender/blenkernel/intern/displist.c
index f3de400..b1d231b 100644
--- a/source/blender/blenkernel/intern/displist.c
+++ b/source/blender/blenkernel/intern/displist.c
@@ -456,7 +456,8 @@ void BKE_displist_fill(ListBase *dispbase, ListBase *to, 
const float normal_proj
        ScanFillFace *sf_tri;
        DispList *dlnew = NULL, *dl;
        float *f1;
-       int colnr = 0, charidx = 0, cont = 1, tot, a, *index, nextcol = 0;
+       int colnr = 0, charidx = 0, cont = 1, tot, a, nextcol = 0;
+       unsigned int *index;
        intptr_t totvert;
 
        if (dispbase == NULL)
@@ -548,7 +549,7 @@ void BKE_displist_fill(ListBase *dispbase, ListBase *to, 
const float normal_proj
                                        index[2] = (intptr_t)sf_tri->v3->tmp.l;
 
                                        if (flipnormal)
-                                               SWAP(int, index[0], index[2]);
+                                               SWAP(unsigned int, index[0], 
index[2]);
 
                                        index += 3;
                                        sf_tri = sf_tri->next;
@@ -1046,7 +1047,7 @@ static void curve_calc_modifiers_post(Scene *scene, 
Object *ob, ListBase *dispba
 static void displist_surf_indices(DispList *dl)
 {
        int a, b, p1, p2, p3, p4;
-       int *index;
+       unsigned int *index;
 
        dl->totindex = 0;
 
diff --git a/source/blender/blenkernel/intern/mball.c 
b/source/blender/blenkernel/intern/mball.c
index 43819e1..69dcf81 100644
--- a/source/blender/blenkernel/intern/mball.c
+++ b/source/blender/blenkernel/intern/mball.c
@@ -801,13 +801,13 @@ static float metaball(float x, float y, float z)
 
 /* ******************************************** */
 
-static int *indices = NULL;
+static unsigned int *indices = NULL;
 static int totindex, curindex;
 
 
 static void accum_mballfaces(int i1, int i2, int i3, int i4)
 {
-       int *newi, *cur;
+       unsigned int *newi, *cur;
        /* static int i = 0; I would like to delete altogether, but I don't 
dare to, yet */
 
        if (totindex == curindex) {
diff --git a/source/blender/blenkernel/intern/mesh.c 
b/source/blender/blenkernel/intern/mesh.c
index 2eb318c..9e40d90 100644
--- a/source/blender/blenkernel/intern/mesh.c
+++ b/source/blender/blenkernel/intern/mesh.c
@@ -1147,7 +1147,8 @@ void BKE_mesh_from_metaball(ListBase *lb, Mesh *me)
        MLoop *mloop, *allloop;
        MPoly *mpoly;
        float *nors, *verts;
-       int a, *index;
+       int a;
+       unsigned int *index;
        
        dl = lb->first;
        if (dl == NULL) return;
@@ -1311,7 +1312,8 @@ int BKE_mesh_nurbs_displist_to_mdata(Object *ob, ListBase 
*dispbase,
        MEdge *medge;
        float *data;
        int a, b, ofs, vertcount, startvert, totvert = 0, totedge = 0, totloop 
= 0, totvlak = 0;
-       int p1, p2, p3, p4, *index;
+       int p1, p2, p3, p4;
+       unsigned int *index;
        const bool conv_polys = ((cu->flag & CU_3D) ||    /* 2d polys are 
filled with DL_INDEX3 displists */
                                 (ob->type == OB_SURF));  /* surf polys are 
never filled */
 
diff --git a/source/blender/editors/include/ED_screen.h 
b/source/blender/editors/include/ED_screen.h
index 12030f7..7031dac 100644
--- a/source/blender/editors/include/ED_screen.h
+++ b/source/blender/editors/include/ED_screen.h
@@ -48,6 +48,7 @@ struct bScreen;
 struct ARegion;
 struct uiBlock;
 struct rcti;
+struct Main;
 
 /* regions */
 void    ED_region_do_listen(struct ARegion *ar, struct wmNotifier *note);
diff --git a/source/blender/editors/include/ED_util.h 
b/source/blender/editors/include/ED_util.h
index 67f790f..cded445 100644
--- a/source/blender/editors/include/ED_util.h
+++ b/source/blender/editors/include/ED_util.h
@@ -40,6 +40,7 @@ struct wmOperator;
 struct wmOperatorType;
 struct BMEditMesh;
 struct Mesh;
+struct PackedFile;
 
 /* ed_util.c */
 
diff --git a/source/blender/editors/include/UI_interface.h 
b/source/blender/editors/include/UI_interface.h
index 794f5e1..4b75a6b 100644
--- a/source/blender/editors/include/UI_interface.h
+++ b/source/blender/editors/include/UI_interface.h
@@ -75,6 +75,7 @@ struct ImBuf;
 struct bNodeTree;
 struct bNode;
 struct bNodeSocket;
+struct bScreen;
 
 typedef struct uiBut uiBut;
 typedef struct uiBlock uiBlock;
diff --git a/source/blender/editors/mesh/editmesh_select.c 
b/source/blender/editors/mesh/editmesh_select.c
index b6a646a..91170af 100644
--- a/source/blender/editors/mesh/editmesh_select.c
+++ b/source/blender/editors/mesh/editmesh_select.c
@@ -178,7 +178,7 @@ static void draw_triangulated(const int mcords[][2], const 
short tot)
        /* do the draw */
        dl = lb.first;  /* filldisplist adds in head of list */
        if (dl->type == DL_INDEX3) {
-               int *index;
+               unsigned int *index;
                
                a = dl->parts;
                fp = dl->verts;
diff --git a/source/blender/editors/sculpt_paint/paint_intern.h 
b/source/blender/editors/sculpt_paint/paint_intern.h
index b68e23f..e3b7d0c 100644
--- a/source/blender/editors/sculpt_paint/paint_intern.h
+++ b/source/blender/editors/sculpt_paint/paint_intern.h
@@ -56,6 +56,10 @@ struct wmOperator;
 struct wmOperatorType;
 struct ImagePaintState;
 struct wmWindowManager;
+struct wmKeyConfig;
+struct Image;
+struct ImBuf;
+struct SpaceImage;
 enum PaintMode;
 
 /* paint_stroke.c */
diff --git a/source/blender/editors/space_view3d/drawanimviz.c 
b/source/blender/editors/space_view3d/drawanimviz.c
index b5ea369..ba71ae0 100644
--- a/source/blender/editors/space_view3d/drawanimviz.c
+++ b/source/blender/editors/space_view3d/drawanimviz.c
@@ -83,7 +83,7 @@ void draw_motion_paths_init(View3D *v3d, ARegion *ar)
        if (v3d->zbuf) glDisable(GL_DEPTH_TEST);
        
        gpuPushMatrix();
-       gpuLoadMatrix(rv3d->viewmat[4]);
+       gpuLoadMatrix(rv3d->viewmat[0]);
 }
 
 /* Draw the given motion path for an Object or a Bone 
diff --git a/source/blender/editors/space_view3d/view3d_draw.c 
b/source/blender/editors/space_view3d/view3d_draw.c
index 6b2f1de..c2b7126 100644
--- a/source/blender/editors/space_view3d/view3d_draw.c
+++ b/source/blender/editors/space_view3d/view3d_draw.c
@@ -654,7 +654,7 @@ static void sort3(int sort[3], float a, float b, float c)
 
 /* Draw a live substitute of the view icon, which is always shown
  * colors copied from transform_manipulator.c, we should keep these matching. 
*/
-static void draw_view_axis(RegionView3D *rv3d, rcti *rect)
+static void draw_view_axis(RegionView3D *rv3d, rcti *UNUSED(rect))
 {
        /* axis size */
        const float k = U.rvisize;
@@ -685,7 +685,7 @@ static void draw_view_axis(RegionView3D *rv3d, rcti *rect)
                { 0, 0, size },
        };
 
-       const unsigned char label[] = "xyz";
+       const char label[] = "xyz";
        GLboolean showLabel[3];
 
        GLubyte color[3][4];
diff --git a/source/blender/editors/space_view3d/view3d_intern.h 
b/source/blender/editors/space_view3d/view3d_intern.h
index a02ab00..0e94014 100644
--- a/source/blender/editors/space_view3d/view3d_intern.h
+++ b/source/blender/editors/space_view3d/view3d_intern.h
@@ -52,6 +52,8 @@ struct wmNDOFMotionData;
 struct wmOperatorType;
 struct wmWindowManager;
 struct ListBase;
+struct wmKeyConfig;
+struct GPUTexture;
 
 /* drawing flags: */
 enum {
diff --git a/source/blender/gpu/intern/gpu_matrix.c 
b/source/blender/gpu/intern/gpu_matrix.c
index f322d7b..27f70ed 100644
--- a/source/blender/gpu/intern/gpu_matrix.c
+++ b/source/blender/gpu/intern/gpu_matrix.c
@@ -65,8 +65,6 @@ typedef struct GPU_matrix_stack
 
 
 
-static GLboolean glslneedupdate = GL_TRUE;
-
 static GPU_matrix_stack ms_modelview;
 static GPU_matrix_stack ms_projection;
 static GPU_matrix_stack ms_texture;
diff --git a/source/blender/python/generic/bgl.c 
b/source/blender/python/generic/bgl.c
index f8a8699..7d4a0c6 100644
--- a/source/blender/python/generic/bgl.c
+++ b/source/blender/python/generic/bgl.c
@@ -1467,9 +1467,8 @@ static struct PyMethodDef BGL_methods[] = {
        {NULL, NULL, 0, NULL}
 };
 
-static struct PyMethodDef BGLES2_methods[] = {
-
 #if defined(WITH_GL_PROFILE_ES20)
+static struct PyMethodDef BGLES2_methods[] = {
        MethodDef(AttachShader),
        MethodDef(BindTexture), 
        MethodDef(BlendFunc),
@@ -1540,10 +1539,10 @@ static struct PyMethodDef BGLES2_methods[] = {
        MethodDef(UseProgram),
        MethodDef(ValidateProgram),
        MethodDef(Viewport),
-#endif
 
        {NULL, NULL, 0, NULL}
 };
+#endif
 
 #if defined(WITH_GL_PROFILE_COMPAT)
 static struct PyModuleDef BGL_module_def = {
diff --git a/source/blender/python/intern/bpy_rna.c 
b/source/blender/python/intern/bpy_rna.c
index 5334043..5c76ca3 100644
--- a/source/blender/python/intern/bpy_rna.c
+++ b/source/blender/python/intern/bpy_rna.c
@@ -189,7 +189,7 @@ static GHash *id_weakref_pool_get(ID *id)
 }
 
 /* called from pyrna_struct_CreatePyObject() and pyrna_prop_CreatePyObject() */
-void id_weakref_pool_add(ID *id, BPy_DummyPointerRNA *pyrna)
+static void id_weakref_pool_add(ID *id, BPy_DummyPointerRNA *pyrna)
 {
        PyObject *weakref;
        PyObject *weakref_capsule;
diff --git a/source/blender/python/mathutils/mathutils_geometry.c 
b/source/blender/python/mathutils/mathutils_geometry.c
index 689cbbe..cd5f818 100644
--- a/source/blender/python/mathutils/mathutils_geometry.c
+++ b/source/blender/python/mathutils/mathutils_geometry.c
@@ -1268,8 +1268,9 @@ static PyObject *M_Geometry_tessellate_polygon(PyObject 
*UNUSED(self), PyObject
        ListBase dispbase = {NULL, NULL};
        DispList *dl;
        float *fp; /*pointer to the array of malloced dl->verts to set the 
points from the vectors */
-       int index, *dl_face, totpoints = 0;
-
+       int index, totpoints = 0;
+       unsigned int *dl_face;
+    
        if (!PySequence_Check(polyLineSeq)) {
                PyErr_SetString(PyExc_TypeError,
                                "expected a sequence of poly lines");


@@ Diff output truncated at 10240 characters. @@

_______________________________________________
Bf-blender-cvs mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to