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-06-10 19:20:10 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-06-10 19:20:10 +0400
commit5534701e5d7659d8fdd73ef64375116bb07463e8 (patch)
tree9c667fb154109a59a0682b036879d15e7038f0ea
parent10932e2e9785b92f786deeec2794816a05a6fed1 (diff)
style cleanup: use capital camel case names for typedef's
-rw-r--r--source/blender/blenkernel/intern/anim.c8
-rw-r--r--source/blender/blenkernel/intern/seqcache.c40
-rw-r--r--source/blender/blenlib/BLI_boxpack2d.h2
-rw-r--r--source/blender/blenlib/intern/boxpack2d.c28
-rw-r--r--source/blender/blenlib/intern/fileops.c70
-rw-r--r--source/blender/editors/animation/keyframes_general.c8
-rw-r--r--source/blender/editors/mesh/editmesh_loopcut.c22
-rw-r--r--source/blender/editors/mesh/editmesh_tools.c38
-rw-r--r--source/blender/editors/sculpt_paint/paint_vertex.c12
-rw-r--r--source/gameengine/Ketsji/KX_NearSensor.h2
-rw-r--r--source/gameengine/Ketsji/KX_TouchSensor.h6
-rw-r--r--source/gameengine/VideoTexture/ImageBase.cpp6
12 files changed, 122 insertions, 120 deletions
diff --git a/source/blender/blenkernel/intern/anim.c b/source/blender/blenkernel/intern/anim.c
index 701ce6c8299..170638f0e8d 100644
--- a/source/blender/blenkernel/intern/anim.c
+++ b/source/blender/blenkernel/intern/anim.c
@@ -840,7 +840,7 @@ static void frames_duplilist(ListBase *lb, Scene *scene, Object *ob, int par_ind
*ob = copyob;
}
-typedef struct vertexDupliData {
+typedef struct VertexDupliData {
ID *id; /* scene or group, for recursive loops */
int level;
int animated;
@@ -851,7 +851,7 @@ typedef struct vertexDupliData {
Object *ob, *par;
float (*orco)[3];
int par_index;
-} vertexDupliData;
+} VertexDupliData;
/* ------------- */
@@ -859,7 +859,7 @@ static void vertex_dupli__mapFunc(void *userData, int index, const float co[3],
const float no_f[3], const short no_s[3])
{
DupliObject *dob;
- vertexDupliData *vdd = userData;
+ VertexDupliData *vdd = userData;
float vec[3], q2[4], mat[3][3], tmat[4][4], obmat[4][4];
int origlay;
@@ -910,7 +910,7 @@ static void vertex_duplilist(ListBase *lb, ID *id, Scene *scene, Object *par, fl
Mesh *me = par->data;
Base *base = NULL;
DerivedMesh *dm;
- vertexDupliData vdd;
+ VertexDupliData vdd;
Scene *sce = NULL;
Group *group = NULL;
GroupObject *go = NULL;
diff --git a/source/blender/blenkernel/intern/seqcache.c b/source/blender/blenkernel/intern/seqcache.c
index ea4699f8495..582034ae623 100644
--- a/source/blender/blenkernel/intern/seqcache.c
+++ b/source/blender/blenkernel/intern/seqcache.c
@@ -29,7 +29,7 @@
#include <stddef.h>
-#include "BLO_sys_types.h" /* for intptr_t */
+#include "BLO_sys_types.h" /* for intptr_t */
#include "MEM_guardedalloc.h"
@@ -38,21 +38,21 @@
#include "IMB_moviecache.h"
-typedef struct seqCacheKey {
- struct Sequence * seq;
+typedef struct SeqCacheKey {
+ struct Sequence *seq;
SeqRenderData context;
float cfra;
seq_stripelem_ibuf_t type;
-} seqCacheKey;
+} SeqCacheKey;
static struct MovieCache *moviecache = NULL;
static unsigned int seqcache_hashhash(const void *key_)
{
- const seqCacheKey *key = (seqCacheKey*) key_;
+ const SeqCacheKey *key = (SeqCacheKey *) key_;
unsigned int rval = seq_hash_render_data(&key->context);
- rval ^= *(unsigned int*) &key->cfra;
+ rval ^= *(unsigned int *) &key->cfra;
rval += key->type;
rval ^= ((intptr_t) key->seq) << 6;
@@ -61,11 +61,11 @@ static unsigned int seqcache_hashhash(const void *key_)
static int seqcache_hashcmp(const void *a_, const void *b_)
{
- const seqCacheKey * a = (seqCacheKey*) a_;
- const seqCacheKey * b = (seqCacheKey*) b_;
+ const SeqCacheKey *a = (SeqCacheKey *) a_;
+ const SeqCacheKey *b = (SeqCacheKey *) b_;
if (a->seq < b->seq) {
- return -1;
+ return -1;
}
if (a->seq > b->seq) {
return 1;
@@ -98,18 +98,18 @@ void seq_stripelem_cache_cleanup(void)
{
if (moviecache) {
IMB_moviecache_free(moviecache);
- moviecache = IMB_moviecache_create(sizeof(seqCacheKey), seqcache_hashhash,
- seqcache_hashcmp, NULL);
+ moviecache = IMB_moviecache_create(sizeof(SeqCacheKey), seqcache_hashhash,
+ seqcache_hashcmp, NULL);
}
}
-struct ImBuf * seq_stripelem_cache_get(
- SeqRenderData context, struct Sequence * seq,
- float cfra, seq_stripelem_ibuf_t type)
+struct ImBuf *seq_stripelem_cache_get(
+ SeqRenderData context, struct Sequence *seq,
+ float cfra, seq_stripelem_ibuf_t type)
{
if (moviecache && seq) {
- seqCacheKey key;
+ SeqCacheKey key;
key.seq = seq;
key.context = context;
@@ -123,18 +123,18 @@ struct ImBuf * seq_stripelem_cache_get(
}
void seq_stripelem_cache_put(
- SeqRenderData context, struct Sequence * seq,
- float cfra, seq_stripelem_ibuf_t type, struct ImBuf * i)
+ SeqRenderData context, struct Sequence *seq,
+ float cfra, seq_stripelem_ibuf_t type, struct ImBuf *i)
{
- seqCacheKey key;
+ SeqCacheKey key;
if (!i) {
return;
}
if (!moviecache) {
- moviecache = IMB_moviecache_create(sizeof(seqCacheKey), seqcache_hashhash,
- seqcache_hashcmp, NULL);
+ moviecache = IMB_moviecache_create(sizeof(SeqCacheKey), seqcache_hashhash,
+ seqcache_hashcmp, NULL);
}
key.seq = seq;
diff --git a/source/blender/blenlib/BLI_boxpack2d.h b/source/blender/blenlib/BLI_boxpack2d.h
index 77e937d7b6f..3bc486054f5 100644
--- a/source/blender/blenlib/BLI_boxpack2d.h
+++ b/source/blender/blenlib/BLI_boxpack2d.h
@@ -43,7 +43,7 @@ typedef struct BoxPack {
/* Verts this box uses
* (BL,TR,TL,BR) / 0,1,2,3 */
- struct boxVert *v[4];
+ struct BoxVert *v[4];
} BoxPack;
void BLI_box_pack_2D(BoxPack *boxarray, const int len, float *tot_width, float *tot_height);
diff --git a/source/blender/blenlib/intern/boxpack2d.c b/source/blender/blenlib/intern/boxpack2d.c
index bf63517a4c2..feaa60b40b2 100644
--- a/source/blender/blenlib/intern/boxpack2d.c
+++ b/source/blender/blenlib/intern/boxpack2d.c
@@ -33,7 +33,7 @@
*
* The defined Below are for internal use only */
-typedef struct boxVert {
+typedef struct BoxVert {
float x;
float y;
short free;
@@ -48,7 +48,7 @@ typedef struct boxVert {
struct BoxPack *isect_cache[4];
int index;
-} boxVert;
+} BoxVert;
/* free vert flags */
#define EPSILON 0.0000001f
@@ -121,11 +121,11 @@ static int box_areasort(const void *p1, const void *p2)
* */
static float box_width;
static float box_height;
-static boxVert *vertarray;
+static BoxVert *vertarray;
static int vertex_sort(const void *p1, const void *p2)
{
- boxVert *v1, *v2;
+ BoxVert *v1, *v2;
float a1, a2;
v1 = vertarray + ((int *)p1)[0];
@@ -154,7 +154,7 @@ static int vertex_sort(const void *p1, const void *p2)
* */
void BLI_box_pack_2D(BoxPack *boxarray, const int len, float *tot_width, float *tot_height)
{
- boxVert *vert; /* the current vert */
+ BoxVert *vert; /* the current vert */
int box_index, verts_pack_len, i, j, k, isect;
int quad_flags[4] = {BLF, TRF, TLF, BRF}; /* use for looping */
BoxPack *box, *box_test; /*current box and another for intersection tests*/
@@ -170,38 +170,38 @@ void BLI_box_pack_2D(BoxPack *boxarray, const int len, float *tot_width, float *
qsort(boxarray, len, sizeof(BoxPack), box_areasort);
/* add verts to the boxes, these are only used internally */
- vert = vertarray = MEM_mallocN(len * 4 * sizeof(boxVert), "BoxPack Verts");
+ vert = vertarray = MEM_mallocN(len * 4 * sizeof(BoxVert), "BoxPack Verts");
vertex_pack_indices = MEM_mallocN(len * 3 * sizeof(int), "BoxPack Indices");
for (box = boxarray, box_index = 0, i = 0; box_index < len; box_index++, box++) {
vert->blb = vert->brb = vert->tlb =
- vert->isect_cache[0] = vert->isect_cache[1] =
- vert->isect_cache[2] = vert->isect_cache[3] = NULL;
+ vert->isect_cache[0] = vert->isect_cache[1] =
+ vert->isect_cache[2] = vert->isect_cache[3] = NULL;
vert->free = CORNERFLAGS & ~TRF;
vert->trb = box;
vert->index = i; i++;
box->v[BL] = vert; vert++;
vert->trb = vert->brb = vert->tlb =
- vert->isect_cache[0] = vert->isect_cache[1] =
- vert->isect_cache[2] = vert->isect_cache[3] = NULL;
+ vert->isect_cache[0] = vert->isect_cache[1] =
+ vert->isect_cache[2] = vert->isect_cache[3] = NULL;
vert->free = CORNERFLAGS & ~BLF;
vert->blb = box;
vert->index = i; i++;
box->v[TR] = vert; vert++;
vert->trb = vert->blb = vert->tlb =
- vert->isect_cache[0] = vert->isect_cache[1] =
- vert->isect_cache[2] = vert->isect_cache[3] = NULL;
+ vert->isect_cache[0] = vert->isect_cache[1] =
+ vert->isect_cache[2] = vert->isect_cache[3] = NULL;
vert->free = CORNERFLAGS & ~BRF;
vert->brb = box;
vert->index = i; i++;
box->v[TL] = vert; vert++;
vert->trb = vert->blb = vert->brb =
- vert->isect_cache[0] = vert->isect_cache[1] =
- vert->isect_cache[2] = vert->isect_cache[3] = NULL;
+ vert->isect_cache[0] = vert->isect_cache[1] =
+ vert->isect_cache[2] = vert->isect_cache[3] = NULL;
vert->free = CORNERFLAGS & ~TLF;
vert->tlb = box;
vert->index = i; i++;
diff --git a/source/blender/blenlib/intern/fileops.c b/source/blender/blenlib/intern/fileops.c
index e6d06484e74..ec7b59702bd 100644
--- a/source/blender/blenlib/intern/fileops.c
+++ b/source/blender/blenlib/intern/fileops.c
@@ -385,16 +385,16 @@ int BLI_rename(const char *from, const char *to)
enum {
/* operation succeeded succeeded */
- recursiveOp_Callback_OK = 0,
+ RecursiveOp_Callback_OK = 0,
/* operation requested not to perform recursive digging for current path */
- recursiveOp_Callback_StopRecurs = 1,
+ RecursiveOp_Callback_StopRecurs = 1,
/* error occured in callback and recursive walking should stop immediately */
- recursiveOp_Callback_Error = 2
+ RecursiveOp_Callback_Error = 2
} recuresiveOp_Callback_Result;
-typedef int (*recursiveOp_Callback)(const char *from, const char *to);
+typedef int (*RecursiveOp_Callback)(const char *from, const char *to);
/* appending of filename to dir (ensures for buffer size before appending) */
static void join_dirfile_alloc(char **dst, size_t *alloc_len, const char *dir, const char *file)
@@ -419,8 +419,8 @@ static char *strip_last_slash(const char *dir)
return result;
}
-static int recursive_operation(const char *startfrom, const char *startto, recursiveOp_Callback callback_dir_pre,
- recursiveOp_Callback callback_file, recursiveOp_Callback callback_dir_post)
+static int recursive_operation(const char *startfrom, const char *startto, RecursiveOp_Callback callback_dir_pre,
+ RecursiveOp_Callback callback_file, RecursiveOp_Callback callback_dir_post)
{
struct dirent **dirlist;
struct stat st;
@@ -446,7 +446,7 @@ static int recursive_operation(const char *startfrom, const char *startto, recur
if (callback_file) {
ret = callback_file(from, to);
- if (ret != recursiveOp_Callback_OK)
+ if (ret != RecursiveOp_Callback_OK)
ret = -1;
}
@@ -472,11 +472,11 @@ static int recursive_operation(const char *startfrom, const char *startto, recur
/* call pre-recursive walking directory callback */
ret = callback_dir_pre(from, to);
- if (ret != recursiveOp_Callback_OK) {
+ if (ret != RecursiveOp_Callback_OK) {
MEM_freeN(from);
if (to) free(to);
- if (ret == recursiveOp_Callback_StopRecurs) {
+ if (ret == RecursiveOp_Callback_StopRecurs) {
/* callback requested not to perform recursive walking, not an error */
return 0;
}
@@ -505,7 +505,7 @@ static int recursive_operation(const char *startfrom, const char *startto, recur
else if (callback_file) {
/* call file callback for current path */
ret = callback_file(from_path, to_path);
- if (ret != recursiveOp_Callback_OK)
+ if (ret != RecursiveOp_Callback_OK)
ret = -1;
}
@@ -522,7 +522,7 @@ static int recursive_operation(const char *startfrom, const char *startto, recur
if (callback_dir_post) {
/* call post-recursive directory callback */
ret = callback_dir_post(from, to);
- if (ret != recursiveOp_Callback_OK)
+ if (ret != RecursiveOp_Callback_OK)
ret = -1;
}
}
@@ -541,10 +541,10 @@ static int delete_callback_post(const char *from, const char *UNUSED(to))
if (rmdir(from)) {
perror("rmdir");
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
- return recursiveOp_Callback_OK;
+ return RecursiveOp_Callback_OK;
}
static int delete_single_file(const char *from, const char *UNUSED(to))
@@ -552,10 +552,10 @@ static int delete_single_file(const char *from, const char *UNUSED(to))
if (unlink(from)) {
perror("unlink");
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
- return recursiveOp_Callback_OK;
+ return RecursiveOp_Callback_OK;
}
FILE *BLI_fopen(const char *filename, const char *mode)
@@ -628,27 +628,27 @@ static int copy_callback_pre(const char *from, const char *to)
if (check_the_same(from, to)) {
fprintf(stderr, "%s: '%s' is the same as '%s'\n", __func__, from, to);
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
if (lstat(from, &st)) {
perror("stat");
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
/* create a directory */
if (mkdir(to, st.st_mode)) {
perror("mkdir");
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
/* set proper owner and group on new directory */
if (chown(to, st.st_uid, st.st_gid)) {
perror("chown");
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
- return recursiveOp_Callback_OK;
+ return RecursiveOp_Callback_OK;
}
static int copy_single_file(const char *from, const char *to)
@@ -660,12 +660,12 @@ static int copy_single_file(const char *from, const char *to)
if (check_the_same(from, to)) {
fprintf(stderr, "%s: '%s' is the same as '%s'\n", __func__, from, to);
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
if (lstat(from, &st)) {
perror("lstat");
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
if (S_ISLNK(st.st_mode)) {
@@ -690,7 +690,7 @@ static int copy_single_file(const char *from, const char *to)
if (need_free) MEM_freeN(link_buffer);
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
link_buffer[link_len] = 0;
@@ -698,13 +698,13 @@ static int copy_single_file(const char *from, const char *to)
if (symlink(link_buffer, to)) {
perror("symlink");
if (need_free) MEM_freeN(link_buffer);
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
if (need_free)
MEM_freeN(link_buffer);
- return recursiveOp_Callback_OK;
+ return RecursiveOp_Callback_OK;
}
else if (S_ISCHR(st.st_mode) ||
S_ISBLK(st.st_mode) ||
@@ -714,30 +714,30 @@ static int copy_single_file(const char *from, const char *to)
/* copy special type of file */
if (mknod(to, st.st_mode, st.st_rdev)) {
perror("mknod");
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
if (set_permissions(to, &st))
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
- return recursiveOp_Callback_OK;
+ return RecursiveOp_Callback_OK;
}
else if (!S_ISREG(st.st_mode)) {
fprintf(stderr, "Copying of this kind of files isn't supported yet\n");
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
from_stream = fopen(from, "rb");
if (!from_stream) {
perror("fopen");
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
to_stream = fopen(to, "wb");
if (!to_stream) {
perror("fopen");
fclose(from_stream);
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
}
while ((len = fread(buf, 1, sizeof(buf), from_stream)) > 0) {
@@ -748,9 +748,9 @@ static int copy_single_file(const char *from, const char *to)
fclose(from_stream);
if (set_permissions(to, &st))
- return recursiveOp_Callback_Error;
+ return RecursiveOp_Callback_Error;
- return recursiveOp_Callback_OK;
+ return RecursiveOp_Callback_OK;
}
static int move_callback_pre(const char *from, const char *to)
@@ -760,7 +760,7 @@ static int move_callback_pre(const char *from, const char *to)
if (ret)
return copy_callback_pre(from, to);
- return recursiveOp_Callback_StopRecurs;
+ return RecursiveOp_Callback_StopRecurs;
}
static int move_single_file(const char *from, const char *to)
@@ -770,7 +770,7 @@ static int move_single_file(const char *from, const char *to)
if (ret)
return copy_single_file(from, to);
- return recursiveOp_Callback_OK;
+ return RecursiveOp_Callback_OK;
}
int BLI_move(const char *file, const char *to)
diff --git a/source/blender/editors/animation/keyframes_general.c b/source/blender/editors/animation/keyframes_general.c
index ac37b6c4141..14bee00a72a 100644
--- a/source/blender/editors/animation/keyframes_general.c
+++ b/source/blender/editors/animation/keyframes_general.c
@@ -374,16 +374,16 @@ void smooth_fcurve(FCurve *fcu)
/* ---------------- */
/* little cache for values... */
-typedef struct tempFrameValCache {
+typedef struct TempFrameValCache {
float frame, val;
-} tempFrameValCache;
+} TempFrameValCache;
/* Evaluates the curves between each selected keyframe on each frame, and keys the value */
void sample_fcurve(FCurve *fcu)
{
BezTriple *bezt, *start = NULL, *end = NULL;
- tempFrameValCache *value_cache, *fp;
+ TempFrameValCache *value_cache, *fp;
int sfra, range;
int i, n, nIndex;
@@ -406,7 +406,7 @@ void sample_fcurve(FCurve *fcu)
sfra = (int)(floor(start->vec[1][0]) );
if (range) {
- value_cache = MEM_callocN(sizeof(tempFrameValCache) * range, "IcuFrameValCache");
+ value_cache = MEM_callocN(sizeof(TempFrameValCache) * range, "IcuFrameValCache");
/* sample values */
for (n = 1, fp = value_cache; n < range && fp; n++, fp++) {
diff --git a/source/blender/editors/mesh/editmesh_loopcut.c b/source/blender/editors/mesh/editmesh_loopcut.c
index 7298153791e..185c804661d 100644
--- a/source/blender/editors/mesh/editmesh_loopcut.c
+++ b/source/blender/editors/mesh/editmesh_loopcut.c
@@ -86,7 +86,7 @@
/* ringsel operator */
/* struct for properties used while drawing */
-typedef struct tringselOpData {
+typedef struct RingSelOpData {
ARegion *ar; /* region that ringsel was activated in */
void *draw_handle; /* for drawing preview loop */
@@ -102,13 +102,13 @@ typedef struct tringselOpData {
int extend;
int do_cut;
-} tringselOpData;
+} RingSelOpData;
/* modal loop selection drawing callback */
static void ringsel_draw(const bContext *C, ARegion *UNUSED(ar), void *arg)
{
View3D *v3d = CTX_wm_view3d(C);
- tringselOpData *lcd = arg;
+ RingSelOpData *lcd = arg;
int i;
if (lcd->totedge > 0) {
@@ -176,7 +176,7 @@ static void edgering_find_order(BMEdge *lasteed, BMEdge *eed,
}
}
-static void edgering_sel(tringselOpData *lcd, int previewlines, int select)
+static void edgering_sel(RingSelOpData *lcd, int previewlines, int select)
{
BMEditMesh *em = lcd->em;
BMEdge *startedge = lcd->eed;
@@ -290,7 +290,7 @@ static void edgering_sel(tringselOpData *lcd, int previewlines, int select)
lcd->totedge = tot;
}
-static void ringsel_find_edge(tringselOpData *lcd, int cuts)
+static void ringsel_find_edge(RingSelOpData *lcd, int cuts)
{
if (lcd->eed) {
edgering_sel(lcd, cuts, 0);
@@ -304,7 +304,7 @@ static void ringsel_find_edge(tringselOpData *lcd, int cuts)
static void ringsel_finish(bContext *C, wmOperator *op)
{
- tringselOpData *lcd = op->customdata;
+ RingSelOpData *lcd = op->customdata;
int cuts = RNA_int_get(op->ptr, "number_cuts");
if (lcd->eed) {
@@ -350,7 +350,7 @@ static void ringsel_finish(bContext *C, wmOperator *op)
/* called when modal loop selection is done... */
static void ringsel_exit(bContext *UNUSED(C), wmOperator *op)
{
- tringselOpData *lcd = op->customdata;
+ RingSelOpData *lcd = op->customdata;
/* deactivate the extra drawing stuff in 3D-View */
ED_region_draw_cb_exit(lcd->ar->type, lcd->draw_handle);
@@ -368,10 +368,10 @@ static void ringsel_exit(bContext *UNUSED(C), wmOperator *op)
/* called when modal loop selection gets set up... */
static int ringsel_init(bContext *C, wmOperator *op, int do_cut)
{
- tringselOpData *lcd;
+ RingSelOpData *lcd;
/* alloc new customdata */
- lcd = op->customdata = MEM_callocN(sizeof(tringselOpData), "ringsel Modal Op Data");
+ lcd = op->customdata = MEM_callocN(sizeof(RingSelOpData), "ringsel Modal Op Data");
/* assign the drawing handle for drawing preview line... */
lcd->ar = CTX_wm_region(C);
@@ -402,7 +402,7 @@ static int ringcut_cancel(bContext *C, wmOperator *op)
static int ringcut_invoke(bContext *C, wmOperator *op, wmEvent *evt)
{
Object *obedit = CTX_data_edit_object(C);
- tringselOpData *lcd;
+ RingSelOpData *lcd;
BMEdge *edge;
int dist = 75;
@@ -434,7 +434,7 @@ static int ringcut_invoke(bContext *C, wmOperator *op, wmEvent *evt)
static int loopcut_modal(bContext *C, wmOperator *op, wmEvent *event)
{
int cuts = RNA_int_get(op->ptr, "number_cuts");
- tringselOpData *lcd = op->customdata;
+ RingSelOpData *lcd = op->customdata;
int show_cuts = 0;
view3d_operator_needs_opengl(C);
diff --git a/source/blender/editors/mesh/editmesh_tools.c b/source/blender/editors/mesh/editmesh_tools.c
index b6d89a62d05..0f7d4c5c547 100644
--- a/source/blender/editors/mesh/editmesh_tools.c
+++ b/source/blender/editors/mesh/editmesh_tools.c
@@ -3676,14 +3676,14 @@ enum {
SRT_REVERSE, /* Reverse current order of selected elements. */
};
-typedef struct bmelemsort {
+typedef struct BMElemSort {
float srt; /* Sort factor */
int org_idx; /* Original index of this element _in its mempool_ */
-} bmelemsort;
+} BMElemSort;
static int bmelemsort_comp(const void *v1, const void *v2)
{
- const bmelemsort *x1 = v1, *x2 = v2;
+ const BMElemSort *x1 = v1, *x2 = v2;
return (x1->srt > x2->srt) - (x1->srt < x2->srt);
}
@@ -3704,7 +3704,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
/* In all five elements below, 0 = vertices, 1 = edges, 2 = faces. */
/* Just to mark protected elements. */
char *pblock[3] = {NULL, NULL, NULL}, *pb;
- bmelemsort *sblock[3] = {NULL, NULL, NULL}, *sb;
+ BMElemSort *sblock[3] = {NULL, NULL, NULL}, *sb;
int *map[3] = {NULL, NULL, NULL}, *mp;
int totelem[3] = {0, 0, 0}, tot;
int affected[3] = {0, 0, 0}, aff;
@@ -3733,7 +3733,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[0]) {
pb = pblock[0] = MEM_callocN(sizeof(char) * totelem[0], "sort_bmelem vert pblock");
- sb = sblock[0] = MEM_callocN(sizeof(bmelemsort) * totelem[0], "sort_bmelem vert sblock");
+ sb = sblock[0] = MEM_callocN(sizeof(BMElemSort) * totelem[0], "sort_bmelem vert sblock");
BM_ITER_MESH_INDEX (ve, &iter, em->bm, BM_VERTS_OF_MESH, i) {
if (BM_elem_flag_test(ve, flag)) {
@@ -3752,7 +3752,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[1]) {
pb = pblock[1] = MEM_callocN(sizeof(char) * totelem[1], "sort_bmelem edge pblock");
- sb = sblock[1] = MEM_callocN(sizeof(bmelemsort) * totelem[1], "sort_bmelem edge sblock");
+ sb = sblock[1] = MEM_callocN(sizeof(BMElemSort) * totelem[1], "sort_bmelem edge sblock");
BM_ITER_MESH_INDEX (ed, &iter, em->bm, BM_EDGES_OF_MESH, i) {
if (BM_elem_flag_test(ed, flag)) {
@@ -3772,7 +3772,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[2]) {
pb = pblock[2] = MEM_callocN(sizeof(char) * totelem[2], "sort_bmelem face pblock");
- sb = sblock[2] = MEM_callocN(sizeof(bmelemsort) * totelem[2], "sort_bmelem face sblock");
+ sb = sblock[2] = MEM_callocN(sizeof(BMElemSort) * totelem[2], "sort_bmelem face sblock");
BM_ITER_MESH_INDEX (fa, &iter, em->bm, BM_FACES_OF_MESH, i) {
if (BM_elem_flag_test(fa, flag)) {
@@ -3806,7 +3806,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[0]) {
pb = pblock[0] = MEM_callocN(sizeof(char) * totelem[0], "sort_bmelem vert pblock");
- sb = sblock[0] = MEM_callocN(sizeof(bmelemsort) * totelem[0], "sort_bmelem vert sblock");
+ sb = sblock[0] = MEM_callocN(sizeof(BMElemSort) * totelem[0], "sort_bmelem vert sblock");
BM_ITER_MESH_INDEX (ve, &iter, em->bm, BM_VERTS_OF_MESH, i) {
if (BM_elem_flag_test(ve, flag)) {
@@ -3822,7 +3822,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[1]) {
pb = pblock[1] = MEM_callocN(sizeof(char) * totelem[1], "sort_bmelem edge pblock");
- sb = sblock[1] = MEM_callocN(sizeof(bmelemsort) * totelem[1], "sort_bmelem edge sblock");
+ sb = sblock[1] = MEM_callocN(sizeof(BMElemSort) * totelem[1], "sort_bmelem edge sblock");
BM_ITER_MESH_INDEX (ed, &iter, em->bm, BM_EDGES_OF_MESH, i) {
if (BM_elem_flag_test(ed, flag)) {
@@ -3841,7 +3841,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[2]) {
pb = pblock[2] = MEM_callocN(sizeof(char) * totelem[2], "sort_bmelem face pblock");
- sb = sblock[2] = MEM_callocN(sizeof(bmelemsort) * totelem[2], "sort_bmelem face sblock");
+ sb = sblock[2] = MEM_callocN(sizeof(BMElemSort) * totelem[2], "sort_bmelem face sblock");
BM_ITER_MESH_INDEX (fa, &iter, em->bm, BM_FACES_OF_MESH, i) {
if (BM_elem_flag_test(fa, flag)) {
@@ -3862,7 +3862,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
/* Faces only! */
else if (action == SRT_MATERIAL && totelem[2]) {
pb = pblock[2] = MEM_callocN(sizeof(char) * totelem[2], "sort_bmelem face pblock");
- sb = sblock[2] = MEM_callocN(sizeof(bmelemsort) * totelem[2], "sort_bmelem face sblock");
+ sb = sblock[2] = MEM_callocN(sizeof(BMElemSort) * totelem[2], "sort_bmelem face sblock");
BM_ITER_MESH_INDEX (fa, &iter, em->bm, BM_FACES_OF_MESH, i) {
if (BM_elem_flag_test(fa, flag)) {
@@ -3966,7 +3966,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
* enabling/disabling an element type. */
BLI_srandom(seed);
pb = pblock[0] = MEM_callocN(sizeof(char) * totelem[0], "sort_bmelem vert pblock");
- sb = sblock[0] = MEM_callocN(sizeof(bmelemsort) * totelem[0], "sort_bmelem vert sblock");
+ sb = sblock[0] = MEM_callocN(sizeof(BMElemSort) * totelem[0], "sort_bmelem vert sblock");
BM_ITER_MESH_INDEX (ve, &iter, em->bm, BM_VERTS_OF_MESH, i) {
if (BM_elem_flag_test(ve, flag)) {
@@ -3983,7 +3983,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[1]) {
BLI_srandom(seed);
pb = pblock[1] = MEM_callocN(sizeof(char) * totelem[1], "sort_bmelem edge pblock");
- sb = sblock[1] = MEM_callocN(sizeof(bmelemsort) * totelem[1], "sort_bmelem edge sblock");
+ sb = sblock[1] = MEM_callocN(sizeof(BMElemSort) * totelem[1], "sort_bmelem edge sblock");
BM_ITER_MESH_INDEX (ed, &iter, em->bm, BM_EDGES_OF_MESH, i) {
if (BM_elem_flag_test(ed, flag)) {
@@ -4000,7 +4000,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[2]) {
BLI_srandom(seed);
pb = pblock[2] = MEM_callocN(sizeof(char) * totelem[2], "sort_bmelem face pblock");
- sb = sblock[2] = MEM_callocN(sizeof(bmelemsort) * totelem[2], "sort_bmelem face sblock");
+ sb = sblock[2] = MEM_callocN(sizeof(BMElemSort) * totelem[2], "sort_bmelem face sblock");
BM_ITER_MESH_INDEX (fa, &iter, em->bm, BM_FACES_OF_MESH, i) {
if (BM_elem_flag_test(fa, flag)) {
@@ -4018,7 +4018,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
else if (action == SRT_REVERSE) {
if (totelem[0]) {
pb = pblock[0] = MEM_callocN(sizeof(char) * totelem[0], "sort_bmelem vert pblock");
- sb = sblock[0] = MEM_callocN(sizeof(bmelemsort) * totelem[0], "sort_bmelem vert sblock");
+ sb = sblock[0] = MEM_callocN(sizeof(BMElemSort) * totelem[0], "sort_bmelem vert sblock");
BM_ITER_MESH_INDEX (ve, &iter, em->bm, BM_VERTS_OF_MESH, i) {
if (BM_elem_flag_test(ve, flag)) {
@@ -4034,7 +4034,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[1]) {
pb = pblock[1] = MEM_callocN(sizeof(char) * totelem[1], "sort_bmelem edge pblock");
- sb = sblock[1] = MEM_callocN(sizeof(bmelemsort) * totelem[1], "sort_bmelem edge sblock");
+ sb = sblock[1] = MEM_callocN(sizeof(BMElemSort) * totelem[1], "sort_bmelem edge sblock");
BM_ITER_MESH_INDEX (ed, &iter, em->bm, BM_EDGES_OF_MESH, i) {
if (BM_elem_flag_test(ed, flag)) {
@@ -4050,7 +4050,7 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
if (totelem[2]) {
pb = pblock[2] = MEM_callocN(sizeof(char) * totelem[2], "sort_bmelem face pblock");
- sb = sblock[2] = MEM_callocN(sizeof(bmelemsort) * totelem[2], "sort_bmelem face sblock");
+ sb = sblock[2] = MEM_callocN(sizeof(BMElemSort) * totelem[2], "sort_bmelem face sblock");
BM_ITER_MESH_INDEX (fa, &iter, em->bm, BM_FACES_OF_MESH, i) {
if (BM_elem_flag_test(fa, flag)) {
@@ -4086,11 +4086,11 @@ static void sort_bmelem_flag(bContext *C, const int types, const int flag, const
sb = sblock[j];
if (pb && sb && !map[j]) {
char *p_blk;
- bmelemsort *s_blk;
+ BMElemSort *s_blk;
tot = totelem[j];
aff = affected[j];
- qsort(sb, aff, sizeof(bmelemsort), bmelemsort_comp);
+ qsort(sb, aff, sizeof(BMElemSort), bmelemsort_comp);
mp = map[j] = MEM_mallocN(sizeof(int) * tot, "sort_bmelem map");
p_blk = pb + tot - 1;
diff --git a/source/blender/editors/sculpt_paint/paint_vertex.c b/source/blender/editors/sculpt_paint/paint_vertex.c
index 43981770784..3c37ad8cf2a 100644
--- a/source/blender/editors/sculpt_paint/paint_vertex.c
+++ b/source/blender/editors/sculpt_paint/paint_vertex.c
@@ -2624,10 +2624,10 @@ void PAINT_OT_vertex_paint_toggle(wmOperatorType *ot)
* - revise whether op->customdata should be added in object, in set_vpaint
*/
-typedef struct polyfacemap_e {
- struct polyfacemap_e *next, *prev;
+typedef struct PolyFaceMap {
+ struct PolyFaceMap *next, *prev;
int facenr;
-} polyfacemap_e;
+} PolyFaceMap;
typedef struct VPaintData {
ViewContext vc;
@@ -2648,7 +2648,7 @@ typedef struct VPaintData {
static void vpaint_build_poly_facemap(struct VPaintData *vd, Mesh *me)
{
MFace *mf;
- polyfacemap_e *e;
+ PolyFaceMap *e;
int *origIndex;
int i;
@@ -2667,7 +2667,7 @@ static void vpaint_build_poly_facemap(struct VPaintData *vd, Mesh *me)
if (*origIndex == ORIGINDEX_NONE)
continue;
- e = BLI_memarena_alloc(vd->polyfacemap_arena, sizeof(polyfacemap_e));
+ e = BLI_memarena_alloc(vd->polyfacemap_arena, sizeof(PolyFaceMap));
e->facenr = i;
BLI_addtail(&vd->polyfacemap[*origIndex], e);
@@ -2784,7 +2784,7 @@ static void vpaint_paint_poly(VPaint *vp, VPaintData *vpd, Object *ob,
MCol *mc;
MLoop *ml;
MLoopCol *mlc;
- polyfacemap_e *e;
+ PolyFaceMap *e;
unsigned int *lcol = ((unsigned int *)me->mloopcol) + mpoly->loopstart;
unsigned int *lcolorig = ((unsigned int *)vp->vpaint_prev) + mpoly->loopstart;
float alpha;
diff --git a/source/gameengine/Ketsji/KX_NearSensor.h b/source/gameengine/Ketsji/KX_NearSensor.h
index 8655d93d406..82f523283ed 100644
--- a/source/gameengine/Ketsji/KX_NearSensor.h
+++ b/source/gameengine/Ketsji/KX_NearSensor.h
@@ -74,7 +74,7 @@ public:
virtual void ReParent(SCA_IObject* parent);
virtual bool NewHandleCollision(void* obj1,void* obj2,
- const PHY_CollData * coll_data);
+ const PHY_CollData * coll_data);
virtual bool BroadPhaseFilterCollision(void*obj1,void*obj2);
virtual bool BroadPhaseSensorFilterCollision(void* obj1,void* obj2) { return false; }
virtual sensortype GetSensorType() { return ST_NEAR; }
diff --git a/source/gameengine/Ketsji/KX_TouchSensor.h b/source/gameengine/Ketsji/KX_TouchSensor.h
index 1a22067f9ac..d739144d70d 100644
--- a/source/gameengine/Ketsji/KX_TouchSensor.h
+++ b/source/gameengine/Ketsji/KX_TouchSensor.h
@@ -93,8 +93,10 @@ public:
virtual void UnregisterSumo(KX_TouchEventManager* touchman);
virtual void UnregisterToManager();
-// virtual DT_Bool HandleCollision(void* obj1,void* obj2,
-// const DT_CollData * coll_data);
+#if 0
+ virtual DT_Bool HandleCollision(void* obj1,void* obj2,
+ const DT_CollData * coll_data);
+#endif
virtual bool NewHandleCollision(void*obj1,void*obj2,const PHY_CollData* colldata);
diff --git a/source/gameengine/VideoTexture/ImageBase.cpp b/source/gameengine/VideoTexture/ImageBase.cpp
index b1d77d8807f..ac92bcc6d41 100644
--- a/source/gameengine/VideoTexture/ImageBase.cpp
+++ b/source/gameengine/VideoTexture/ImageBase.cpp
@@ -444,9 +444,9 @@ PyObject * Image_getImage (PyImage * self, char * mode)
// get an empty buffer
buffer = BGL_MakeBuffer( GL_BYTE, 1, &dimensions, NULL);
// and fill it
- for (i=0, d=(unsigned char*)buffer->buf.asbyte, s=(unsigned char*)image;
- i<pixels;
- ++i, d+=ncolor, s+=4)
+ for (i = 0, d = (unsigned char *)buffer->buf.asbyte, s = (unsigned char *)image;
+ i < pixels;
+ i++, d += ncolor, s += 4)
{
for (c=0; c<ncolor; c++)
{