Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-09-04 05:23:50 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-09-04 05:23:50 +0400
commita71b1601842054eb0e663ea49a589cb6074f7d80 (patch)
treeed77c1ce408468cbd5761a8ffdaa3371b2c089a7 /source/blender
parent7283709a40ddcb4f39c6955b44920c79d21d200d (diff)
fix for building on msvc2008 (also style cleanup)
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/blenkernel/intern/mball.c2
-rw-r--r--source/blender/blenlib/intern/BLI_memarena.c4
-rw-r--r--source/blender/blenloader/intern/readfile.c4
-rw-r--r--source/blender/editors/include/UI_interface.h10
-rw-r--r--source/blender/editors/include/UI_view2d.h2
-rw-r--r--source/blender/editors/interface/interface.c3
-rw-r--r--source/blender/editors/space_view3d/drawmesh.c9
-rw-r--r--source/blender/editors/space_view3d/view3d_intern.h2
-rw-r--r--source/blender/gpu/GPU_buffers.h12
-rw-r--r--source/blender/imbuf/IMB_imbuf.h4
-rw-r--r--source/blender/render/extern/include/RE_render_ext.h2
-rw-r--r--source/blender/render/intern/include/pixelshading.h6
-rw-r--r--source/blender/windowmanager/WM_keymap.h6
13 files changed, 36 insertions, 30 deletions
diff --git a/source/blender/blenkernel/intern/mball.c b/source/blender/blenkernel/intern/mball.c
index eebcf12a799..a4fec1c0de4 100644
--- a/source/blender/blenkernel/intern/mball.c
+++ b/source/blender/blenkernel/intern/mball.c
@@ -157,7 +157,7 @@ struct pgn_elements {
/* Forward declarations */
static int vertid(const CORNER *c1, const CORNER *c2, PROCESS *p, MetaBall *mb);
-static int setcenter(CENTERLIST *table[], int i, int j, int k);
+static int setcenter(CENTERLIST *table[], const int i, const int j, const int k);
static CORNER *setcorner(PROCESS *p, int i, int j, int k);
static void converge(const float p1[3], const float p2[3], float v1, float v2,
float (*function)(float, float, float), float p[3], MetaBall *mb, int f);
diff --git a/source/blender/blenlib/intern/BLI_memarena.c b/source/blender/blenlib/intern/BLI_memarena.c
index 8c9993afee8..0ac6209fc95 100644
--- a/source/blender/blenlib/intern/BLI_memarena.c
+++ b/source/blender/blenlib/intern/BLI_memarena.c
@@ -46,7 +46,7 @@ struct MemArena {
LinkNode *bufs;
};
-MemArena *BLI_memarena_new(int bufsize, const char *name)
+MemArena *BLI_memarena_new(const int bufsize, const char *name)
{
MemArena *ma = MEM_callocN(sizeof(*ma), "memarena");
ma->bufsize = bufsize;
@@ -66,7 +66,7 @@ void BLI_memarena_use_malloc(MemArena *ma)
ma->use_calloc = 0;
}
-void BLI_memarena_use_align(struct MemArena *ma, int align)
+void BLI_memarena_use_align(struct MemArena *ma, const int align)
{
/* align should be a power of two */
ma->align = align;
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 974f32c5112..1021d2a794d 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -7029,8 +7029,8 @@ static void do_version_ntree_mask_264(void *UNUSED(data), ID *UNUSED(id), bNodeT
if (node->storage == NULL) {
NodeMask *data = MEM_callocN(sizeof(NodeMask), __func__);
/* move settings into own struct */
- data->size_x = node->custom3;
- data->size_y = node->custom4;
+ data->size_x = (int)node->custom3;
+ data->size_y = (int)node->custom4;
node->custom3 = 0.5f; /* default shutter */
node->storage = data;
}
diff --git a/source/blender/editors/include/UI_interface.h b/source/blender/editors/include/UI_interface.h
index f055c89235d..c6779a3765a 100644
--- a/source/blender/editors/include/UI_interface.h
+++ b/source/blender/editors/include/UI_interface.h
@@ -527,7 +527,7 @@ enum {
BUT_GET_TIP,
BUT_GET_RNA_TIP,
BUT_GET_RNAENUM_TIP,
- BUT_GET_OP_KEYMAP,
+ BUT_GET_OP_KEYMAP
};
typedef struct uiStringInfo {
@@ -538,7 +538,7 @@ typedef struct uiStringInfo {
/* Note: Expects pointers to uiStringInfo structs as parameters.
* Will fill them with translated strings, when possible.
* Strings in uiStringInfo must be MEM_freeN'ed by caller. */
-void uiButGetStrInfo(struct bContext *C, uiBut *but, const int nbr, ...);
+void uiButGetStrInfo(struct bContext *C, uiBut *but, int nbr, ...);
/* Edit i18n stuff. */
/* Name of the main py op from i18n addon. */
@@ -573,7 +573,7 @@ typedef void (*uiIDPoinFuncFP)(struct bContext *C, const char *str, struct ID **
typedef void (*uiIDPoinFunc)(struct bContext *C, struct ID *id, int event);
uiBut *uiDefIDPoinBut(uiBlock *block, uiIDPoinFuncFP func, short blocktype, int retval, const char *str,
- int x, int y, short width, short height, void *idpp, const char *tip);
+ int x, int y, short width, short height, void *idpp, const char *tip);
int uiIconFromID(struct ID *id);
@@ -624,7 +624,9 @@ void uiButSetNFunc(uiBut *but, uiButHandleNFunc func, void *argN, void
void uiButSetCompleteFunc(uiBut *but, uiButCompleteFunc func, void *arg);
-void uiBlockSetDrawExtraFunc(uiBlock *block, void (*func)(const struct bContext *C, void *, void *, void *, struct rcti *rect), void *arg1, void *arg2);
+void uiBlockSetDrawExtraFunc(uiBlock *block,
+ void (*func)(const struct bContext *C, void *, void *, void *, struct rcti *rect),
+ void *arg1, void *arg2);
void uiButSetFocusOnEnter(struct wmWindow *win, uiBut *but);
diff --git a/source/blender/editors/include/UI_view2d.h b/source/blender/editors/include/UI_view2d.h
index 3a8f05a76f0..792c96fe7c8 100644
--- a/source/blender/editors/include/UI_view2d.h
+++ b/source/blender/editors/include/UI_view2d.h
@@ -203,7 +203,7 @@ void UI_view2d_operatortypes(void);
void UI_view2d_keymap(struct wmKeyConfig *keyconf);
void UI_view2d_smooth_view(struct bContext *C, struct ARegion *ar,
- const struct rctf *cur);
+ const struct rctf *cur);
#endif /* __UI_VIEW2D_H__ */
diff --git a/source/blender/editors/interface/interface.c b/source/blender/editors/interface/interface.c
index a1b9c0d6d07..ffce2b618a3 100644
--- a/source/blender/editors/interface/interface.c
+++ b/source/blender/editors/interface/interface.c
@@ -33,7 +33,8 @@
#include <math.h>
#include <string.h>
#include <ctype.h>
-
+#include <stddef.h> /* offsetof() */
+
#include "MEM_guardedalloc.h"
#include "DNA_scene_types.h"
diff --git a/source/blender/editors/space_view3d/drawmesh.c b/source/blender/editors/space_view3d/drawmesh.c
index 1894dd1ac4e..d2b3bcf6825 100644
--- a/source/blender/editors/space_view3d/drawmesh.c
+++ b/source/blender/editors/space_view3d/drawmesh.c
@@ -772,7 +772,8 @@ static int compareDrawOptionsEm(void *userData, int cur_index, int next_index)
return 1;
}
-void draw_mesh_textured_old(Scene *scene, View3D *v3d, RegionView3D *rv3d, Object *ob, DerivedMesh *dm, int draw_flags)
+void draw_mesh_textured_old(Scene *scene, View3D *v3d, RegionView3D *rv3d,
+ Object *ob, DerivedMesh *dm, const int draw_flags)
{
Mesh *me = ob->data;
@@ -941,7 +942,8 @@ static int tex_mat_set_face_editmesh_cb(void *userData, int index)
return !BM_elem_flag_test(efa, BM_ELEM_HIDDEN);
}
-void draw_mesh_textured(Scene *scene, View3D *v3d, RegionView3D *rv3d, Object *ob, DerivedMesh *dm, const int draw_flags)
+void draw_mesh_textured(Scene *scene, View3D *v3d, RegionView3D *rv3d,
+ Object *ob, DerivedMesh *dm, const int draw_flags)
{
if ((!BKE_scene_use_new_shading_nodes(scene)) || (draw_flags & DRAW_MODIFIERS_PREVIEW)) {
draw_mesh_textured_old(scene, v3d, rv3d, ob, dm, draw_flags);
@@ -1017,7 +1019,8 @@ void draw_mesh_textured(Scene *scene, View3D *v3d, RegionView3D *rv3d, Object *o
/* Vertex Paint and Weight Paint */
-void draw_mesh_paint(View3D *v3d, RegionView3D *rv3d, Object *ob, DerivedMesh *dm, int draw_flags)
+void draw_mesh_paint(View3D *v3d, RegionView3D *rv3d,
+ Object *ob, DerivedMesh *dm, const int draw_flags)
{
DMSetDrawOptions facemask = NULL;
Mesh *me = ob->data;
diff --git a/source/blender/editors/space_view3d/view3d_intern.h b/source/blender/editors/space_view3d/view3d_intern.h
index 71e87e73747..5bfabf4fc4a 100644
--- a/source/blender/editors/space_view3d/view3d_intern.h
+++ b/source/blender/editors/space_view3d/view3d_intern.h
@@ -175,7 +175,7 @@ void VIEW3D_OT_game_start(struct wmOperatorType *ot);
int ED_view3d_boundbox_clip(RegionView3D * rv3d, float obmat[][4], struct BoundBox *bb);
void view3d_smooth_view(struct bContext *C, struct View3D *v3d, struct ARegion *ar, struct Object *, struct Object *,
- float *ofs, float *quat, float *dist, float *lens);
+ float *ofs, float *quat, float *dist, float *lens);
void setwinmatrixview3d(ARegion *ar, View3D *v3d, rctf *rect); /* rect: for picking */
void setviewmatrixview3d(Scene *scene, View3D *v3d, RegionView3D *rv3d);
diff --git a/source/blender/gpu/GPU_buffers.h b/source/blender/gpu/GPU_buffers.h
index 629283ce50d..1729ac06f5a 100644
--- a/source/blender/gpu/GPU_buffers.h
+++ b/source/blender/gpu/GPU_buffers.h
@@ -159,18 +159,18 @@ int GPU_buffer_legacy(struct DerivedMesh *dm );
typedef struct GPU_Buffers GPU_Buffers;
GPU_Buffers *GPU_build_mesh_buffers(int (*face_vert_indices)[4],
- struct MFace *mface, struct MVert *mvert,
- int *face_indices, int totface);
+ struct MFace *mface, struct MVert *mvert,
+ int *face_indices, int totface);
void GPU_update_mesh_buffers(GPU_Buffers *buffers, struct MVert *mvert,
- int *vert_indices, int totvert, const float *vmask);
+ int *vert_indices, int totvert, const float *vmask);
GPU_Buffers *GPU_build_grid_buffers(int *grid_indices, int totgrid,
- unsigned int **grid_hidden, int gridsize);
+ unsigned int **grid_hidden, int gridsize);
void GPU_update_grid_buffers(GPU_Buffers *buffers, struct CCGElem **grids,
- const struct DMFlagMat *grid_flag_mats,
- int *grid_indices, int totgrid, const struct CCGKey *key);
+ const struct DMFlagMat *grid_flag_mats,
+ int *grid_indices, int totgrid, const struct CCGKey *key);
void GPU_draw_buffers(GPU_Buffers *buffers, DMSetMaterial setMaterial);
diff --git a/source/blender/imbuf/IMB_imbuf.h b/source/blender/imbuf/IMB_imbuf.h
index a04affd4891..d23d42ddd0c 100644
--- a/source/blender/imbuf/IMB_imbuf.h
+++ b/source/blender/imbuf/IMB_imbuf.h
@@ -483,8 +483,8 @@ void IMB_rectfill_alpha(struct ImBuf *ibuf, const float value);
/* this should not be here, really, we needed it for operating on render data, IMB_rectfill_area calls it */
void buf_rectfill_area(unsigned char *rect, float *rectf, int width, int height,
- const float col[4], const int do_color_management,
- int x1, int y1, int x2, int y2);
+ const float col[4], const int do_color_management,
+ int x1, int y1, int x2, int y2);
/* defined in metadata.c */
int IMB_metadata_change_field(struct ImBuf *img, const char *key, const char *field);
diff --git a/source/blender/render/extern/include/RE_render_ext.h b/source/blender/render/extern/include/RE_render_ext.h
index 604cd940fab..c07ed42332f 100644
--- a/source/blender/render/extern/include/RE_render_ext.h
+++ b/source/blender/render/extern/include/RE_render_ext.h
@@ -65,7 +65,7 @@ void antialias_tagbuf(int xsize, int ysize, char *rectmove);
struct Material *RE_init_sample_material(struct Material *orig_mat, struct Scene *scene);
void RE_free_sample_material(struct Material *mat);
void RE_sample_material_color(struct Material *mat, float color[3], float *alpha, const float volume_co[3], const float surface_co[3],
- int face_index, short hit_quad, struct DerivedMesh *orcoDm, struct Object *ob);
+ int face_index, short hit_quad, struct DerivedMesh *orcoDm, struct Object *ob);
#endif /* __RE_RENDER_EXT_H__ */
diff --git a/source/blender/render/intern/include/pixelshading.h b/source/blender/render/intern/include/pixelshading.h
index 00d731912b6..30d574694b2 100644
--- a/source/blender/render/intern/include/pixelshading.h
+++ b/source/blender/render/intern/include/pixelshading.h
@@ -44,9 +44,9 @@
* \return pointer to the object
*/
int shadeHaloFloat(HaloRen *har,
- float *col, int zz,
- float dist, float xn,
- float yn, short flarec);
+ float *col, int zz,
+ float dist, float xn,
+ float yn, short flarec);
/**
* Render the sky at pixel (x, y).
diff --git a/source/blender/windowmanager/WM_keymap.h b/source/blender/windowmanager/WM_keymap.h
index 78dbd253cd6..5c88babfb47 100644
--- a/source/blender/windowmanager/WM_keymap.h
+++ b/source/blender/windowmanager/WM_keymap.h
@@ -57,11 +57,11 @@ void WM_keymap_init (struct bContext *C);
void WM_keymap_free (struct wmKeyMap *keymap);
wmKeyMapItem *WM_keymap_verify_item(struct wmKeyMap *keymap, const char *idname, int type,
- int val, int modifier, int keymodifier);
+ int val, int modifier, int keymodifier);
wmKeyMapItem *WM_keymap_add_item(struct wmKeyMap *keymap, const char *idname, int type,
- int val, int modifier, int keymodifier);
+ int val, int modifier, int keymodifier);
wmKeyMapItem *WM_keymap_add_menu(struct wmKeyMap *keymap, const char *idname, int type,
- int val, int modifier, int keymodifier);
+ int val, int modifier, int keymodifier);
void WM_keymap_remove_item(struct wmKeyMap *keymap, struct wmKeyMapItem *kmi);
char *WM_keymap_item_to_string(wmKeyMapItem *kmi, char *str, int len);