Threaded object update and EvaluationContext
[blender.git] / source / blender / windowmanager / intern / wm_playanim.c
index 31b44915ad4572f23d4661f5a8ff26630d3622df..ab48e72562ecf7e85a19d7cd9f3875635c550f25 100644 (file)
@@ -13,7 +13,7 @@
  *
  * You should have received a copy of the GNU General Public License
  * along with this program; if not, write to the Free Software Foundation,
- * Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
+ * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
  *
  * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV.
  * All rights reserved.
@@ -896,17 +896,20 @@ static char *wm_main_playanim_intern(int argc, const char **argv)
                                        }
                                        break;
                                case 's':
-                                       sfra = MIN2(MAXFRAME, MAX2(1, atoi(argv[2]) ));
+                                       sfra = atoi(argv[2]);
+                                       CLAMP(sfra, 1, MAXFRAME);
                                        argc--;
                                        argv++;
                                        break;
                                case 'e':
-                                       efra = MIN2(MAXFRAME, MAX2(1, atoi(argv[2]) ));
+                                       efra = atoi(argv[2]);
+                                       CLAMP(efra, 1, MAXFRAME);
                                        argc--;
                                        argv++;
                                        break;
                                case 'j':
-                                       ps.fstep = MIN2(MAXFRAME, MAX2(1, atoi(argv[2])));
+                                       ps.fstep = atoi(argv[2]);
+                                       CLAMP(ps.fstep, 1, MAXFRAME);
                                        swaptime *= ps.fstep;
                                        argc--;
                                        argv++;
@@ -956,9 +959,9 @@ static char *wm_main_playanim_intern(int argc, const char **argv)
        }
 
 #if 0 //XXX25
-       #if !defined(WIN32) && !defined(__APPLE__)
+#if !defined(WIN32) && !defined(__APPLE__)
        if (fork()) exit(0);
-       #endif
+#endif
 #endif //XXX25
 
        {
@@ -1199,7 +1202,7 @@ static char *wm_main_playanim_intern(int argc, const char **argv)
        
        IMB_exit();
        BKE_images_exit();
-       DAG_threaded_exit();
+       DAG_exit();
 
        totblock = MEM_get_memory_blocks_in_use();
        if (totblock != 0) {