add GPROFILE scons option; fix spectacular CPU usage sawtooth caused by constant redraw of entire rects when their bounds change
git-svn-id: svn://localhost/ardour2/trunk@1576 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
84af9f18eb
commit
3a716d2b90
@ -44,6 +44,7 @@ opts.AddOptions(
|
|||||||
BoolOption('UNIVERSAL', 'Compile as universal binary. Requires that external libraries are already universal.', 0),
|
BoolOption('UNIVERSAL', 'Compile as universal binary. Requires that external libraries are already universal.', 0),
|
||||||
BoolOption('VERSIONED', 'Add revision information to ardour/gtk executable name inside the build directory', 0),
|
BoolOption('VERSIONED', 'Add revision information to ardour/gtk executable name inside the build directory', 0),
|
||||||
BoolOption('VST', 'Compile with support for VST', 0),
|
BoolOption('VST', 'Compile with support for VST', 0),
|
||||||
|
BoolOption('GPROFILE', 'Compile with support for gprofile (Developers only)', 0),
|
||||||
BoolOption('TRANZPORT', 'Compile with support for Frontier Designs (if libusb is available)', 1)
|
BoolOption('TRANZPORT', 'Compile with support for Frontier Designs (if libusb is available)', 1)
|
||||||
)
|
)
|
||||||
|
|
||||||
@ -531,6 +532,9 @@ env = conf.Finish()
|
|||||||
#
|
#
|
||||||
|
|
||||||
opt_flags = []
|
opt_flags = []
|
||||||
|
if env['GPROFILE'] == 1:
|
||||||
|
debug_flags = [ '-g', '-pg' ]
|
||||||
|
else:
|
||||||
debug_flags = [ '-g' ]
|
debug_flags = [ '-g' ]
|
||||||
|
|
||||||
# guess at the platform, used to define compiler flags
|
# guess at the platform, used to define compiler flags
|
||||||
|
@ -153,7 +153,7 @@ ARDOUR_UI::connect_to_session (Session *s)
|
|||||||
|
|
||||||
second_connection = Glib::signal_timeout().connect (mem_fun(*this, &ARDOUR_UI::every_second), 1000);
|
second_connection = Glib::signal_timeout().connect (mem_fun(*this, &ARDOUR_UI::every_second), 1000);
|
||||||
point_one_second_connection = Glib::signal_timeout().connect (mem_fun(*this, &ARDOUR_UI::every_point_one_seconds), 100);
|
point_one_second_connection = Glib::signal_timeout().connect (mem_fun(*this, &ARDOUR_UI::every_point_one_seconds), 100);
|
||||||
// point_oh_five_second_connection = Glib::signal_timeout().connect (mem_fun(*this, &ARDOUR_UI::every_point_oh_five_seconds), 50);
|
point_oh_five_second_connection = Glib::signal_timeout().connect (mem_fun(*this, &ARDOUR_UI::every_point_oh_five_seconds), 50);
|
||||||
point_zero_one_second_connection = Glib::signal_timeout().connect (mem_fun(*this, &ARDOUR_UI::every_point_zero_one_seconds), 40);
|
point_zero_one_second_connection = Glib::signal_timeout().connect (mem_fun(*this, &ARDOUR_UI::every_point_zero_one_seconds), 40);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -526,7 +526,7 @@ AudioStreamView::setup_rec_box ()
|
|||||||
rec_rects.push_back (recbox);
|
rec_rects.push_back (recbox);
|
||||||
|
|
||||||
screen_update_connection.disconnect();
|
screen_update_connection.disconnect();
|
||||||
screen_update_connection = ARDOUR_UI::instance()->SuperRapidScreenUpdate.connect (mem_fun (*this, &AudioStreamView::update_rec_box));
|
screen_update_connection = ARDOUR_UI::instance()->MidRapidScreenUpdate.connect (mem_fun (*this, &AudioStreamView::update_rec_box));
|
||||||
rec_updating = true;
|
rec_updating = true;
|
||||||
rec_active = true;
|
rec_active = true;
|
||||||
|
|
||||||
|
@ -264,11 +264,17 @@ gnome_canvas_simplerect_reset_bounds (GnomeCanvasItem *item)
|
|||||||
double x1, x2, y1, y2;
|
double x1, x2, y1, y2;
|
||||||
double old_x1, old_x2, old_y1, old_y2;
|
double old_x1, old_x2, old_y1, old_y2;
|
||||||
double a, b, c, d;
|
double a, b, c, d;
|
||||||
|
ArtIRect intersection, old, new;
|
||||||
|
|
||||||
old_x1 = item->x1;
|
old.x0 = old_x1 = item->x1;
|
||||||
old_y1 = item->y1;
|
old.y0 = old_y1 = item->y1;
|
||||||
old_x2 = item->x2;
|
old.x1 = old_x2 = item->x2;
|
||||||
old_y2 = item->y2;
|
old.y1 = old_y2 = item->y2;
|
||||||
|
|
||||||
|
new.x0 = x1;
|
||||||
|
new.y0 = y1;
|
||||||
|
new.x1 = x2;
|
||||||
|
new.y1 = y2;
|
||||||
|
|
||||||
gnome_canvas_simplerect_bounds (item, &x1, &y1, &x2, &y2);
|
gnome_canvas_simplerect_bounds (item, &x1, &y1, &x2, &y2);
|
||||||
gnome_canvas_item_i2w (item, &x1, &y1);
|
gnome_canvas_item_i2w (item, &x1, &y1);
|
||||||
@ -288,6 +294,8 @@ gnome_canvas_simplerect_reset_bounds (GnomeCanvasItem *item)
|
|||||||
|
|
||||||
/* now queue redraws for changed areas */
|
/* now queue redraws for changed areas */
|
||||||
|
|
||||||
|
art_irect_intersect (&intersection, &old, &new);
|
||||||
|
#if 0
|
||||||
a = MIN(item->x1, old_x1);
|
a = MIN(item->x1, old_x1);
|
||||||
b = MAX(item->x1, old_x1);
|
b = MAX(item->x1, old_x1);
|
||||||
|
|
||||||
@ -304,7 +312,15 @@ gnome_canvas_simplerect_reset_bounds (GnomeCanvasItem *item)
|
|||||||
d = MAX(d,item->y2);
|
d = MAX(d,item->y2);
|
||||||
d = MAX(d, old_y2);
|
d = MAX(d, old_y2);
|
||||||
|
|
||||||
|
fprintf (stderr, "%p REDRAW %g,%g %g,%g\n", simplerect, a, c, b + 0.5, d + 0.5);
|
||||||
gnome_canvas_request_redraw (item->canvas, a, c, b + 0.5, d + 0.5);
|
gnome_canvas_request_redraw (item->canvas, a, c, b + 0.5, d + 0.5);
|
||||||
|
#else
|
||||||
|
gnome_canvas_request_redraw (item->canvas,
|
||||||
|
intersection.x0,
|
||||||
|
intersection.y0,
|
||||||
|
intersection.x1,
|
||||||
|
intersection.y1);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
Reference in New Issue
Block a user