X-Git-Url: http://git.cinelerra-gg.org/git/?a=blobdiff_plain;f=cinelerra-5.1%2Fplugins%2Ftimeavg%2Ftimeavg.C;h=0de40c2d62dcab72859961e0deb2cab501c09990;hb=af44bff549c39ac8bb6e42a791e7a211e1013526;hp=1929a1400ad36056d876697898968f3028888390;hpb=21c2e6b36d6a96c2f662a89459d607b5a387f4eb;p=goodguy%2Fhistory.git diff --git a/cinelerra-5.1/plugins/timeavg/timeavg.C b/cinelerra-5.1/plugins/timeavg/timeavg.C index 1929a140..0de40c2d 100644 --- a/cinelerra-5.1/plugins/timeavg/timeavg.C +++ b/cinelerra-5.1/plugins/timeavg/timeavg.C @@ -19,12 +19,13 @@ * */ -#include "clip.h" +#include "bccolors.h" #include "bchash.h" +#include "clip.h" #include "filexml.h" #include "keyframe.h" #include "language.h" -#include "cicolors.h" +#include "bccolors.h" #include "timeavg.h" #include "timeavgwindow.h" #include "transportque.h" @@ -214,7 +215,7 @@ int TimeAvgMain::process_buffer(VFrame *frame, // Create new frames for( ; i < config.frames; i++) { - history2[i] = new VFrame(w, h, color_model); + history2[i] = new VFrame(w, h, color_model, 0); history_frame2[i] = -0x7fffffff; history_valid2[i] = 0; } @@ -231,7 +232,7 @@ int TimeAvgMain::process_buffer(VFrame *frame, { history = new VFrame*[config.frames]; for(int i = 0; i < config.frames; i++) - history[i] = new VFrame(w, h, color_model); + history[i] = new VFrame(w, h, color_model, 0); history_size = config.frames; history_frame = new int64_t[config.frames]; bzero(history_frame, sizeof(int64_t) * config.frames); @@ -498,8 +499,7 @@ void TimeAvgMain::reset_accum(int w, int h, int color_model) } } -#define RGB_TO_VALUE(r, g, b) \ -((r) * R_TO_Y + (g) * G_TO_Y + (b) * B_TO_Y) +#define RGB_TO_VALUE(r, g, b) YUV::yuv.rgb_to_y_f((r),(g),(b)) // Only AVERAGE and ACCUMULATE use this #define SUBTRACT_ACCUM(type, \