upgrades to scopewindow, add blurbox, bd.sh sed tab test, tweak clk2play over window...
authorGood Guy <good1.2guy@gmail.com>
Sun, 29 Mar 2020 23:44:55 +0000 (17:44 -0600)
committerGood Guy <good1.2guy@gmail.com>
Sun, 29 Mar 2020 23:44:55 +0000 (17:44 -0600)
19 files changed:
cinelerra-5.1/cinelerra/bdcreate.C
cinelerra-5.1/cinelerra/cwindowgui.C
cinelerra-5.1/cinelerra/editpanel.C
cinelerra-5.1/cinelerra/editpanel.h
cinelerra-5.1/cinelerra/loadbalance.C
cinelerra-5.1/cinelerra/mainsession.C
cinelerra-5.1/cinelerra/mainsession.h
cinelerra-5.1/cinelerra/mwindow.C
cinelerra-5.1/cinelerra/mwindow.h
cinelerra-5.1/cinelerra/recordscopes.C
cinelerra-5.1/cinelerra/recordscopes.h
cinelerra-5.1/cinelerra/scopewindow.C
cinelerra-5.1/cinelerra/scopewindow.h
cinelerra-5.1/cinelerra/scopewindow.inc
cinelerra-5.1/cinelerra/theme.C
cinelerra-5.1/plugins/theme_cakewalk/cakewalk.C
cinelerra-5.1/plugins/theme_neophyte/neophyte.C
cinelerra-5.1/plugins/videoscope/videoscope.C
cinelerra-5.1/po/es.po

index f02a5905aaf8885374d80f36f07611e897a02a24..f13642c856cbcecd4cd6c08f41f81787221dfcfc 100644 (file)
@@ -172,7 +172,7 @@ char *BD_BatchRenderJob::create_script(EDL *edl, ArrayList<Indexable *> *idxbls)
        fprintf(fp,"dir=`cd \"$sdir\"; pwd`\n");
        fprintf(fp,"PATH=$PATH:%s\n",exec_path);
        fprintf(fp,"mkdir -p $dir/udfs\n");
-       fprintf(fp,"sz=`du -cb $dir/bd.m2ts* | tail -1 | sed -e 's/[ \t].*//'`\n");
+       fprintf(fp,"sz=`du -cb $dir/bd.m2ts* | tail -1 | sed -e 's/[    ].*//'`\n");
        fprintf(fp,"blks=$((sz/2048 + 4096))\n");
        fprintf(fp,"rm -f %s\n", udfs);
        fprintf(fp,"mkudffs -b 2048 %s $blks\n", udfs);
index 3a6c2db8e9f96de906a5216f45ee8704821b4313..beac0f8184b22e87b9538b2781b7573a56c03a44 100644 (file)
@@ -281,7 +281,7 @@ int CWindowGUI::button_press_event()
        if( current_operation == CWINDOW_NONE &&
            mwindow->edl != 0 && canvas->get_canvas() &&
            mwindow->edl->session->cwindow_click2play &&
-           canvas->get_canvas()->get_cursor_over_window() ) {
+           canvas->get_canvas()->cursor_above() ) {
                switch( get_buttonpress() ) {
                case LEFT_BUTTON:
                        if( !cwindow->playback_engine->is_playing_back ) {
@@ -744,7 +744,7 @@ CWindowEditing::CWindowEditing(MWindow *mwindow, CWindow *cwindow)
                mwindow->theme->cedit_x, mwindow->theme->cedit_y,
                mwindow->edl->session->editing_mode,
                0, // use_editing_mode
-               1, // use_keyframe
+               0, // use_keyframe
                0, // use_splice
                0, // use_overwrite
                1, // use_copy
index 7eca7192a496b21df673ba28cd776f4908a22982..6488be94564e9334529dd4e365307f4977e58278 100644 (file)
@@ -171,19 +171,16 @@ void EditPanel::update()
 
 int EditPanel::calculate_w(MWindow *mwindow, int use_keyframe, int total_buttons)
 {
-       int result = 0;
-       int button_w = mwindow->theme->get_image_set("ibeam")[0]->get_w();
-       if( use_keyframe ) {
+       int button_w = mwindow->theme->get_image_set("meters")[0]->get_w();
+       int result = button_w * total_buttons;
+       if( use_keyframe )
                result += 2*(button_w + mwindow->theme->toggle_margin);
-       }
-
-       result += button_w * total_buttons;
        return result;
 }
 
 int EditPanel::calculate_h(MWindow *mwindow)
 {
-       return mwindow->theme->get_image_set("ibeam")[0]->get_h();
+       return mwindow->theme->get_image_set("meters")[0]->get_h();
 }
 
 void EditPanel::create_buttons()
@@ -1167,6 +1164,10 @@ EditPanelScopeDialog::~EditPanelScopeDialog()
        delete gui_lock;
 }
 
+void EditPanelScopeDialog::handle_close_event(int result)
+{
+       scope_gui = 0;
+}
 void EditPanelScopeDialog::handle_done_event(int result)
 {
        gui_lock->lock("EditPanelScopeDialog::handle_done_event");
@@ -1202,7 +1203,7 @@ EditPanelScopeGUI::EditPanelScopeGUI(MWindow *mwindow, EditPanelScopeDialog *dia
  : ScopeGUI(mwindow->theme,
        mwindow->session->scope_x, mwindow->session->scope_y,
        mwindow->session->scope_w, mwindow->session->scope_h,
-       mwindow->preferences->processors)
+       mwindow->get_cpus())
 {
        this->mwindow = mwindow;
        this->dialog = dialog;
@@ -1220,6 +1221,9 @@ void EditPanelScopeGUI::create_objects()
        use_vector = session->use_vector;
        use_hist_parade = session->use_hist_parade;
        use_wave_parade = session->use_wave_parade;
+       use_wave_gain = session->use_wave_gain;
+       use_vect_gain = session->use_vect_gain;
+       use_smooth = session->use_smooth;
        ScopeGUI::create_objects();
 }
 
@@ -1231,6 +1235,9 @@ void EditPanelScopeGUI::toggle_event()
        session->use_vector = use_vector;
        session->use_hist_parade = use_hist_parade;
        session->use_wave_parade = use_wave_parade;
+       session->use_wave_gain = use_wave_gain;
+       session->use_vect_gain = use_vect_gain;
+       session->use_smooth = use_smooth;
 }
 
 int EditPanelScopeGUI::translation_event()
index c5064dd0e9a9ded4abca01e6a5534917bccefd5b..b81d9fed0d385d4e654d424435fec4e7407cb313 100644 (file)
@@ -367,6 +367,7 @@ public:
        EditPanelScopeDialog(MWindow *mwindow, EditPanel *panel);
        ~EditPanelScopeDialog();
 
+       void handle_close_event(int result);
        void handle_done_event(int result);
        BC_Window* new_gui();
        void process(VFrame *output_frame);
index 7ea93415eab042e08c7dfd0a372c49ec7070f544..cbfdc29dd9c61180d721ba63a5fc8ec9e4609a17 100644 (file)
@@ -228,7 +228,7 @@ LoadPackage* LoadServer::get_package(int number)
 
 LoadClient* LoadServer::get_client(int number)
 {
-       return clients[number];
+       return is_single ? single_client : clients[number];
 }
 
 int LoadServer::get_total_packages()
index a21297e0df7fa633bca7e129aafa68a0901d0050..66978fef4c32c355044270f6c66921d24cc8b0f0 100644 (file)
@@ -106,6 +106,9 @@ MainSession::MainSession(MWindow *mwindow)
        use_vector = 0;
        use_hist_parade = 0;
        use_wave_parade = 0;
+       use_wave_gain = 5;
+       use_vect_gain = 5;
+       use_smooth = 0;
        afolders_w = 0;
        show_vwindow = show_awindow = show_cwindow = show_gwindow = show_lwindow = 0;
        plugindialog_w = plugindialog_h = 0;
@@ -321,6 +324,9 @@ void MainSession::default_window_positions(int window_config)
        use_vector = 1;
        use_hist_parade = 1;
        use_wave_parade = 1;
+       use_wave_gain = 5;
+       use_vect_gain = 5;
+       use_smooth = 1;
 
        if(mwindow->edl)
                lwindow_w = MeterPanel::get_meters_width(mwindow->theme,
@@ -435,6 +441,9 @@ int MainSession::load_defaults(BC_Hash *defaults)
        use_vector = defaults->get("USE_VECTOR", use_vector);
        use_hist_parade = defaults->get("USE_HIST_PARADE", use_hist_parade);
        use_wave_parade = defaults->get("USE_WAVE_PARADE", use_wave_parade);
+       use_wave_gain = defaults->get("USE_WAVE_GAIN", use_wave_gain);
+       use_vect_gain = defaults->get("USE_VECT_GAIN", use_vect_gain);
+       use_smooth = defaults->get("USE_SMOOTH", use_smooth);
 
 //printf("MainSession::load_defaults 1\n");
 
@@ -560,6 +569,9 @@ int MainSession::save_defaults(BC_Hash *defaults)
        defaults->update("USE_VECTOR", use_vector);
        defaults->update("USE_HIST_PARADE", use_hist_parade);
        defaults->update("USE_WAVE_PARADE", use_wave_parade);
+       defaults->update("USE_WAVE_GAIN", use_wave_gain);
+       defaults->update("USE_VECT_GAIN", use_vect_gain);
+       defaults->update("USE_SMOOTH", use_smooth);
 
        defaults->update("ABINS_W", afolders_w);
 
index 6395b809cc3b00e0feb0b579b9bdad386265d260..2757f7e0421c076e8851c87aeacd8cdbdc0e74dd 100644 (file)
@@ -172,6 +172,9 @@ public:
        int use_vector;
        int use_hist_parade;
        int use_wave_parade;
+       int use_wave_gain;
+       int use_vect_gain;
+       int use_smooth;
 
        int afolders_w;
        int show_vwindow, show_awindow, show_cwindow, show_gwindow, show_lwindow;
index 86e15ad796aeb7d994ec9e1f996f36a40c15311c..93e0a457aba68912903ef05b7d5fe21e10700cc1 100644 (file)
@@ -5085,3 +5085,13 @@ PatchGUI *MWindow::get_patchgui(Track *track)
         return patchgui;
 }
 
+int MWindow::get_cpus()
+{
+       int out_w = edl->session->output_w;
+       int out_h = edl->session->output_h;
+       int cpus = out_w*out_h/0x80000 + 1;
+       if( cpus > preferences->processors )
+               cpus = preferences->processors;
+       return cpus;
+}
+
index eccc0a3bb8d5ba02aad953f6fea3b720f281b239..b04acea7300b5dc36acc8c7a1eda2adc8049428b 100644 (file)
@@ -797,6 +797,7 @@ public:
        void speed_before();
        int speed_after(int done);
        int normalize_speed(EDL *old_edl, EDL *new_edl);
+       int get_cpus();
 //
        void clean_indexes();
 //     TimeBomb timebomb;
index 65f50b1e8ded9334e65e0d9872df8725e6c3c8cf..c7dfd53d30ff37d81a9335f62b5a5c4d67bd8c83 100644 (file)
@@ -45,6 +45,10 @@ RecordScopeThread::~RecordScopeThread()
        delete gui_lock;
 }
 
+void RecordScopeThread::handle_close_event(int result)
+{
+       scope_gui = 0;
+}
 void RecordScopeThread::handle_done_event(int result)
 {
        gui_lock->lock("RecordScopeThread::handle_done_event");
@@ -113,6 +117,9 @@ void RecordScopeGUI::create_objects()
        use_vector = mwindow->session->use_vector;
        use_hist_parade = mwindow->session->use_hist_parade;
        use_wave_parade = mwindow->session->use_wave_parade;
+       use_wave_gain = mwindow->session->use_wave_gain;
+       use_vect_gain = mwindow->session->use_vect_gain;
+       use_smooth = mwindow->session->use_smooth;
        ScopeGUI::create_objects();
 }
 
@@ -124,6 +131,9 @@ void RecordScopeGUI::toggle_event()
        mwindow->session->use_vector = use_vector;
        mwindow->session->use_hist_parade = use_hist_parade;
        mwindow->session->use_wave_parade = use_wave_parade;
+       mwindow->session->use_wave_gain = use_wave_gain;
+       mwindow->session->use_vect_gain = use_vect_gain;
+       mwindow->session->use_smooth = use_smooth;
 }
 
 int RecordScopeGUI::translation_event()
index b65c0883b66717dfe07d402dde14bdde6fc1dbb3..ac9f41bbc5a11aa2d3f366cb0cd42600220f620d 100644 (file)
@@ -38,6 +38,7 @@ public:
        RecordScopeThread(MWindow *mwindow, RecordMonitor *record_monitor);
        ~RecordScopeThread();
 
+       void handle_close_event(int result);
        void handle_done_event(int result);
        BC_Window* new_gui();
        void process(VFrame *output_frame);
index 36883b68d5da6355c0db01966913435a48838d5e..17bb811ca0eca906cd9399fb49cc382eae9e3702 100644 (file)
@@ -40,25 +40,25 @@ ScopeUnit::ScopeUnit(ScopeGUI *gui,
        this->gui = gui;
 }
 
-#define BPP 3
-#define incr_point(rows,h, n, comp) \
-if(iy >= 0 && iy < h) { int v; \
-  uint8_t *vp = rows[iy] + ix*BPP + (comp); \
-  v = *vp+(n);  *vp = v>0xff ? 0xff : v; \
-}
-#define incr_points(rows,h, rv, gv, bv) \
-if(iy >= 0 && iy < h) { int v; \
-  uint8_t *vp = rows[iy] + ix*BPP; \
-  v = *vp+(rv);  *vp++ = v>0xff ? 0xff : v; \
+
+#define incr_point(rows,h, iv,comp) { \
+if(iy >= 0 && iy < h) { \
+  uint8_t *vp = rows[iy] + ix*3 + (comp); \
+  int v = *vp+(iv);  *vp = v>0xff ? 0xff : v; } \
+}
+#define incr_points(rows,h, rv,gv,bv) { \
+if(iy >= 0 && iy < h) { \
+  uint8_t *vp = rows[iy] + ix*3; \
+  int v = *vp+(rv);  *vp++ = v>0xff ? 0xff : v; \
   v = *vp+(gv);  *vp++ = v>0xff ? 0xff : v; \
-  v = *vp+(bv);  *vp   = v>0xff ? 0xff : v; \
+  v = *vp+(bv);  *vp = v>0xff ? 0xff : v; } \
 }
-#define clip_points(rows,h, rv, gv, bv) \
-if(iy >= 0 && iy < h) { int v; \
-  uint8_t *vp = rows[iy] + ix*BPP; \
-  v = *vp+(rv);  *vp++ = v>0xff ? 0xff : v<0 ? 0 : v; \
+#define clip_points(rows,h, rv,gv,bv) { \
+if(iy >= 0 && iy < h) { \
+  uint8_t *vp = rows[iy] + ix*3; \
+  int v = *vp+(rv);  *vp++ = v>0xff ? 0xff : v<0 ? 0 : v; \
   v = *vp+(gv);  *vp++ = v>0xff ? 0xff : v<0 ? 0 : v; \
-  v = *vp+(bv);  *vp   = v>0xff ? 0xff : v<0 ? 0 : v; \
+  v = *vp+(bv);  *vp = v>0xff ? 0xff : v<0 ? 0 : v; } \
 }
 
 #define PROCESS_PIXEL(column) { \
@@ -81,37 +81,37 @@ if(iy >= 0 && iy < h) { int v; \
        } \
 /* Calculate waveform */ \
        if(use_wave || use_wave_parade) { \
-               int ix = (column) * wave_w / out_w; \
-               if(ix >= 0 && ix < wave_w) { \
+               int ix = column * wave_w / dat_w; \
+               if(ix >= 0 && ix < wave_w-1) { \
                        if(use_wave_parade > 0) { \
                                ix /= 3; \
-                               int iy = wave_h - (int)((r - FLOAT_MIN) /  \
+                               int iy = wave_h - ((r - FLOAT_MIN) /  \
                                                (FLOAT_MAX - FLOAT_MIN) * wave_h); \
-                               incr_point(waveform_rows,wave_h, winc, 0); \
+                               incr_point(waveform_rows,wave_h, winc,0); \
                                ix += wave_w/3; \
-                               iy = wave_h - (int)((g - FLOAT_MIN) /  \
+                               iy = wave_h - ((g - FLOAT_MIN) /  \
                                                (FLOAT_MAX - FLOAT_MIN) * wave_h); \
-                               incr_point(waveform_rows,wave_h, winc, 1); \
+                               incr_point(waveform_rows,wave_h, winc,1); \
                                ix += wave_w/3; \
-                               iy = wave_h - (int)((b - FLOAT_MIN) /  \
+                               iy = wave_h - ((b - FLOAT_MIN) /  \
                                                (FLOAT_MAX - FLOAT_MIN) * wave_h); \
-                               incr_point(waveform_rows,wave_h, winc, 2); \
+                               incr_point(waveform_rows,wave_h, winc,2); \
                        } \
                        else if(use_wave_parade < 0) { \
-                               int iy = wave_h - (int)((r - FLOAT_MIN) /  \
+                               int iy = wave_h - ((r - FLOAT_MIN) /  \
                                                (FLOAT_MAX - FLOAT_MIN) * wave_h); \
-                               clip_points(waveform_rows,wave_h, winc, -winc, -winc); \
-                               iy = wave_h - (int)((g - FLOAT_MIN) /  \
+                               clip_points(waveform_rows,wave_h, winc,-winc,-winc); \
+                               iy = wave_h - ((g - FLOAT_MIN) /  \
                                                (FLOAT_MAX - FLOAT_MIN) * wave_h); \
-                               clip_points(waveform_rows,wave_h, -winc, winc, -winc); \
-                               iy = wave_h - (int)((b - FLOAT_MIN) /  \
+                               clip_points(waveform_rows,wave_h, -winc,winc,-winc); \
+                               iy = wave_h - ((b - FLOAT_MIN) /  \
                                                (FLOAT_MAX - FLOAT_MIN) * wave_h); \
-                               clip_points(waveform_rows,wave_h, -winc, -winc, winc); \
+                               clip_points(waveform_rows,wave_h, -winc,-winc,winc); \
                        } \
-                       else { int yinc = 3*winc; \
-                               int rinc = yinc*(r-FLOAT_MIN) / (FLOAT_MAX-FLOAT_MIN) + 3; \
-                               int ginc = yinc*(g-FLOAT_MIN) / (FLOAT_MAX-FLOAT_MIN) + 3; \
-                               int binc = yinc*(b-FLOAT_MIN) / (FLOAT_MAX-FLOAT_MIN) + 3; \
+                       else { float yinc = 3*winc; \
+                               float rinc = yinc*(r-FLOAT_MIN) / (FLOAT_MAX-FLOAT_MIN) + 3; \
+                               float ginc = yinc*(g-FLOAT_MIN) / (FLOAT_MAX-FLOAT_MIN) + 3; \
+                               float binc = yinc*(b-FLOAT_MIN) / (FLOAT_MAX-FLOAT_MIN) + 3; \
                                int iy = wave_h - ((intensity - FLOAT_MIN) /  \
                                                (FLOAT_MAX - FLOAT_MIN) * wave_h); \
                                incr_points(waveform_rows,wave_h, rinc, ginc, binc); \
@@ -134,23 +134,25 @@ if(iy >= 0 && iy < h) { int v; \
                int rv = CLIP(r_f, 0, 1) * vinc + 3; \
                int gv = CLIP(g_f, 0, 1) * vinc + 3; \
                int bv = CLIP(b_f, 0, 1) * vinc + 3; \
-               incr_points(vector_rows,vector_h, rv, gv, bv); \
+               incr_points(vector_rows,vector_h, rv,gv,bv); \
        } \
 }
 
-#define PROCESS_RGB_PIXEL(column, max) { \
-       r = (float)*row++ / max; \
-       g = (float)*row++ / max; \
-       b = (float)*row++ / max; \
+#define PROCESS_RGB_PIXEL(type,max, column) { \
+       type *rp = (type *)row; \
+       r = (float)rp[0] / max; \
+       g = (float)rp[1] / max; \
+       b = (float)rp[2] / max; \
        HSV::rgb_to_hsv(r, g, b, h, s, v); \
        intensity = v; \
        PROCESS_PIXEL(column) \
 }
 
-#define PROCESS_BGR_PIXEL(column, max) { \
-       b = (float)*row++ / max; \
-       g = (float)*row++ / max; \
-       r = (float)*row++ / max; \
+#define PROCESS_BGR_PIXEL(type,max, column) { \
+       type *rp = (type *)row; \
+       b = (float)rp[0] / max; \
+       g = (float)rp[1] / max; \
+       r = (float)rp[2] / max; \
        HSV::rgb_to_hsv(r, g, b, h, s, v); \
        intensity = v; \
        PROCESS_PIXEL(column) \
@@ -181,120 +183,140 @@ void ScopeUnit::process_package(LoadPackage *package)
        int wave_w = waveform_vframe->get_w();
        int vector_h = vector_vframe->get_h();
        int vector_w = vector_vframe->get_w();
-       int out_w = gui->output_frame->get_w();
-       int out_h = gui->output_frame->get_h();
-       int winc = (wave_w * wave_h) / (out_w * out_h);
+       int dat_w = gui->data_frame->get_w();
+       int dat_h = gui->data_frame->get_h();
+       int winc = (wave_w * wave_h) / (dat_w * dat_h);
        if( use_wave_parade ) winc *= 3;
-       winc += 2;  winc *= gui->wdial;
-       int vinc = 3*(vector_w * vector_h) / (out_w * out_h) + 2;
-       vinc *= gui->vdial;
+       winc += 2;  winc *= gui->use_wave_gain;
+       int vinc = 3*(vector_w * vector_h) / (dat_w * dat_h) + 2;
+       vinc *= gui->use_vect_gain;
        float radius = MIN(gui->vector_w / 2, gui->vector_h / 2);
-       unsigned char **waveform_rows = waveform_vframe->get_rows();
-       unsigned char **vector_rows = vector_vframe->get_rows();
-       unsigned char **rows = gui->output_frame->get_rows();
+       uint8_t **waveform_rows = waveform_vframe->get_rows();
+       uint8_t **vector_rows = vector_vframe->get_rows();
+       uint8_t **rows = gui->data_frame->get_rows();
 
-       switch( gui->output_frame->get_color_model() ) {
+       switch( gui->data_frame->get_color_model() ) {
        case BC_RGB888:
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
-                       unsigned char *row = rows[y];
-                       for( int x=0; x<out_w; ++x ) {
-                               PROCESS_RGB_PIXEL(x, 255)
+                       uint8_t *row = rows[y];
+                       for( int x=0; x<dat_w; ++x ) {
+                               PROCESS_RGB_PIXEL(uint8_t,0xff, x)
+                               row += 3*sizeof(uint8_t);
                        }
                }
                break;
        case BC_RGBA8888:
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
-                       unsigned char *row = rows[y];
-                       for( int x=0; x<out_w; ++x ) {
-                               PROCESS_RGB_PIXEL(x, 255)
-                               ++row;
+                       uint8_t *row = rows[y];
+                       for( int x=0; x<dat_w; ++x ) {
+                               PROCESS_RGB_PIXEL(uint8_t,0xff, x)
+                               row += 4*sizeof(uint8_t);
+                       }
+               }
+               break;
+       case BC_RGB161616:
+               for( int y=pkg->row1; y<pkg->row2; ++y ) {
+                       uint8_t *row = rows[y];
+                       for( int x=0; x<dat_w; ++x ) {
+                               PROCESS_RGB_PIXEL(uint16_t,0xffff, x)
+                               row += 3*sizeof(uint16_t);
+                       }
+               }
+               break;
+       case BC_RGBA16161616:
+               for( int y=pkg->row1; y<pkg->row2; ++y ) {
+                       uint8_t *row = rows[y];
+                       for( int x=0; x<dat_w; ++x ) {
+                               PROCESS_RGB_PIXEL(uint16_t,0xffff, x)
+                               row += 4*sizeof(uint16_t);
                        }
                }
                break;
        case BC_BGR888:
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
-                       unsigned char *row = rows[y];
-                       for( int x=0; x<out_w; ++x ) {
-                               PROCESS_BGR_PIXEL(x, 255)
+                       uint8_t *row = rows[y];
+                       for( int x=0; x<dat_w; ++x ) {
+                               PROCESS_BGR_PIXEL(uint8_t,0xff, x)
+                               row += 3*sizeof(uint8_t);
                        }
                }
                break;
        case BC_BGR8888:
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
-                       unsigned char *row = rows[y];
-                       for( int x=0; x<out_w; ++x ) {
-                               PROCESS_BGR_PIXEL(x, 255)
-                               ++row;
+                       uint8_t *row = rows[y];
+                       for( int x=0; x<dat_w; ++x ) {
+                               PROCESS_BGR_PIXEL(uint8_t,0xff, x)
+                               row += 4*sizeof(uint8_t);
                        }
                }
                break;
        case BC_RGB_FLOAT:
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
                        float *row = (float*)rows[y];
-                       for( int x=0; x<out_w; ++x ) {
-                               PROCESS_RGB_PIXEL(x, 1.0)
+                       for( int x=0; x<dat_w; ++x ) {
+                               PROCESS_RGB_PIXEL(float,1.f, x)
+                               row += 3*sizeof(float);
                        }
                }
                break;
        case BC_RGBA_FLOAT:
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
                        float *row = (float*)rows[y];
-                       for( int x=0; x<out_w; ++x ) {
-                               PROCESS_RGB_PIXEL(x, 1.0)
-                               ++row;
+                       for( int x=0; x<dat_w; ++x ) {
+                               PROCESS_RGB_PIXEL(float,1.f, x)
+                               row += 4*sizeof(float);
                        }
                }
                break;
        case BC_YUV888:
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
-                       unsigned char *row = rows[y];
-                       for( int x=0; x<out_w; ++x ) {
+                       uint8_t *row = rows[y];
+                       for( int x=0; x<dat_w; ++x ) {
                                PROCESS_YUV_PIXEL(x, row[0], row[1], row[2])
-                               row += 3;
+                               row += 3*sizeof(uint8_t);
                        }
                }
                break;
 
        case BC_YUVA8888:
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
-                       unsigned char *row = rows[y];
-                       for( int x=0; x<out_w; ++x ) {
+                       uint8_t *row = rows[y];
+                       for( int x=0; x<dat_w; ++x ) {
                                PROCESS_YUV_PIXEL(x, row[0], row[1], row[2])
-                               row += 4;
+                               row += 4*sizeof(uint8_t);
                        }
                }
                break;
        case BC_YUV420P: {
-               unsigned char *yp = gui->output_frame->get_y();
-               unsigned char *up = gui->output_frame->get_u();
-               unsigned char *vp = gui->output_frame->get_v();
+               uint8_t *yp = gui->data_frame->get_y();
+               uint8_t *up = gui->data_frame->get_u();
+               uint8_t *vp = gui->data_frame->get_v();
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
-                       unsigned char *y_row = yp + y * out_w;
-                       unsigned char *u_row = up + (y / 2) * (out_w / 2);
-                       unsigned char *v_row = vp + (y / 2) * (out_w / 2);
-                       for( int x=0; x<out_w; x+=2 ) {
+                       uint8_t *y_row = yp + y * dat_w;
+                       uint8_t *u_row = up + (y / 2) * (dat_w / 2);
+                       uint8_t *v_row = vp + (y / 2) * (dat_w / 2);
+                       for( int x=0; x<dat_w; x+=2 ) {
                                PROCESS_YUV_PIXEL(x, *y_row, *u_row, *v_row);
                                ++y_row;
                                PROCESS_YUV_PIXEL(x + 1, *y_row, *u_row, *v_row);
-                               ++y_row;
-                               ++u_row;  ++v_row;
+                               ++y_row;  ++u_row;  ++v_row;
                        }
                }
                break; }
        case BC_YUV422:
                for( int y=pkg->row1; y<pkg->row2; ++y ) {
-                       unsigned char *row = rows[y];
-                       for( int x=0; x<out_w; x+=2 ) {
+                       uint8_t *row = rows[y];
+                       for( int x=0; x<dat_w; x+=2 ) {
                                PROCESS_YUV_PIXEL(x, row[0], row[1], row[3]);
                                PROCESS_YUV_PIXEL(x + 1, row[2], row[1], row[3]);
-                               row += 4;
+                               row += 4*sizeof(uint8_t);
                        }
                }
                break;
 
        default:
                printf("ScopeUnit::process_package %d: color_model=%d unrecognized\n",
-                       __LINE__, gui->output_frame->get_color_model());
+                       __LINE__, gui->data_frame->get_color_model());
                break;
        }
 }
@@ -313,7 +335,7 @@ ScopeEngine::~ScopeEngine()
 
 void ScopeEngine::init_packages()
 {
-       int y = 0, h = gui->output_frame->get_h();
+       int y = 0, h = gui->data_frame->get_h();
        for( int i=0,n=LoadServer::get_total_packages(); i<n; ) {
                ScopePackage *pkg = (ScopePackage*)get_package(i);
                pkg->row1 = y;
@@ -364,6 +386,7 @@ ScopeGUI::ScopeGUI(Theme *theme,
        this->y = y;
        this->w = w;
        this->h = h;
+       this->temp_frame = 0;
        this->theme = theme;
        this->cpus = cpus;
        reset();
@@ -376,6 +399,7 @@ ScopeGUI::ScopeGUI(PluginClient *plugin, int w, int h)
        this->y = get_y();
        this->w = w;
        this->h = h;
+       this->temp_frame = 0;
        this->theme = plugin->get_theme();
        this->cpus = plugin->PluginClient::smp + 1;
        reset();
@@ -386,14 +410,22 @@ ScopeGUI::~ScopeGUI()
        delete waveform_vframe;
        delete vector_vframe;
        delete engine;
+       delete box_blur;
+       delete temp_frame;
 }
 
 void ScopeGUI::reset()
 {
+       output_frame = 0;
+       data_frame = 0;
        frame_w = 1;
+       use_smooth = 1;
+       use_wave_gain = 5;
+       use_vect_gain = 5;
        waveform_vframe = 0;
        vector_vframe = 0;
        engine = 0;
+       box_blur = 0;
        use_hist = 0;
        use_wave = 1;
        use_vector = 1;
@@ -402,8 +434,8 @@ void ScopeGUI::reset()
        waveform = 0;
        vectorscope = 0;
        histogram = 0;
-       wave_w = wave_h = vector_w = vector_h = 0;
-       wdial = vdial = 5.f;
+       wave_w = wave_h = 0;
+       vector_w = vector_h = 0;
 }
 
 
@@ -417,12 +449,14 @@ void ScopeGUI::create_objects()
 
        lock_window("ScopeGUI::create_objects");
        int x = theme->widget_border;
-       int y = theme->widget_border +
-               ScopeWaveDial::calculate_h() - ScopeMenu::calculate_h();
+       int y = theme->widget_border;
+       add_subwindow(smooth = new ScopeSmooth(this, x, y));
+       y += smooth->get_h() + theme->widget_border;
        add_subwindow(scope_menu = new ScopeMenu(this, x, y));
        scope_menu->create_objects();
        x += scope_menu->get_w() + theme->widget_border;
        add_subwindow(value_text = new BC_Title(x, y, ""));
+       y += scope_menu->get_h() + theme->widget_border;
 
        create_panels();
        update_toggles();
@@ -434,46 +468,47 @@ void ScopeGUI::create_objects()
 void ScopeGUI::create_panels()
 {
        calculate_sizes(get_w(), get_h());
+       int slider_w = xS(100);
        if( (use_wave || use_wave_parade) ) {
-               int px = wave_x + wave_w - ScopeWaveDial::calculate_w() - xS(5);
-               int py = wave_y - ScopeWaveDial::calculate_h() - yS(5);
+               int px = wave_x + wave_w - slider_w - xS(5);
+               int py = wave_y - ScopeWaveSlider::get_span(0) - yS(5);
                if( !waveform ) {
                        add_subwindow(waveform = new ScopeWaveform(this,
                                wave_x, wave_y, wave_w, wave_h));
                        waveform->create_objects();
-                       add_subwindow(wave_dial = new ScopeWaveDial(this, px, py));
+                       add_subwindow(wave_slider = new ScopeWaveSlider(this, px, py, slider_w));
                }
                else {
                        waveform->reposition_window(
                                wave_x, wave_y, wave_w, wave_h);
                        waveform->clear_box(0, 0, wave_w, wave_h);
-                       wave_dial->reposition_window(px, py);
+                       wave_slider->reposition_window(px, py);
                }
        }
        else if( !(use_wave || use_wave_parade) && waveform ) {
-               delete waveform;   waveform = 0;
-               delete wave_dial;  wave_dial = 0;
+               delete waveform;     waveform = 0;
+               delete wave_slider;  wave_slider = 0;
        }
 
        if( use_vector ) {
-               int vx = vector_x + vector_w - ScopeVectDial::calculate_w() - xS(5);
-               int vy = vector_y - ScopeVectDial::calculate_h() - yS(5);
+               int vx = vector_x + vector_w - slider_w - xS(5);
+               int vy = vector_y - ScopeVectSlider::get_span(0) - yS(5);
                if( !vectorscope ) {
                        add_subwindow(vectorscope = new ScopeVectorscope(this,
                                vector_x, vector_y, vector_w, vector_h));
                        vectorscope->create_objects();
-                       add_subwindow(vect_dial = new ScopeVectDial(this, vx, vy));
+                       add_subwindow(vect_slider = new ScopeVectSlider(this, vx, vy, slider_w));
                }
                else {
                        vectorscope->reposition_window(
                                vector_x, vector_y, vector_w, vector_h);
                        vectorscope->clear_box(0, 0, vector_w, vector_h);
-                       vect_dial->reposition_window(vx, vy);
+                       vect_slider->reposition_window(vx, vy);
                }
        }
        else if( !use_vector && vectorscope ) {
                delete vectorscope;  vectorscope = 0;
-               delete vect_dial;    vect_dial = 0;
+               delete vect_slider;  vect_slider = 0;
        }
 
        if( (use_hist || use_hist_parade) ) {
@@ -522,7 +557,7 @@ void ScopeGUI::toggle_event()
 void ScopeGUI::calculate_sizes(int w, int h)
 {
        int margin = theme->widget_border;
-       int menu_h = ScopeWaveDial::calculate_h() + margin * 2;
+       int menu_h = smooth->get_h() + scope_menu->get_h() + margin * 3;
        int text_w = get_text_width(SMALLFONT, "000") + margin * 2;
        int total_panels = ((use_hist || use_hist_parade) ? 1 : 0) +
                ((use_wave || use_wave_parade) ? 1 : 0) +
@@ -593,13 +628,14 @@ int ScopeGUI::resize_event(int w, int h)
        this->w = w;
        this->h = h;
        calculate_sizes(w, h);
+       int margin = theme->widget_border;
 
        if( waveform ) {
                waveform->reposition_window(wave_x, wave_y, wave_w, wave_h);
                waveform->clear_box(0, 0, wave_w, wave_h);
-               int px = wave_x + wave_w - ScopeWaveDial::calculate_w() - xS(5);
-               int py = wave_y - ScopeWaveDial::calculate_h() - yS(5);
-               wave_dial->reposition_window(px, py);
+               int px = wave_x + wave_w - wave_slider->get_w() - margin;
+               int py = wave_y - wave_slider->get_h() - margin;
+               wave_slider->reposition_window(px, py);
        }
 
        if( histogram ) {
@@ -610,9 +646,9 @@ int ScopeGUI::resize_event(int w, int h)
        if( vectorscope ) {
                vectorscope->reposition_window(vector_x, vector_y, vector_w, vector_h);
                vectorscope->clear_box(0, 0, vector_w, vector_h);
-               int vx = vector_x + vector_w - ScopeVectDial::calculate_w() - xS(5);
-               int vy = vector_y - ScopeVectDial::calculate_h() - yS(5);
-               vect_dial->reposition_window(vx, vy);
+               int vx = vector_x + vector_w - vect_slider->get_w() - margin;
+               int vy = vector_y - vect_slider->get_h() - margin;
+               vect_slider->reposition_window(vx, vy);
        }
 
        allocate_vframes();
@@ -738,7 +774,17 @@ void ScopeGUI::process(VFrame *output_frame)
 {
        lock_window("ScopeGUI::process");
        this->output_frame = output_frame;
-       frame_w = output_frame->get_w();
+       int ow = output_frame->get_w(), oh = output_frame->get_h();
+       if( use_smooth ) {
+               VFrame::get_temp(temp_frame, ow, oh, BC_RGB161616);
+               temp_frame->transfer_from(output_frame);
+               if( !box_blur ) box_blur = new BoxBlur(cpus);
+               box_blur->blur(temp_frame, temp_frame, 2, 2);
+               data_frame = temp_frame;
+       }
+       else
+               data_frame = output_frame;
+       frame_w = data_frame->get_w();
        //float radius = MIN(vector_w / 2, vector_h / 2);
        bzero(waveform_vframe->get_data(), waveform_vframe->get_data_size());
        bzero(vector_vframe->get_data(), vector_vframe->get_data_size());
@@ -747,9 +793,9 @@ void ScopeGUI::process(VFrame *output_frame)
        if( histogram )
                histogram->draw(0, 0);
        if( waveform )
-               waveform->draw_vframe(waveform_vframe, 1, 0, 0);
+               waveform->draw_vframe(waveform_vframe);
        if( vectorscope )
-               vectorscope->draw_vframe(vector_vframe, 1, 0, 0);
+               vectorscope->draw_vframe(vector_vframe);
 
        draw_overlays(1, 0, 1);
        unlock_window();
@@ -1076,12 +1122,14 @@ void ScopeMenu::create_objects()
                new ScopeScopesOn(this, _("Histogram"), SCOPE_HISTOGRAM));
        add_item(hist_rgb_on =
                new ScopeScopesOn(this, _("Histogram RGB"), SCOPE_HISTOGRAM_RGB));
+       add_item(new BC_MenuItem("-"));
        add_item(wave_on =
                new ScopeScopesOn(this, _("Waveform"), SCOPE_WAVEFORM));
        add_item(wave_rgb_on =
                new ScopeScopesOn(this, _("Waveform RGB"), SCOPE_WAVEFORM_RGB));
        add_item(wave_ply_on =
                new ScopeScopesOn(this, _("Waveform ply"), SCOPE_WAVEFORM_PLY));
+       add_item(new BC_MenuItem("-"));
        add_item(vect_on =
                new ScopeScopesOn(this, _("Vectorscope"), SCOPE_VECTORSCOPE));
 }
@@ -1096,27 +1144,194 @@ void ScopeMenu::update_toggles()
        vect_on->set_checked(gui->use_vector);
 }
 
-ScopeWaveDial::ScopeWaveDial(ScopeGUI *gui, int x, int y)
- : BC_FPot(x, y, gui->wdial, 1.f, 9.f)
+ScopeWaveSlider::ScopeWaveSlider(ScopeGUI *gui, int x, int y, int w)
+ : BC_ISlider(x, y, 0, w, w, 1, 9, gui->use_wave_gain)
+{
+       this->gui = gui;
+}
+int ScopeWaveSlider::handle_event()
+{
+       gui->use_wave_gain = get_value();
+       gui->update_scope();
+       gui->toggle_event();
+       return 1;
+}
+
+ScopeVectSlider::ScopeVectSlider(ScopeGUI *gui, int x, int y, int w)
+ : BC_ISlider(x, y, 0, w, w, 1, 9, gui->use_vect_gain)
 {
        this->gui = gui;
 }
-int ScopeWaveDial::handle_event()
+int ScopeVectSlider::handle_event()
 {
-       gui->wdial = get_value();
+       gui->use_vect_gain = get_value();
        gui->update_scope();
+       gui->toggle_event();
        return 1;
 }
 
-ScopeVectDial::ScopeVectDial(ScopeGUI *gui, int x, int y)
- : BC_FPot(x, y, gui->vdial, 1.f, 9.f)
+ScopeSmooth::ScopeSmooth(ScopeGUI *gui, int x, int y)
+ : BC_CheckBox(x, y, gui->use_smooth, _("Smooth"))
 {
        this->gui = gui;
 }
-int ScopeVectDial::handle_event()
+
+int ScopeSmooth::handle_event()
 {
-       gui->vdial = get_value();
+       gui->use_smooth = get_value();
        gui->update_scope();
+       gui->toggle_event();
        return 1;
 }
 
+// from ffmpeg vf_boxblur
+template<class dst_t, class src_t> static inline
+void blurt(dst_t *dst, int dst_step, src_t *src, int src_step, int len, int radius)
+{
+       const int length = radius*2 + 1;
+       const int inv = ((1<<16) + length/2)/length;
+       int x, n, sum = src[radius*src_step];
+
+       for( x=0; x<radius; ++x )
+               sum += src[x*src_step]<<1;
+       sum = sum*inv + (1<<15);
+
+       for( x=0; x<=radius; ++x ) {
+               sum += (src[(radius+x)*src_step] - src[(radius-x)*src_step])*inv;
+               dst[x*dst_step] = sum>>16;
+       }
+       n = len - radius;
+       for( ; x<n; ++x ) {
+               sum += (src[(radius+x)*src_step] - src[(x-radius-1)*src_step])*inv;
+               dst[x*dst_step] = sum >>16;
+       }
+
+       for ( ; x<len; ++x ) {
+               sum += (src[(2*len-radius-x-1)*src_step] - src[(x-radius-1)*src_step])*inv;
+               dst[x*dst_step] = sum>>16;
+       }
+}
+template<class dst_t, class src_t> static inline
+void blur_power(dst_t *dst, int dst_step, src_t *src, int src_step,
+               int len, int radius, int power)
+{
+       dst_t atemp[len], btemp[len];
+       dst_t *a = atemp, *b = btemp;
+       blurt(a, 1, src, src_step, len, radius);
+       while( power-- > 2 ) {
+               blurt(b, 1, a, 1, len, radius);
+               dst_t *t = a; a = b; b = t;
+        }
+       if( power > 1 )
+               blurt(dst, dst_step, a, 1, len, radius);
+       else
+                for( int i = 0; i<len; ++i ) dst[i*dst_step] = a[i];
+}
+
+
+BoxBlurPackage::BoxBlurPackage()
+ : LoadPackage()
+{
+}
+
+BoxBlurUnit::BoxBlurUnit(BoxBlur *box_blur)
+ : LoadClient(box_blur)
+{
+}
+
+template<class dst_t, class src_t>
+void BoxBlurUnit::blurt_package(LoadPackage *package)
+{
+       BoxBlur *box_blur = (BoxBlur *)server;
+       src_t *src_data = (src_t *)box_blur->src_data;
+       dst_t *dst_data = (dst_t *)box_blur->dst_data;
+       int radius = box_blur->radius;
+       int power = box_blur->power;
+       int vlen = box_blur->vlen;
+       int c0 = box_blur->c0, c1 = box_blur->c1;
+       int src_ustep = box_blur->src_ustep;
+       int dst_ustep = box_blur->dst_ustep;
+       int src_vstep = box_blur->src_vstep;
+       int dst_vstep = box_blur->dst_vstep;
+       BoxBlurPackage *pkg = (BoxBlurPackage*)package;
+       int u1 = pkg->u1, u2 = pkg->u2;
+       for( int u=u1; u<u2; ++u ) {
+               src_t *sp = src_data + u*src_ustep;
+               dst_t *dp = dst_data + u*dst_ustep;
+               for( int c=c0; c<=c1; ++c ) {
+                       blur_power(dp+c, dst_vstep, sp+c, src_vstep,
+                               vlen, radius, power);
+               }
+       }
+}
+
+void BoxBlurUnit::process_package(LoadPackage *package)
+{
+       blurt_package<uint16_t, const uint16_t>(package);
+}
+
+BoxBlur::BoxBlur(int cpus)
+ : LoadServer(cpus, cpus)
+{
+}
+BoxBlur::~BoxBlur()
+{
+}
+
+LoadClient* BoxBlur::new_client() { return new BoxBlurUnit(this); }
+LoadPackage* BoxBlur::new_package() { return new BoxBlurPackage(); }
+
+void BoxBlur::init_packages()
+{
+       int u = 0;
+       for( int i=0,n=LoadServer::get_total_packages(); i<n; ) {
+               BoxBlurPackage *pkg = (BoxBlurPackage*)get_package(i);
+               pkg->u1 = u;
+               pkg->u2 = u = (++i * ulen) / n;
+       }
+}
+
+//dst can equal src, requires geom(dst)==geom(src)
+//uv: 0=hblur, 1=vblur;  comp: -1=rgb,0=r,1=g,2=b
+void BoxBlur::process(VFrame *dst, VFrame *src, int uv,
+               int radius, int power, int comp)
+{
+       this->radius = radius;
+       this->power = power;
+       int src_w = src->get_w(), src_h = src->get_h();
+       ulen = !uv ? src_h : src_w;
+       vlen = !uv ? src_w : src_h;
+       c0 = comp<0 ? 0 : comp;
+       c1 = comp<0 ? 2 : comp;
+       src_data = src->get_data();
+       dst_data = dst->get_data();
+       int src_pixsz = BC_CModels::calculate_pixelsize(src->get_color_model());
+       int src_comps = BC_CModels::components(src->get_color_model());
+       int src_bpp = src_pixsz / src_comps;
+       int dst_pixsz = BC_CModels::calculate_pixelsize(dst->get_color_model());
+       int dst_comps = BC_CModels::components(dst->get_color_model());
+       int dst_bpp = dst_pixsz / dst_comps;
+       int dst_linsz = dst->get_bytes_per_line() / dst_bpp;
+       int src_linsz = src->get_bytes_per_line() / src_bpp;
+       src_ustep = !uv ? src_linsz : src_comps;
+       dst_ustep = !uv ? dst_linsz: dst_comps;
+       src_vstep = !uv ? src_comps : src_linsz;
+       dst_vstep = !uv ? dst_comps : dst_linsz;
+
+       process_packages();
+}
+
+void BoxBlur::hblur(VFrame *dst, VFrame *src, int radius, int power, int comp)
+{
+       process(dst, src, 0, radius, power, comp);
+}
+void BoxBlur::vblur(VFrame *dst, VFrame *src, int radius, int power, int comp)
+{
+       process(dst, src, 1, radius, power, comp);
+}
+void BoxBlur::blur(VFrame *dst, VFrame *src, int radius, int power, int comp)
+{
+       process(dst, src, 0, radius, power, comp);
+       process(dst, dst, 1, radius, power, comp);
+}
+
index 93ef7a8931b3143365f009f8032ae4d3379b16ff..74201e460f4520a88ee50be2c531c6c3550fe304 100644 (file)
@@ -161,22 +161,31 @@ public:
        ScopeScopesOn *vect_on;
 };
 
-class ScopeWaveDial : public BC_FPot
+class ScopeWaveSlider : public BC_ISlider
 {
 public:
-       ScopeWaveDial(ScopeGUI *gui, int x, int y);
+       ScopeWaveSlider(ScopeGUI *gui, int x, int y, int w);
        int handle_event();
        ScopeGUI *gui;
 };
 
-class ScopeVectDial : public BC_FPot
+class ScopeVectSlider : public BC_ISlider
 {
 public:
-       ScopeVectDial(ScopeGUI *gui, int x, int y);
+       ScopeVectSlider(ScopeGUI *gui, int x, int y, int w);
        int handle_event();
        ScopeGUI *gui;
 };
 
+class ScopeSmooth : public BC_CheckBox
+{
+public:
+       ScopeSmooth(ScopeGUI *gui, int x, int y);
+       int handle_event();
+       ScopeGUI *gui;
+};
+
+
 class ScopeGUI : public PluginClientWindow
 {
 public:
@@ -205,29 +214,73 @@ public:
 
        Theme *theme;
        VFrame *output_frame;
+       VFrame *data_frame, *temp_frame;
        ScopeEngine *engine;
+       BoxBlur *box_blur;
        VFrame *waveform_vframe;
        VFrame *vector_vframe;
        ScopeHistogram *histogram;
        ScopeWaveform *waveform;
        ScopeVectorscope *vectorscope;
        ScopeMenu *scope_menu;
-       ScopeWaveDial *wave_dial;
-       ScopeVectDial *vect_dial;
+       ScopeWaveSlider *wave_slider;
+       ScopeVectSlider *vect_slider;
+       ScopeSmooth *smooth;
        BC_Title *value_text;
 
        int x, y, w, h;
        int vector_x, vector_y, vector_w, vector_h;
        int wave_x, wave_y, wave_w, wave_h;
        int hist_x, hist_y, hist_w, hist_h;
-       float wdial, vdial;
 
        int cpus;
        int use_hist, use_wave, use_vector;
        int use_hist_parade, use_wave_parade;
 
        int bins[HIST_SECTIONS][TOTAL_BINS];
-       int frame_w;
+       int frame_w, use_smooth;
+       int use_wave_gain, use_vect_gain;
+};
+
+
+class BoxBlurPackage : public LoadPackage
+{
+public:
+       BoxBlurPackage();
+       int u1, u2;
+};
+
+class BoxBlurUnit : public LoadClient
+{
+public:
+       BoxBlurUnit(BoxBlur*server);
+       template<class dst_t, class src_t>
+               void blurt_package(LoadPackage *package);
+       void process_package(LoadPackage *package);
+};
+
+class BoxBlur : public LoadServer
+{
+public:
+       BoxBlur(int cpus);
+       virtual ~BoxBlur();
+       void init_packages();
+       LoadClient* new_client();
+       LoadPackage* new_package();
+       void process(VFrame *dst, VFrame *src, int uv,
+               int radius, int power, int comp);
+       void hblur(VFrame *dst, VFrame *src,
+               int radius, int power, int comp=-1);
+       void vblur(VFrame *dst, VFrame *src,
+               int radius, int power, int comp=-1);
+       void blur(VFrame *dst, VFrame *src,
+               int radius, int power, int comp=-1);
+       const uint8_t *src_data;
+       uint8_t *dst_data;
+       int src_ustep, dst_ustep;
+       int src_vstep, dst_vstep;
+       int radius, power;
+       int ulen, vlen, c0, c1;
 };
 
 #endif
index 3dff0beff86e77e1a5bcbabf4fbb88c3defd5047..3da8bd28ebe4f98451749524bcb90f1014693eb0 100644 (file)
@@ -32,8 +32,13 @@ class ScopeScopesOn;
 class ScopeMenu;
 class ScopeWaveDial;
 class ScopeVectDial;
+class ScopeSmooth;
 class ScopeGUI;
 
+class BoxBlurPackage;
+class BoxBlurUnit;
+class BoxBlur;
+
 #endif
 
 
index 20e6668889b0b1cd23f14155cb64654042d735a6..80ca335c5d78a7dde1fe95ddddeda873e27a3c04 100644 (file)
@@ -708,7 +708,7 @@ void Theme::draw_mwindow_bg(MWindowGUI *gui)
 
 void Theme::get_cwindow_sizes(CWindowGUI *gui, int cwindow_controls)
 {
-       int total_buttons = !use_commercials ? 17 : 18;
+       int total_buttons = !use_commercials ? 16 : 17;
        int edit_w = EditPanel::calculate_w(mwindow, 1, total_buttons);
        int transport_w = PlayTransport::get_transport_width(mwindow) + toggle_margin;
        int zoom_w = ZoomPanel::calculate_w(czoom_w);
index f3c1cde75f118c5d9b1005ffc001c26e938688c8..28f68fc50b4351cef2e97858bc7ddf9ec0f56084 100644 (file)
@@ -1036,7 +1036,7 @@ void CAKEWALKTHEME::initialize()
 }
 void CAKEWALKTHEME::get_vwindow_sizes(VWindowGUI *gui)
 {
- int edit_w = EditPanel::calculate_w(mwindow, 0, xS(10));
+ int edit_w = EditPanel::calculate_w(mwindow, 0, 12);
  int transport_w = PlayTransport::get_transport_width(mwindow) + toggle_margin;
  vtimebar_h = yS(16);
  int division_w = xS(30);
@@ -1072,7 +1072,7 @@ void CAKEWALKTHEME::get_vwindow_sizes(VWindowGUI *gui)
    get_image_set("autokeyframe")[0]->get_h() -
    widget_border;
   vdivision_x = xS(280);
-  vtime_x = vedit_x + xS(65);
+  vtime_x = vedit_x + xS(85);
   vtime_y = vedit_y + yS(28);
  } else {
   buttons_h = vtimebar_h +
index ac057329558d69c104de809f85bc64223202934a..3a02a47edf38630046168297bfdd19312f648d12 100644 (file)
@@ -1193,7 +1193,7 @@ void NEOPHYTETHEME::initialize()
 // Re-align the Clock. theme.c:931 
 void NEOPHYTETHEME::get_vwindow_sizes(VWindowGUI *gui)
 {
-       int edit_w = EditPanel::calculate_w(mwindow, 0, xS(10));
+       int edit_w = EditPanel::calculate_w(mwindow, 0, 12);
        int transport_w = PlayTransport::get_transport_width(mwindow) + toggle_margin;
        vtimebar_h = yS(16);       // The height of the position indicator
        int division_w = xS(30);
@@ -1260,7 +1260,8 @@ void NEOPHYTETHEME::get_vwindow_sizes(VWindowGUI *gui)
 
                vdivision_x = vedit_x + edit_w + division_w;
                vtime_x = vdivision_x + vtime_border;
-               vtime_y = vedit_y + widget_border - 7; // vertical height concentric at button height
+               // vertical height concentric at button height
+               vtime_y = vedit_y + widget_border - yS(7);
        }
 
        // vtimebar_x = vcanvas_x;
index 1b7322df0091dcafe23302b62b2dde53b1e03f28..e662dacbf65518e4ff5d947f2f3840122b334940 100644 (file)
 #include <string.h>
 
 
-
-
-
 class VideoScopeEffect;
-class VideoScopeEngine;
 class VideoScopeWindow;
 
 class VideoScopeConfig
@@ -61,39 +57,7 @@ public:
        void create_objects();
        void toggle_event();
        int resize_event(int w, int h);
-       void update();
-
-       VideoScopeEffect *plugin;
-};
-
-
-
 
-
-class VideoScopePackage : public LoadPackage
-{
-public:
-       VideoScopePackage();
-       int row1, row2;
-};
-
-
-class VideoScopeUnit : public LoadClient
-{
-public:
-       VideoScopeUnit(VideoScopeEffect *plugin, VideoScopeEngine *server);
-       void process_package(LoadPackage *package);
-       VideoScopeEffect *plugin;
-};
-
-class VideoScopeEngine : public LoadServer
-{
-public:
-       VideoScopeEngine(VideoScopeEffect *plugin, int cpus);
-       ~VideoScopeEngine();
-       void init_packages();
-       LoadClient* new_client();
-       LoadPackage* new_package();
        VideoScopeEffect *plugin;
 };
 
@@ -113,42 +77,19 @@ public:
 
        int use_hist, use_wave, use_vector;
        int use_hist_parade, use_wave_parade;
+       int use_wave_gain, use_vect_gain, use_smooth;
+
        int w, h;
        VFrame *input;
 };
 
 
-
-
-
-
-
-
-
-
-
-
-
-
 VideoScopeConfig::VideoScopeConfig()
 {
 }
 
-
-
-
-
-
-
-
-
-
-
-
 VideoScopeWindow::VideoScopeWindow(VideoScopeEffect *plugin)
- : ScopeGUI(plugin,
-       plugin->w,
-       plugin->h)
+ : ScopeGUI(plugin, plugin->w, plugin->h)
 {
        this->plugin = plugin;
 }
@@ -164,6 +105,10 @@ void VideoScopeWindow::create_objects()
        use_vector = plugin->use_vector;
        use_hist_parade = plugin->use_hist_parade;
        use_wave_parade = plugin->use_wave_parade;
+       use_wave_gain = plugin->use_wave_gain;
+       use_vect_gain = plugin->use_vect_gain;
+       use_smooth = plugin->use_smooth;
+
        ScopeGUI::create_objects();
 }
 
@@ -174,6 +119,9 @@ void VideoScopeWindow::toggle_event()
        plugin->use_vector = use_vector;
        plugin->use_hist_parade = use_hist_parade;
        plugin->use_wave_parade = use_wave_parade;
+       plugin->use_wave_gain = use_wave_gain;
+       plugin->use_vect_gain = use_vect_gain;
+       plugin->use_smooth = use_smooth;
 // Make it reprocess
        plugin->send_configure_change();
 }
@@ -189,32 +137,8 @@ int VideoScopeWindow::resize_event(int w, int h)
        return 1;
 }
 
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
 REGISTER_PLUGIN(VideoScopeEffect)
 
-
-
-
-
-
 VideoScopeEffect::VideoScopeEffect(PluginServer *server)
  : PluginVClient(server)
 {
@@ -225,16 +149,15 @@ VideoScopeEffect::VideoScopeEffect(PluginServer *server)
        use_vector = 1;
        use_hist_parade = 1;
        use_wave_parade = 1;
+       use_wave_gain = 5;
+       use_vect_gain = 5;
+       use_smooth = 1;
 }
 
 VideoScopeEffect::~VideoScopeEffect()
 {
-
-
 }
 
-
-
 const char* VideoScopeEffect::plugin_title() { return N_("VideoScope"); }
 int VideoScopeEffect::is_realtime() { return 1; }
 
@@ -250,10 +173,7 @@ void VideoScopeEffect::save_data(KeyFrame *keyframe)
 // cause data to be stored directly in text
        output.set_shared_output(keyframe->xbuf);
        output.tag.set_title("VIDEOSCOPE");
-
-
-       if(is_defaults())
-       {
+       if( is_defaults() ) {
                output.tag.set_property("W", w);
                output.tag.set_property("H", h);
                output.tag.set_property("USE_HIST", use_hist);
@@ -261,8 +181,11 @@ void VideoScopeEffect::save_data(KeyFrame *keyframe)
                output.tag.set_property("USE_VECTOR", use_vector);
                output.tag.set_property("USE_HIST_PARADE", use_hist_parade);
                output.tag.set_property("USE_WAVE_PARADE", use_wave_parade);
-       }
+               output.tag.set_property("USE_WAVE_GAIN", use_wave_gain);
+               output.tag.set_property("USE_VECT_GAIN", use_vect_gain);
+               output.tag.set_property("USE_SMOOTH", use_smooth);
 
+       }
        output.append_tag();
        output.tag.set_title("/VIDEOSCOPE");
        output.append_tag();
@@ -274,285 +197,44 @@ void VideoScopeEffect::read_data(KeyFrame *keyframe)
 {
        FileXML input;
        input.set_shared_input(keyframe->xbuf);
-
        int result = 0;
 
-
-       while(!result)
-       {
-               result = input.read_tag();
-
-               if(!result)
-               {
-                       if(input.tag.title_is("VIDEOSCOPE"))
-                       {
-                               if(is_defaults())
-                               {
-                                       w = input.tag.get_property("W", w);
-                                       h = input.tag.get_property("H", h);
-                                       use_hist = input.tag.get_property("USE_HIST", use_hist);
-                                       use_wave = input.tag.get_property("USE_WAVE", use_wave);
-                                       use_vector = input.tag.get_property("USE_VECTOR", use_vector);
-                                       use_hist_parade = input.tag.get_property("USE_HIST_PARADE", use_hist_parade);
-                                       use_wave_parade = input.tag.get_property("USE_WAVE_PARADE", use_wave_parade);
-                               }
+       while( !(result = input.read_tag()) ) {
+               if( input.tag.title_is("VIDEOSCOPE") ) {
+                       if( is_defaults() ) {
+                               w = input.tag.get_property("W", w);
+                               h = input.tag.get_property("H", h);
+                               use_hist = input.tag.get_property("USE_HIST", use_hist);
+                               use_wave = input.tag.get_property("USE_WAVE", use_wave);
+                               use_vector = input.tag.get_property("USE_VECTOR", use_vector);
+                               use_hist_parade = input.tag.get_property("USE_HIST_PARADE", use_hist_parade);
+                               use_wave_parade = input.tag.get_property("USE_WAVE_PARADE", use_wave_parade);
+                               use_wave_gain = input.tag.get_property("USE_WAVE_GAIN", use_wave_gain);
+                               use_vect_gain = input.tag.get_property("USE_VECT_GAIN", use_vect_gain);
+                               use_smooth = input.tag.get_property("USE_SMOOTH", use_smooth);
                        }
                }
        }
 }
 
-
-
-
 NEW_WINDOW_MACRO(VideoScopeEffect, VideoScopeWindow)
 
-
 int VideoScopeEffect::process_realtime(VFrame *input, VFrame *output)
 {
 
        send_render_gui(input);
-//printf("VideoScopeEffect::process_realtime 1\n");
-       if(input->get_rows()[0] != output->get_rows()[0])
+       if( input->get_rows()[0] != output->get_rows()[0] )
                output->copy_from(input);
        return 1;
 }
 
 void VideoScopeEffect::render_gui(void *input)
 {
-       if(thread)
-       {
-               VideoScopeWindow *window = ((VideoScopeWindow*)thread->window);
-               window->lock_window();
-
-//printf("VideoScopeEffect::process_realtime 1\n");
-               this->input = (VFrame*)input;
-//printf("VideoScopeEffect::process_realtime 1\n");
-               window->process(this->input);
-
-
-               window->unlock_window();
-       }
-}
-
-
-
-
-
-VideoScopePackage::VideoScopePackage()
- : LoadPackage()
-{
-}
-
-
-
-
-
-
-VideoScopeUnit::VideoScopeUnit(VideoScopeEffect *plugin,
-       VideoScopeEngine *server)
- : LoadClient(server)
-{
-       this->plugin = plugin;
-}
-
-
-#define INTENSITY(p) ((unsigned int)(((p)[0]) * 77+ ((p)[1] * 150) + ((p)[2] * 29)) >> 8)
-
-
-static void draw_point(unsigned char **rows, int color_model,
-               int x, int y, int r, int g, int b)
-{
-       switch( color_model ) {
-       case BC_BGR8888: {
-               unsigned char *pixel = rows[y] + x * 4;
-               pixel[0] = b; pixel[1] = g; pixel[2] = r;
-               break;
-       }
-       case BC_BGR888: break;
-       case BC_RGB565: {
-               unsigned char *pixel = rows[y] + x * 2;
-               pixel[0] = (r & 0xf8) | (g >> 5);
-               pixel[1] = ((g & 0xfc) << 5) | (b >> 3);
-               break;
-       }
-       case BC_BGR565: break;
-       case BC_RGB8: break;
-       }
-}
-
-#define VIDEOSCOPE(type, temp_type, max, components, use_yuv) { \
-       for( int i=pkg->row1; i<pkg->row2; ++i ) { \
-               type *in_row = (type*)plugin->input->get_rows()[i]; \
-               for( int j=0; j<w; ++j ) { \
-                       type *in_pixel = in_row + j * components; \
-                       float intensity; /* Analyze pixel */ \
-                       if(use_yuv) intensity = (float)*in_pixel / max; \
-                       float h, s, v; \
-                       temp_type r, g, b; \
-                       if( use_yuv ) { \
-                               if( sizeof(type) == 2 ) { \
-                                       YUV::yuv.yuv_to_rgb_16(r, g, b, \
-                                               in_pixel[0], in_pixel[1], in_pixel[2]); \
-                               } \
-                               else { \
-                                       YUV::yuv.yuv_to_rgb_8(r, g, b, \
-                                               in_pixel[0], in_pixel[1], in_pixel[2]); \
-                               } \
-                       } \
-                       else { \
-                               r = in_pixel[0]; \
-                               g = in_pixel[1]; \
-                               b = in_pixel[2]; \
-                       } \
-                       HSV::rgb_to_hsv((float)r / max, (float)g / max, (float)b / max, \
-                                       h, s, v); \
-/* Calculate waveform */ \
-                       if(parade) { \
-                               int x = j * waveform_w / w / 3; /* red */ \
-                               int y = waveform_h - (int)(((float)r / max - FLOAT_MIN) / \
-                                       (FLOAT_MAX - FLOAT_MIN) * waveform_h); \
-                               if(x >= 0 && x < waveform_w / 3 && y >= 0 && y < waveform_h) \
-                                       draw_point(waveform_rows, waveform_cmodel, x, y, \
-                                               0xff, 0x00, 0x00); \
-                               x = waveform_w / 3 + j * waveform_w / w / 3; /* green */ \
-                               y = waveform_h - (int)(((float)g / max - FLOAT_MIN) / \
-                                       (FLOAT_MAX - FLOAT_MIN) * waveform_h); \
-                               if(x >= waveform_w / 3 && x < waveform_w * 2 / 3 && \
-                                       y >= 0 && y < waveform_h) \
-                                       draw_point(waveform_rows, waveform_cmodel, x, y, \
-                                               0x00, 0xff, 0x00); \
-                               x = waveform_w * 2 / 3 + j * waveform_w / w / 3; /* blue */ \
-                               y = waveform_h - (int)(((float)b / max - FLOAT_MIN) / \
-                                       (FLOAT_MAX - FLOAT_MIN) * waveform_h); \
-                               if(x >= waveform_w * 2 / 3 && x < waveform_w && \
-                                       y >= 0 && y < waveform_h) \
-                                       draw_point(waveform_rows, waveform_cmodel, x, y, \
-                                               0x00, 0x00, 0xff); \
-                       } \
-                       else { \
-                               if(!use_yuv) intensity = v; \
-                               intensity = (intensity - FLOAT_MIN) / (FLOAT_MAX - FLOAT_MIN) * \
-                                       waveform_h; \
-                               int y = waveform_h - (int)intensity; \
-                               int x = j * waveform_w / w; \
-                               if(x >= 0 && x < waveform_w && y >= 0 && y < waveform_h) \
-                                       draw_point(waveform_rows, waveform_cmodel, x, y, \
-                                               0xff, 0xff, 0xff); \
-                       } \
-/* Calculate vectorscope */ \
-                       float adjacent = cos((h + 90) / 360 * 2 * M_PI); \
-                       float opposite = sin((h + 90) / 360 * 2 * M_PI); \
-                       int x = (int)(vector_w / 2 +  \
-                               adjacent * (s - FLOAT_MIN) / (FLOAT_MAX - FLOAT_MIN) * radius); \
-                       int y = (int)(vector_h / 2 -  \
-                               opposite * (s - FLOAT_MIN) / (FLOAT_MAX - FLOAT_MIN) * radius); \
-                       CLAMP(x, 0, vector_w - 1); \
-                       CLAMP(y, 0, vector_h - 1); \
-/* Get color with full saturation & value */ \
-                       float r_f, g_f, b_f; \
-                       HSV::hsv_to_rgb(r_f, g_f, b_f, h, s, 1); \
-                       r = (int)(r_f * 255); \
-                       g = (int)(g_f * 255); \
-                       b = (int)(b_f * 255); \
-                       if(sizeof(type) == 4) { /* float */ \
-                               r = CLIP(r, 0, 0xff); \
-                               g = CLIP(g, 0, 0xff); \
-                               b = CLIP(b, 0, 0xff); \
-                       } \
-                       draw_point(vector_rows, vector_cmodel, x, y, \
-                               (int)r, (int)g, (int)b); \
-               } \
-       } \
-}
-
-void VideoScopeUnit::process_package(LoadPackage *package)
-{
-       VideoScopeWindow *window = (VideoScopeWindow*)plugin->thread->window;
-       VideoScopePackage *pkg = (VideoScopePackage*)package;
-       int w = plugin->input->get_w();
-//     int h = plugin->input->get_h();
-       int waveform_h = window->wave_h;
-       int waveform_w = window->wave_w;
-       int waveform_cmodel = window->waveform_vframe->get_color_model();
-       unsigned char **waveform_rows = window->waveform_vframe->get_rows();
-       int vector_h = window->vector_vframe->get_h();
-       int vector_w = window->vector_vframe->get_w();
-       int vector_cmodel = window->vector_vframe->get_color_model();
-       unsigned char **vector_rows = window->vector_vframe->get_rows();
-       float radius = MIN(vector_w / 2, vector_h / 2);
-       int parade = 1;
-
-       switch( plugin->input->get_color_model() ) {
-       case BC_RGB888:
-               VIDEOSCOPE(unsigned char, int, 0xff, 3, 0)
-               break;
-
-       case BC_RGB_FLOAT:
-               VIDEOSCOPE(float, float, 1, 3, 0)
-               break;
-
-       case BC_YUV888:
-               VIDEOSCOPE(unsigned char, int, 0xff, 3, 1)
-               break;
-
-       case BC_RGB161616:
-               VIDEOSCOPE(uint16_t, int, 0xffff, 3, 0)
-               break;
-
-       case BC_YUV161616:
-               VIDEOSCOPE(uint16_t, int, 0xffff, 3, 1)
-               break;
-
-       case BC_RGBA8888:
-               VIDEOSCOPE(unsigned char, int, 0xff, 4, 0)
-               break;
-
-       case BC_RGBA_FLOAT:
-               VIDEOSCOPE(float, float, 1, 4, 0)
-               break;
-
-       case BC_YUVA8888:
-               VIDEOSCOPE(unsigned char, int, 0xff, 4, 1)
-               break;
-
-       case BC_RGBA16161616:
-               VIDEOSCOPE(uint16_t, int, 0xffff, 4, 0)
-               break;
-
-       case BC_YUVA16161616:
-               VIDEOSCOPE(uint16_t, int, 0xffff, 4, 1)
-               break;
-       }
-}
-
-VideoScopeEngine::VideoScopeEngine(VideoScopeEffect *plugin, int cpus)
- : LoadServer(cpus, cpus)
-{
-       this->plugin = plugin;
-}
-
-VideoScopeEngine::~VideoScopeEngine()
-{
-}
-
-void VideoScopeEngine::init_packages()
-{
-       for(int i = 0; i < LoadServer::get_total_packages(); i++)
-       {
-               VideoScopePackage *pkg = (VideoScopePackage*)get_package(i);
-               pkg->row1 = plugin->input->get_h() * i / LoadServer::get_total_packages();
-               pkg->row2 = plugin->input->get_h() * (i + 1) / LoadServer::get_total_packages();
-       }
-}
-
-
-LoadClient* VideoScopeEngine::new_client()
-{
-       return new VideoScopeUnit(plugin, this);
-}
-
-LoadPackage* VideoScopeEngine::new_package()
-{
-       return new VideoScopePackage;
+       if( !thread ) return;
+       VideoScopeWindow *window = ((VideoScopeWindow*)thread->window);
+       window->lock_window();
+       this->input = (VFrame*)input;
+       window->process(this->input);
+       window->unlock_window();
 }
 
index b8c47879179e40cbd6f98c3b58986f4db7e3a018..08a9a39c8b473df9b28d9019412ba94e38d14a5e 100644 (file)
@@ -8,7 +8,7 @@ msgstr ""
 "Project-Id-Version: Cinelerra 5.1\n"
 "Report-Msgid-Bugs-To: \n"
 "POT-Creation-Date: 2016-10-15 14:02-0600\n"
-"PO-Revision-Date: 2020-03-24 11:04+0100\n"
+"PO-Revision-Date: 2020-03-29 03:06+0200\n"
 "Last-Translator: Sergio Daniel Gomez <sergio.sgsistemas@gmail.com>\n"
 "Language-Team: SPANISH <LL@li.org>\n"
 "Language: es\n"
@@ -2726,12 +2726,12 @@ msgstr "Encoger"
 #: cinelerra/cwindowtool.C:462 plugins/titler/titlerwindow.C:291
 #: plugins/titler/titlerwindow.C:305
 msgid "W:"
-msgstr "W:"
+msgstr "An:"
 
 #: cinelerra/cwindowtool.C:486 plugins/titler/titlerwindow.C:292
 #: plugins/titler/titlerwindow.C:310
 msgid "H:"
-msgstr "H:"
+msgstr "Al:"
 
 #: cinelerra/cwindowtool.C:550
 msgid ": Color"
@@ -3972,11 +3972,11 @@ msgstr "Ajustar todas las automatizaciones a la pantalla ( Alt + f )"
 
 #: cinelerra/editpanel.C:889
 msgid "Drag and drop editing mode"
-msgstr "Herramienta de edición para arrastrar y soltar"
+msgstr "Herramienta de edición para arrastrar y soltar (e)"
 
 #: cinelerra/editpanel.C:909
 msgid "Cut and paste editing mode"
-msgstr "Herramienta de selección"
+msgstr "Herramienta de selección (e)"
 
 #: cinelerra/editpanel.C:930
 msgid "Generate keyframes while tweeking (j)"
@@ -9409,11 +9409,11 @@ msgstr "Nuevo tamaño del proyector:"
 
 #: cinelerra/scale.C:226 cinelerra/scale.C:228 cinelerra/setformat.C:393
 msgid "W Ratio:"
-msgstr "Proporción W:"
+msgstr "Proporción An:"
 
 #: cinelerra/scale.C:232 cinelerra/scale.C:234 cinelerra/setformat.C:402
 msgid "H Ratio:"
-msgstr "Proporción H:"
+msgstr "Proporción Al:"
 
 #: cinelerra/scale.C:343 plugins/scale/scalewin.C:234
 msgid "Constrain ratio"
@@ -11470,11 +11470,11 @@ msgstr "Escena Y:"
 
 #: plugins/findobj/findobjwindow.C:138
 msgid "Scene W:"
-msgstr "Escena W:"
+msgstr "Escena An:"
 
 #: plugins/findobj/findobjwindow.C:148
 msgid "Scene H:"
-msgstr "Escena H:"
+msgstr "Escena Al:"
 
 #: plugins/findobj/findobjwindow.C:159
 msgid "Object X:"
@@ -11486,11 +11486,11 @@ msgstr "Objeto Y:"
 
 #: plugins/findobj/findobjwindow.C:189
 msgid "Object W:"
-msgstr "Objeto W:"
+msgstr "Objeto An:"
 
 #: plugins/findobj/findobjwindow.C:199
 msgid "Object H:"
-msgstr "Objeto H:"
+msgstr "Objeto Al:"
 
 #: plugins/findobj/findobjwindow.C:210
 msgid "Replace X:"
@@ -11502,11 +11502,11 @@ msgstr "Reemplazar Y:"
 
 #: plugins/findobj/findobjwindow.C:240
 msgid "Replace W:"
-msgstr "Reemplazar W:"
+msgstr "Reemplazar An:"
 
 #: plugins/findobj/findobjwindow.C:250
 msgid "Replace H:"
-msgstr "Reemplazar H:"
+msgstr "Reemplazar Al:"
 
 #: plugins/findobj/findobjwindow.C:261
 msgid "Replace DX:"
@@ -12952,11 +12952,11 @@ msgstr "En R:"
 
 #: plugins/scaleratio/scaleratiowin.C:55 plugins/translate/translatewin.C:73
 msgid "In W:"
-msgstr "En W:"
+msgstr "En An:"
 
 #: plugins/scaleratio/scaleratiowin.C:60 plugins/translate/translatewin.C:79
 msgid "In H:"
-msgstr "En H:"
+msgstr "En Al:"
 
 #: plugins/scaleratio/scaleratiowin.C:67
 msgid "Out R:"
@@ -12965,12 +12965,12 @@ msgstr "I Salida D:"
 #: plugins/scaleratio/scaleratiowin.C:72 plugins/svg/svgwin.C:68
 #: plugins/translate/translatewin.C:101
 msgid "Out W:"
-msgstr "Salida W:"
+msgstr "Salida An:"
 
 #: plugins/scaleratio/scaleratiowin.C:77 plugins/svg/svgwin.C:77
 #: plugins/translate/translatewin.C:107
 msgid "Out H:"
-msgstr "Salida H:"
+msgstr "Salida Al:"
 
 #: plugins/scaleratio/scaleratiowin.C:92
 msgid "Src X:"
@@ -12982,11 +12982,11 @@ msgstr "Src Y:"
 
 #: plugins/scaleratio/scaleratiowin.C:103
 msgid "Src W:"
-msgstr "W Src:"
+msgstr "Src An:"
 
 #: plugins/scaleratio/scaleratiowin.C:108
 msgid "Src H:"
-msgstr "Src H:"
+msgstr "Src Al:"
 
 #: plugins/scaleratio/scaleratiowin.C:116
 msgid "Dst X:"
@@ -12998,11 +12998,11 @@ msgstr "Dst Y:"
 
 #: plugins/scaleratio/scaleratiowin.C:126
 msgid "Dst W:"
-msgstr "Dst W:"
+msgstr "Dst An:"
 
 #: plugins/scaleratio/scaleratiowin.C:131
 msgid "Dst H:"
-msgstr "Dst H:"
+msgstr "Dst Al:"
 
 #: plugins/shapewipe/shapewipe.C:92
 msgid "White to Black"
@@ -13722,7 +13722,7 @@ msgstr "Animación:"
 
 #: plugins/titler/titlerwindow.C:324
 msgid "Drop shadow:"
-msgstr "Sombra (Distancia):"
+msgstr "Sombra:"
 
 #: plugins/titler/titlerwindow.C:331
 msgid "Fade in (sec):"