summaryrefslogtreecommitdiff
path: root/libs/ardour/session_time.cc
diff options
context:
space:
mode:
authorCarl Hetherington <carl@carlh.net>2009-05-14 00:13:27 +0000
committerCarl Hetherington <carl@carlh.net>2009-05-14 00:13:27 +0000
commit015fc7b39fab97cee1875231694adce43155ceb5 (patch)
tree76dded18cc9441e7325af999358ab3a3235cdb1e /libs/ardour/session_time.cc
parent0569107ddc0d2a8df6ca0a2c8cc16ebe8f3dee99 (diff)
First stage of options rework.
- Split Configuration into RCConfiguration and SessionConfiguration; the first for options which are saved to .rc files and the second for options which are saved in a session file. - Move some options from the old `master' Configuration object into SessionConfiguration; this needs more refinement. - Reflect many RCConfiguration options in an expanded Edit->Preferences dialog; my intention is to remove the corresponding menu items eventually. git-svn-id: svn://localhost/ardour2/branches/3.0@5075 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/session_time.cc')
-rw-r--r--libs/ardour/session_time.cc12
1 files changed, 6 insertions, 6 deletions
diff --git a/libs/ardour/session_time.cc b/libs/ardour/session_time.cc
index 264ce10c82..223c30bd1a 100644
--- a/libs/ardour/session_time.cc
+++ b/libs/ardour/session_time.cc
@@ -52,7 +52,7 @@ Session::bbt_time (nframes_t when, BBT_Time& bbt)
float
Session::smpte_frames_per_second() const
{
- switch (Config->get_smpte_format()) {
+ switch (config.get_smpte_format()) {
case smpte_23976:
return 23.976;
@@ -101,7 +101,7 @@ Session::smpte_frames_per_second() const
bool
Session::smpte_drop_frames() const
{
- switch (Config->get_smpte_format()) {
+ switch (config.get_smpte_format()) {
case smpte_23976:
return false;
@@ -185,7 +185,7 @@ int
Session::set_smpte_format (SmpteFormat format)
{
/* this will trigger any other changes needed */
- Config->set_smpte_format (format);
+ config.set_smpte_format (format);
return 0;
}
@@ -272,7 +272,7 @@ Session::smpte_to_sample( SMPTE::Time& smpte, nframes_t& sample, bool use_offset
}
if (use_subframes) {
- sample += (long) (((double)smpte.subframes * _frames_per_smpte_frame) / Config->get_subframes_per_frame());
+ sample += (long) (((double)smpte.subframes * _frames_per_smpte_frame) / config.get_subframes_per_frame());
}
if (use_offset) {
@@ -334,10 +334,10 @@ Session::sample_to_smpte( nframes_t sample, SMPTE::Time& smpte, bool use_offset,
// Calculate exact number of (exceeding) smpte frames and fractional frames
smpte_frames_left_exact = (double) offset_sample / _frames_per_smpte_frame;
smpte_frames_fraction = smpte_frames_left_exact - floor( smpte_frames_left_exact );
- smpte.subframes = (long) rint(smpte_frames_fraction * Config->get_subframes_per_frame());
+ smpte.subframes = (long) rint(smpte_frames_fraction * config.get_subframes_per_frame());
// XXX Not sure if this is necessary anymore...
- if (smpte.subframes == Config->get_subframes_per_frame()) {
+ if (smpte.subframes == config.get_subframes_per_frame()) {
// This can happen with 24 fps (and 29.97 fps ?)
smpte_frames_left_exact = ceil( smpte_frames_left_exact );
smpte.subframes = 0;