Merging r42945 through r43024 from trunk into soc-2011-tomato
authorSergey Sharybin <sergey.vfx@gmail.com>
Sat, 31 Dec 2011 09:23:06 +0000 (09:23 +0000)
committerSergey Sharybin <sergey.vfx@gmail.com>
Sat, 31 Dec 2011 09:23:06 +0000 (09:23 +0000)
1  2 
source/blender/blenkernel/intern/tracking.c

index b75a9ff0037f0beae0b76d31256606273fcb4b4a,5ef0491c03cd2a6a9b9a3f570a8023642c6f5e70..863080f80c5ffccf4bb43558c136dcc465e67e92
@@@ -1377,7 -1377,7 +1377,7 @@@ int BKE_tracking_next(MovieTrackingCont
                                MEM_freeN(image_new);
                        }
  
 -                      coords_correct= !onbound && !isnan(x2) && !isnan(y2) && finite(x2) && finite(y2);
 +                      coords_correct= !isnan(x2) && !isnan(y2) && finite(x2) && finite(y2);
                        if(coords_correct && !onbound && tracked) {
                                if(context->first_time) {
                                        #pragma omp critical
@@@ -1682,7 -1682,8 +1682,8 @@@ int BKE_tracking_can_reconstruct(MovieT
        return 1;
  #else
        BLI_strncpy(error_msg, "Blender is compiled without motion tracking library", error_size);
-       (void) tracking;
+       (void)tracking;
+       (void)object;
  
        return 0;
  #endif
@@@ -1706,12 -1707,12 +1707,12 @@@ MovieReconstructContext* BKE_tracking_r
  
        track= tracksbase->first;
        while(track) {
-               int first= 0, last= track->markersnr;
+               int first= 0, last= track->markersnr-1;
                MovieTrackingMarker *first_marker= &track->markers[0];
                MovieTrackingMarker *last_marker= &track->markers[track->markersnr-1];
  
                /* find first not-disabled marker */
-               while(first<track->markersnr-1 && first_marker->flag&MARKER_DISABLED) {
+               while(first<=track->markersnr-1 && first_marker->flag&MARKER_DISABLED) {
                        first++;
                        first_marker++;
                }
@@@ -2274,6 -2275,7 +2275,7 @@@ void BKE_tracking_detect_fast(MovieTrac
        libmv_destroyFeatures(features);
  #else
        (void)tracking;
+       (void)tracksbase;
        (void)ibuf;
        (void)framenr;
        (void)margin;