Cleanup: style
This commit is contained in:
@@ -112,7 +112,7 @@ static void md5_init_ctx(struct md5_ctx *ctx)
|
|||||||
* the 'ctx' context for the next 'len' bytes starting at 'buffer'.
|
* the 'ctx' context for the next 'len' bytes starting at 'buffer'.
|
||||||
* It is necessary that 'len' is a multiple of 64!!!
|
* It is necessary that 'len' is a multiple of 64!!!
|
||||||
*/
|
*/
|
||||||
static void md5_process_block (const void *buffer, size_t len, struct md5_ctx *ctx)
|
static void md5_process_block(const void *buffer, size_t len, struct md5_ctx *ctx)
|
||||||
{
|
{
|
||||||
/* These are the four functions used in the four steps of the MD5 algorithm and defined in the RFC 1321.
|
/* These are the four functions used in the four steps of the MD5 algorithm and defined in the RFC 1321.
|
||||||
* The first function is a little bit optimized (as found in Colin Plumbs public domain implementation).
|
* The first function is a little bit optimized (as found in Colin Plumbs public domain implementation).
|
||||||
|
|||||||
@@ -1259,7 +1259,7 @@ void blo_freefiledata(FileData *fd)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (fd->strm.next_in) {
|
if (fd->strm.next_in) {
|
||||||
if (inflateEnd (&fd->strm) != Z_OK) {
|
if (inflateEnd(&fd->strm) != Z_OK) {
|
||||||
printf("close gzip stream error\n");
|
printf("close gzip stream error\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -3971,7 +3971,7 @@ static void direct_link_pointcache_cb(FileData *fd, void *data)
|
|||||||
|
|
||||||
/* the cache saves non-struct data without DNA */
|
/* the cache saves non-struct data without DNA */
|
||||||
if (pm->data[i] && ptcache_data_struct[i][0]=='\0' && (fd->flags & FD_FLAGS_SWITCH_ENDIAN)) {
|
if (pm->data[i] && ptcache_data_struct[i][0]=='\0' && (fd->flags & FD_FLAGS_SWITCH_ENDIAN)) {
|
||||||
int tot = (BKE_ptcache_data_size (i) * pm->totpoint) / sizeof(int); /* data_size returns bytes */
|
int tot = (BKE_ptcache_data_size(i) * pm->totpoint) / sizeof(int); /* data_size returns bytes */
|
||||||
int *poin = pm->data[i];
|
int *poin = pm->data[i];
|
||||||
|
|
||||||
BLI_endian_switch_int32_array(poin, tot);
|
BLI_endian_switch_int32_array(poin, tot);
|
||||||
|
|||||||
@@ -2427,19 +2427,19 @@ static void write_scenes(WriteData *wd, ListBase *scebase)
|
|||||||
writestruct(wd, DATA, "ToolSettings", 1, tos);
|
writestruct(wd, DATA, "ToolSettings", 1, tos);
|
||||||
if (tos->vpaint) {
|
if (tos->vpaint) {
|
||||||
writestruct(wd, DATA, "VPaint", 1, tos->vpaint);
|
writestruct(wd, DATA, "VPaint", 1, tos->vpaint);
|
||||||
write_paint (wd, &tos->vpaint->paint);
|
write_paint(wd, &tos->vpaint->paint);
|
||||||
}
|
}
|
||||||
if (tos->wpaint) {
|
if (tos->wpaint) {
|
||||||
writestruct(wd, DATA, "VPaint", 1, tos->wpaint);
|
writestruct(wd, DATA, "VPaint", 1, tos->wpaint);
|
||||||
write_paint (wd, &tos->wpaint->paint);
|
write_paint(wd, &tos->wpaint->paint);
|
||||||
}
|
}
|
||||||
if (tos->sculpt) {
|
if (tos->sculpt) {
|
||||||
writestruct(wd, DATA, "Sculpt", 1, tos->sculpt);
|
writestruct(wd, DATA, "Sculpt", 1, tos->sculpt);
|
||||||
write_paint (wd, &tos->sculpt->paint);
|
write_paint(wd, &tos->sculpt->paint);
|
||||||
}
|
}
|
||||||
if (tos->uvsculpt) {
|
if (tos->uvsculpt) {
|
||||||
writestruct(wd, DATA, "UvSculpt", 1, tos->uvsculpt);
|
writestruct(wd, DATA, "UvSculpt", 1, tos->uvsculpt);
|
||||||
write_paint (wd, &tos->uvsculpt->paint);
|
write_paint(wd, &tos->uvsculpt->paint);
|
||||||
}
|
}
|
||||||
|
|
||||||
write_paint(wd, &tos->imapaint.paint);
|
write_paint(wd, &tos->imapaint.paint);
|
||||||
|
|||||||
@@ -192,7 +192,7 @@ int getname_anim_fcurve(char *name, ID *id, FCurve *fcu)
|
|||||||
#define HSV_BANDWIDTH 0.3f
|
#define HSV_BANDWIDTH 0.3f
|
||||||
|
|
||||||
/* used to determine the color of F-Curves with FCURVE_COLOR_AUTO_RAINBOW set */
|
/* used to determine the color of F-Curves with FCURVE_COLOR_AUTO_RAINBOW set */
|
||||||
//void fcurve_rainbow (unsigned int cur, unsigned int tot, float *out)
|
// void fcurve_rainbow(unsigned int cur, unsigned int tot, float *out)
|
||||||
void getcolor_fcurve_rainbow(int cur, int tot, float out[3])
|
void getcolor_fcurve_rainbow(int cur, int tot, float out[3])
|
||||||
{
|
{
|
||||||
float hsv[3], fac;
|
float hsv[3], fac;
|
||||||
|
|||||||
@@ -1634,7 +1634,7 @@ static int select_random_exec(bContext *C, wmOperator *op)
|
|||||||
int p;
|
int p;
|
||||||
int k;
|
int k;
|
||||||
|
|
||||||
const float randfac = RNA_float_get (op->ptr, "percent") / 100.0f;
|
const float randfac = RNA_float_get(op->ptr, "percent") / 100.0f;
|
||||||
const int seed = WM_operator_properties_select_random_seed_increment_get(op);
|
const int seed = WM_operator_properties_select_random_seed_increment_get(op);
|
||||||
const bool select = (RNA_enum_get(op->ptr, "action") == SEL_SELECT);
|
const bool select = (RNA_enum_get(op->ptr, "action") == SEL_SELECT);
|
||||||
RNG *rng;
|
RNG *rng;
|
||||||
|
|||||||
@@ -401,7 +401,7 @@ static void image_undo_end(void)
|
|||||||
UndoImageTile *tmp_tile = tile->next;
|
UndoImageTile *tmp_tile = tile->next;
|
||||||
deallocsize += allocsize * ((tile->use_float) ? sizeof(float) : sizeof(char));
|
deallocsize += allocsize * ((tile->use_float) ? sizeof(float) : sizeof(char));
|
||||||
MEM_freeN(tile->rect.pt);
|
MEM_freeN(tile->rect.pt);
|
||||||
BLI_freelinkN (lb, tile);
|
BLI_freelinkN(lb, tile);
|
||||||
tile = tmp_tile;
|
tile = tmp_tile;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|||||||
@@ -3717,7 +3717,7 @@ static void project_paint_prepare_all_faces(
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* tfbase here should be non-null! */
|
/* tfbase here should be non-null! */
|
||||||
BLI_assert (mloopuv_base != NULL);
|
BLI_assert(mloopuv_base != NULL);
|
||||||
|
|
||||||
if (is_face_sel && tpage) {
|
if (is_face_sel && tpage) {
|
||||||
ProjPaintFaceCoSS coSS;
|
ProjPaintFaceCoSS coSS;
|
||||||
|
|||||||
@@ -1158,7 +1158,7 @@ int paint_stroke_modal(bContext *C, wmOperator *op, const wmEvent *event)
|
|||||||
if (event->val == KM_RELEASE) {
|
if (event->val == KM_RELEASE) {
|
||||||
copy_v2_fl2(mouse, event->mval[0], event->mval[1]);
|
copy_v2_fl2(mouse, event->mval[0], event->mval[1]);
|
||||||
paint_stroke_line_constrain(stroke, mouse);
|
paint_stroke_line_constrain(stroke, mouse);
|
||||||
paint_stroke_line_end (C, op, stroke, mouse);
|
paint_stroke_line_end(C, op, stroke, mouse);
|
||||||
stroke_done(C, op);
|
stroke_done(C, op);
|
||||||
return OPERATOR_FINISHED;
|
return OPERATOR_FINISHED;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7607,7 +7607,7 @@ static void createTransPaintCurveVerts(bContext *C, TransInfo *t)
|
|||||||
|
|
||||||
for (pcp = pc->points, i = 0; i < pc->tot_points; i++, pcp++) {
|
for (pcp = pc->points, i = 0; i < pc->tot_points; i++, pcp++) {
|
||||||
if (PC_IS_ANY_SEL(pcp)) {
|
if (PC_IS_ANY_SEL(pcp)) {
|
||||||
PaintCurvePointToTransData (pcp, td, td2d, tdpc);
|
PaintCurvePointToTransData(pcp, td, td2d, tdpc);
|
||||||
|
|
||||||
if (pcp->bez.f2 & SELECT) {
|
if (pcp->bez.f2 & SELECT) {
|
||||||
td += 3;
|
td += 3;
|
||||||
|
|||||||
@@ -230,7 +230,7 @@ GPU_PBVH_Buffers *GPU_build_mesh_pbvh_buffers(
|
|||||||
const int face_indices_len);
|
const int face_indices_len);
|
||||||
|
|
||||||
GPU_PBVH_Buffers *GPU_build_grid_pbvh_buffers(
|
GPU_PBVH_Buffers *GPU_build_grid_pbvh_buffers(
|
||||||
int *grid_indices, int totgrid,unsigned int **grid_hidden, int gridsize, const struct CCGKey *key,
|
int *grid_indices, int totgrid, unsigned int **grid_hidden, int gridsize, const struct CCGKey *key,
|
||||||
struct GridCommonGPUBuffer **grid_common_gpu_buffer);
|
struct GridCommonGPUBuffer **grid_common_gpu_buffer);
|
||||||
|
|
||||||
GPU_PBVH_Buffers *GPU_build_bmesh_pbvh_buffers(bool smooth_shading);
|
GPU_PBVH_Buffers *GPU_build_bmesh_pbvh_buffers(bool smooth_shading);
|
||||||
|
|||||||
@@ -127,7 +127,7 @@ class Mem_IStream : public Imf::IStream
|
|||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
Mem_IStream (unsigned char *exrbuf, size_t exrsize) :
|
Mem_IStream(unsigned char *exrbuf, size_t exrsize) :
|
||||||
IStream("dummy"), _exrpos(0), _exrsize(exrsize)
|
IStream("dummy"), _exrpos(0), _exrsize(exrsize)
|
||||||
{
|
{
|
||||||
_exrbuf = exrbuf;
|
_exrbuf = exrbuf;
|
||||||
|
|||||||
Reference in New Issue
Block a user