From e793fbf211b03b55ef3ff93863fe3cfd7e15ba35 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Fri, 9 Nov 2012 14:43:08 +0000 Subject: [PATCH] merge -r 13409:13412 svn+ssh://ardoursvn@subversion.ardour.org/ardour2/branches/3.0 git-svn-id: svn://localhost/ardour2/branches/3.0-SG@13413 d708f5d6-7413-0410-9779-e7cbd77b26cf --- gtk2_ardour/ardour_ui.cc | 2 +- libs/ardour/ltc_slave.cc | 20 ++++++++++++-------- libs/ardour/mtc_slave.cc | 20 ++++++++++++-------- libs/timecode/src/time.cc | 10 ++-------- tools/osx_packaging/osx_build | 2 +- 5 files changed, 28 insertions(+), 26 deletions(-) diff --git a/gtk2_ardour/ardour_ui.cc b/gtk2_ardour/ardour_ui.cc index af076a33cc..5b538bf411 100644 --- a/gtk2_ardour/ardour_ui.cc +++ b/gtk2_ardour/ardour_ui.cc @@ -1093,7 +1093,7 @@ ARDOUR_UI::update_timecode_format () matching = true; } - snprintf (buf, sizeof (buf), S_("Timecode|TC: %sfps"), + snprintf (buf, sizeof (buf), S_("Timecode|TC: %s"), matching ? X_("green") : X_("red"), Timecode::timecode_format_name (_session->config.get_timecode_format()).c_str()); } else { diff --git a/libs/ardour/ltc_slave.cc b/libs/ardour/ltc_slave.cc index d52a70cab5..f28770b175 100644 --- a/libs/ardour/ltc_slave.cc +++ b/libs/ardour/ltc_slave.cc @@ -240,10 +240,12 @@ LTC_Slave::detect_ltc_fps(int frameno, bool df) did_reset_tc_format = true; } if (cur_timecode != tc_format) { - warning << string_compose(_("Session framerate adjusted from %1 to LTC's %2."), - Timecode::timecode_format_name(cur_timecode), - Timecode::timecode_format_name(tc_format)) - << endmsg; + if (ceil(Timecode::timecode_to_frames_per_second(cur_timecode)) != ceil(Timecode::timecode_to_frames_per_second(tc_format))) { + warning << string_compose(_("Session framerate adjusted from %1 to LTC's %2."), + Timecode::timecode_format_name(cur_timecode), + Timecode::timecode_format_name(tc_format)) + << endmsg; + } session.config.set_timecode_format (tc_format); } } else { @@ -252,10 +254,12 @@ LTC_Slave::detect_ltc_fps(int frameno, bool df) if (a3e_timecode != cur_timecode) printed_timecode_warning = false; if (cur_timecode != tc_format && ! printed_timecode_warning) { - warning << string_compose(_("Session and LTC framerate mismatch: LTC:%1 Session:%2."), - Timecode::timecode_format_name(tc_format), - Timecode::timecode_format_name(cur_timecode)) - << endmsg; + if (ceil(Timecode::timecode_to_frames_per_second(cur_timecode)) != ceil(Timecode::timecode_to_frames_per_second(tc_format))) { + warning << string_compose(_("Session and LTC framerate mismatch: LTC:%1 Session:%2."), + Timecode::timecode_format_name(tc_format), + Timecode::timecode_format_name(cur_timecode)) + << endmsg; + } printed_timecode_warning = true; } } diff --git a/libs/ardour/mtc_slave.cc b/libs/ardour/mtc_slave.cc index 947de39486..d7ec6eb24e 100644 --- a/libs/ardour/mtc_slave.cc +++ b/libs/ardour/mtc_slave.cc @@ -351,10 +351,12 @@ MTC_Slave::update_mtc_time (const byte *msg, bool was_full, framepos_t now) did_reset_tc_format = true; } if (cur_timecode != tc_format) { - warning << string_compose(_("Session framerate adjusted from %1 TO: MTC's %2."), - Timecode::timecode_format_name(cur_timecode), - Timecode::timecode_format_name(tc_format)) - << endmsg; + if (ceil(Timecode::timecode_to_frames_per_second(cur_timecode)) != ceil(Timecode::timecode_to_frames_per_second(tc_format))) { + warning << string_compose(_("Session framerate adjusted from %1 TO: MTC's %2."), + Timecode::timecode_format_name(cur_timecode), + Timecode::timecode_format_name(tc_format)) + << endmsg; + } } session.config.set_timecode_format (tc_format); } else { @@ -363,10 +365,12 @@ MTC_Slave::update_mtc_time (const byte *msg, bool was_full, framepos_t now) if (a3e_timecode != cur_timecode) printed_timecode_warning = false; if (cur_timecode != tc_format && ! printed_timecode_warning) { - warning << string_compose(_("Session and MTC framerate mismatch: MTC:%1 Ardour:%2."), - Timecode::timecode_format_name(tc_format), - Timecode::timecode_format_name(cur_timecode)) - << endmsg; + if (ceil(Timecode::timecode_to_frames_per_second(cur_timecode)) != ceil(Timecode::timecode_to_frames_per_second(tc_format))) { + warning << string_compose(_("Session and MTC framerate mismatch: MTC:%1 Ardour:%2."), + Timecode::timecode_format_name(tc_format), + Timecode::timecode_format_name(cur_timecode)) + << endmsg; + } printed_timecode_warning = true; } } diff --git a/libs/timecode/src/time.cc b/libs/timecode/src/time.cc index 2d41d9b622..4609fbea87 100644 --- a/libs/timecode/src/time.cc +++ b/libs/timecode/src/time.cc @@ -563,21 +563,15 @@ timecode_format_name (TimecodeFormat const t) return "25"; break; + case timecode_2997000: case timecode_2997: return "29.97"; break; + case timecode_2997000drop: case timecode_2997drop: return "29.97 drop"; - break; - case timecode_2997000: - return "29.97000"; - - break; - case timecode_2997000drop: - return "29.97000 drop"; - break; case timecode_30: return "30"; diff --git a/tools/osx_packaging/osx_build b/tools/osx_packaging/osx_build index f8aef0ce06..7f21534623 100755 --- a/tools/osx_packaging/osx_build +++ b/tools/osx_packaging/osx_build @@ -344,7 +344,7 @@ cp ../../gtk2_ardour/mixer.bindings $Resources cp ../../gtk2_ardour/step_editing.bindings $Resources cp $BUILD_ROOT/gtk2_ardour/ardour.menus $Resources -# cp $BUILD_ROOT/ardour_system.rc $Resources/ardour_system.rc +cp ../../ardour_system.rc $Resources/ardour_system.rc cp ../../instant.xml $Resources/instant.xml cp ../../gtk2_ardour/ardour3_ui_default.conf $Resources cp ../../gtk2_ardour/ardour3_ui_default.conf $Resources/ardour3_ui.conf