Cleanup: code-style, duplicate header
This commit is contained in:
@@ -755,7 +755,6 @@ static void where_is_temp(char *fullname, char *basename, const size_t maxlen, c
|
||||
void BKE_tempdir_init(char *userdir)
|
||||
{
|
||||
where_is_temp(btempdir_session, btempdir_base, FILE_MAX, userdir);
|
||||
;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -1167,7 +1167,8 @@ static void stabilization_calculate_data(StabContext *ctx,
|
||||
|
||||
if (ctx->stab->flag & TRACKING_STABILIZE_SCALE) {
|
||||
*r_scale = expf(scale_step * scaleinf); /* Averaged in log scale */
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
*r_scale = 1.0f;
|
||||
}
|
||||
|
||||
@@ -1180,8 +1181,8 @@ static void stabilization_calculate_data(StabContext *ctx,
|
||||
*/
|
||||
get_animated_target_pos(ctx, framenr, target_pos);
|
||||
sub_v2_v2(r_translation, target_pos);
|
||||
*r_angle -= get_animated_target_rot(ctx,framenr);
|
||||
target_scale = get_animated_target_scale(ctx,framenr);
|
||||
*r_angle -= get_animated_target_rot(ctx, framenr);
|
||||
target_scale = get_animated_target_scale(ctx, framenr);
|
||||
if (target_scale != 0.0f) {
|
||||
*r_scale /= target_scale;
|
||||
/* target_scale is an expected/intended reference zoom value */
|
||||
|
||||
@@ -3856,7 +3856,8 @@ void ANIM_channel_draw(bAnimContext *ac, bAnimListElem *ale, float yminc, float
|
||||
if (ac->sl) {
|
||||
if ((ac->spacetype == SPACE_IPO) &&
|
||||
(acf->has_setting(ac, ale, ACHANNEL_SETTING_VISIBLE) ||
|
||||
acf->has_setting(ac, ale, ACHANNEL_SETTING_ALWAYS_VISIBLE))) {
|
||||
acf->has_setting(ac, ale, ACHANNEL_SETTING_ALWAYS_VISIBLE)))
|
||||
{
|
||||
/* for F-Curves, draw color-preview of curve behind checkbox */
|
||||
if (ELEM(ale->type, ANIMTYPE_FCURVE, ANIMTYPE_NLACURVE)) {
|
||||
FCurve *fcu = (FCurve *)ale->data;
|
||||
|
||||
@@ -362,7 +362,7 @@ static int armature_flip_names_exec(bContext *C, wmOperator *UNUSED(op))
|
||||
|
||||
arm = ob->data;
|
||||
|
||||
ListBase bones_names= {NULL};
|
||||
ListBase bones_names = {NULL};
|
||||
|
||||
CTX_DATA_BEGIN(C, EditBone *, ebone, selected_editable_bones)
|
||||
{
|
||||
|
||||
@@ -74,7 +74,6 @@
|
||||
#include "ED_object.h"
|
||||
#include "ED_screen.h"
|
||||
#include "ED_view3d.h"
|
||||
#include "ED_screen.h"
|
||||
#include "ED_space_api.h"
|
||||
|
||||
#include "gpencil_intern.h"
|
||||
|
||||
@@ -315,7 +315,7 @@ static void screen_opengl_render_doit(OGLRender *oglrender, RenderResult *rr)
|
||||
RE_render_result_rect_from_ibuf(rr, &scene->r, out, oglrender->view_id);
|
||||
IMB_freeImBuf(out);
|
||||
}
|
||||
else if (gpd){
|
||||
else if (gpd) {
|
||||
/* If there are no strips, Grease Pencil still needs a buffer to draw on */
|
||||
ImBuf *out = IMB_allocImBuf(oglrender->sizex, oglrender->sizey, 32, IB_rect);
|
||||
RE_render_result_rect_from_ibuf(rr, &scene->r, out, oglrender->view_id);
|
||||
|
||||
@@ -1534,7 +1534,8 @@ static int join_tracks_exec(bContext *C, wmOperator *op)
|
||||
update_stabilization = true;
|
||||
if ((act_track->flag & TRACK_USE_2D_STAB) == 0) {
|
||||
act_track->flag |= TRACK_USE_2D_STAB;
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
stab->tot_track--;
|
||||
}
|
||||
BLI_assert(0 <= stab->tot_track);
|
||||
@@ -1543,7 +1544,8 @@ static int join_tracks_exec(bContext *C, wmOperator *op)
|
||||
update_stabilization = true;
|
||||
if ((act_track->flag & TRACK_USE_2D_STAB_ROT) == 0) {
|
||||
act_track->flag |= TRACK_USE_2D_STAB_ROT;
|
||||
} else {
|
||||
}
|
||||
else {
|
||||
stab->tot_rot_track--;
|
||||
}
|
||||
BLI_assert(0 <= stab->tot_rot_track);
|
||||
|
||||
@@ -545,7 +545,8 @@ static void draw_seq_text(View2D *v2d, SpaceSeq *sseq, Sequence *seq, float x1,
|
||||
if ((sseq->flag & SEQ_ALL_WAVEFORMS) || (seq->flag & SEQ_AUDIO_DRAW_WAVEFORM)) {
|
||||
str[0] = 0;
|
||||
str_len = 0;
|
||||
} else if (seq->sound) {
|
||||
}
|
||||
else if (seq->sound) {
|
||||
str_len = BLI_snprintf(str, sizeof(str), "%s: %s | %d",
|
||||
name, seq->sound->name, seq->len);
|
||||
}
|
||||
|
||||
@@ -774,8 +774,8 @@ void draw_smoke_velocity(SmokeDomainSettings *domain, float viewnormal[3])
|
||||
|
||||
float min[3] = {
|
||||
domain->p0[0] - domain->cell_size[0] * domain->adapt_res,
|
||||
domain->p0[1] - domain->cell_size[1] * domain->adapt_res,
|
||||
domain->p0[2] - domain->cell_size[2] * domain->adapt_res,
|
||||
domain->p0[1] - domain->cell_size[1] * domain->adapt_res,
|
||||
domain->p0[2] - domain->cell_size[2] * domain->adapt_res,
|
||||
};
|
||||
|
||||
int num_points_v[3] = {
|
||||
|
||||
@@ -3157,8 +3157,9 @@ int rna_parameter_size(PropertyRNA *parm)
|
||||
StringPropertyRNA *sparm = (StringPropertyRNA *)parm;
|
||||
return sizeof(char) * sparm->maxlength;
|
||||
}
|
||||
else
|
||||
else {
|
||||
return sizeof(char *);
|
||||
}
|
||||
case PROP_POINTER:
|
||||
{
|
||||
#ifdef RNA_RUNTIME
|
||||
|
||||
@@ -832,14 +832,14 @@ static void rna_def_smoke_domain_settings(BlenderRNA *brna)
|
||||
{FLUID_FIELD_COLOR_R, "COLOR_R", 0, "Red", "Red component of the color field"},
|
||||
{FLUID_FIELD_COLOR_G, "COLOR_G", 0, "Green", "Green component of the color field"},
|
||||
{FLUID_FIELD_COLOR_B, "COLOR_B", 0, "Blue", "Blue component of the color field"},
|
||||
{FLUID_FIELD_DENSITY, "DENSITY", 0, "Density", "Quantity of soot in the fluid"},
|
||||
{FLUID_FIELD_DENSITY, "DENSITY", 0, "Density", "Quantity of soot in the fluid"},
|
||||
{FLUID_FIELD_FLAME, "FLAME", 0, "Flame", "Flame field"},
|
||||
{FLUID_FIELD_FUEL, "FUEL", 0, "Fuel", "Fuel field"},
|
||||
{FLUID_FIELD_HEAT, "HEAT", 0, "Heat", "Temperature of the fluid"},
|
||||
{FLUID_FIELD_VELOCITY_X, "VELOCITY_X", 0, "X Velocity", "X component of the velocity field"},
|
||||
{FLUID_FIELD_VELOCITY_Y, "VELOCITY_Y", 0, "Y Velocity", "Y component of the velocity field"},
|
||||
{FLUID_FIELD_VELOCITY_Z, "VELOCITY_Z", 0, "Z Velocity", "Z component of the velocity field"},
|
||||
{0, NULL, 0, NULL, NULL}
|
||||
{0, NULL, 0, NULL, NULL}
|
||||
};
|
||||
|
||||
prop = RNA_def_property(srna, "coba_field", PROP_ENUM, PROP_NONE);
|
||||
|
||||
@@ -116,7 +116,7 @@ static DerivedMesh *applyModifier(ModifierData *md, Object *ob,
|
||||
|
||||
static bool is_brush_cb(Object *UNUSED(ob), ModifierData *pmd)
|
||||
{
|
||||
return ((DynamicPaintModifierData*)pmd)->brush != NULL;
|
||||
return ((DynamicPaintModifierData *)pmd)->brush != NULL;
|
||||
}
|
||||
|
||||
static void updateDepgraph(ModifierData *md, DagForest *forest,
|
||||
|
||||
@@ -64,10 +64,11 @@ static void node_shader_exec_fresnel(void *data, int UNUSED(thread), bNode *UNUS
|
||||
copy_v3_v3(n, shi->vn);
|
||||
}
|
||||
|
||||
if(shi->use_world_space_shading)
|
||||
if (shi->use_world_space_shading) {
|
||||
mul_mat3_m4_v3((float (*)[4])RE_render_current_get_matrix(RE_VIEW_MATRIX), n);
|
||||
}
|
||||
|
||||
out[0]->vec[0] = RE_fresnel_dielectric(shi->view, n, shi->flippednor ? 1/eta : eta);
|
||||
out[0]->vec[0] = RE_fresnel_dielectric(shi->view, n, shi->flippednor ? 1 / eta : eta);
|
||||
}
|
||||
|
||||
/* node type definition */
|
||||
|
||||
@@ -69,7 +69,7 @@ static void node_shader_exec_layer_weight(void *data, int UNUSED(thread), bNode
|
||||
if (shi->use_world_space_shading)
|
||||
mul_mat3_m4_v3((float (*)[4])RE_render_current_get_matrix(RE_VIEW_MATRIX), n);
|
||||
|
||||
out[0]->vec[0] = RE_fresnel_dielectric(shi->view, n, shi->flippednor ? eta : 1/eta);
|
||||
out[0]->vec[0] = RE_fresnel_dielectric(shi->view, n, shi->flippednor ? eta : 1 / eta);
|
||||
|
||||
float facing = fabs(dot_v3v3(shi->view, n));
|
||||
if (blend != 0.5) {
|
||||
|
||||
@@ -64,7 +64,7 @@ static void node_shader_init_tex_brick(bNodeTree *UNUSED(ntree), bNode *node)
|
||||
|
||||
for (bNodeSocket *sock = node->inputs.first; sock; sock = sock->next) {
|
||||
if (STREQ(sock->name, "Mortar Smooth")) {
|
||||
((bNodeSocketValueFloat*)sock->default_value)->value = 0.1f;
|
||||
((bNodeSocketValueFloat *)sock->default_value)->value = 0.1f;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user