fix for uninitialized value use in newly added fcurve normalized view.

also quiet warning without openmp.
This commit is contained in:
Campbell Barton 2013-10-30 22:13:28 +00:00
parent 1a746911d6
commit bced18155f
2 changed files with 4 additions and 2 deletions

@ -377,7 +377,7 @@ short ANIM_get_normalization_flags(bAnimContext *ac)
static float normalzation_factor_get(FCurve *fcu, short flag) static float normalzation_factor_get(FCurve *fcu, short flag)
{ {
float factor; float factor = 1.0f;
if (flag & ANIM_UNITCONV_RESTORE) { if (flag & ANIM_UNITCONV_RESTORE) {
return 1.0f / fcu->prev_norm_factor; return 1.0f / fcu->prev_norm_factor;

@ -165,7 +165,9 @@ static int is_effected(float planes[4][4], const float co[3])
int do_sculpt_mask_box_select(ViewContext *vc, rcti *rect, bool select, bool UNUSED(extend)) int do_sculpt_mask_box_select(ViewContext *vc, rcti *rect, bool select, bool UNUSED(extend))
{ {
#ifdef _OPENMP
Sculpt *sd = vc->scene->toolsettings->sculpt; Sculpt *sd = vc->scene->toolsettings->sculpt;
#endif
BoundBox bb; BoundBox bb;
bglMats mats = {{0}}; bglMats mats = {{0}};
float clip_planes[4][4]; float clip_planes[4][4];
@ -198,7 +200,7 @@ int do_sculpt_mask_box_select(ViewContext *vc, rcti *rect, bool select, bool UNU
sculpt_undo_push_begin("Mask box fill"); sculpt_undo_push_begin("Mask box fill");
#pragma omp parallel for schedule(guided) if (sd->flags & SCULPT_USE_OPENMP) #pragma omp parallel for schedule(guided) if (sd->flags & SCULPT_USE_OPENMP)
for (i = 0; i < totnode; i++) { for (i = 0; i < totnode; i++) {
PBVHVertexIter vi; PBVHVertexIter vi;