fix for ntreeGPUMaterialNodes(), using uninitialized exec pointer.

also commented some set-but-unused variables.
This commit is contained in:
2011-09-12 00:00:21 +00:00
parent 8f9fa6a400
commit 2827ee26e5
5 changed files with 17 additions and 8 deletions

View File

@@ -5423,9 +5423,13 @@ static void doAnimEdit_SnapFrame(TransInfo *t, TransData *td, TransData2D *td2d,
{
/* snap key to nearest frame? */
if (autosnap == SACTSNAP_FRAME) {
#if 0 /* 'doTime' disabled for now */
const Scene *scene= t->scene;
const short doTime= 0; //getAnimEdit_DrawTime(t); // NOTE: this works, but may be confusing behaviour given the option's label, hence disabled
const double secf= FPS;
#endif
double val;
/* convert frame to nla-action time (if needed) */
@@ -5434,11 +5438,17 @@ static void doAnimEdit_SnapFrame(TransInfo *t, TransData *td, TransData2D *td2d,
else
val= *(td->val);
#if 0 /* 'doTime' disabled for now */
/* do the snapping to nearest frame/second */
if (doTime)
if (doTime) {
val= (float)( floor((val/secf) + 0.5f) * secf );
}
else
#endif
{
val= (float)( floor(val+0.5f) );
}
/* convert frame out of nla-action time */
if (adt)