summaryrefslogtreecommitdiff
path: root/libs/ardour/ardour/slave.h
diff options
context:
space:
mode:
authorRobin Gareus <robin@gareus.org>2012-10-20 18:14:13 +0000
committerRobin Gareus <robin@gareus.org>2012-10-20 18:14:13 +0000
commit7f8d2e32da0f97c519219bb1869f5ca24a62e318 (patch)
tree0e620c4715daa469423a3928a6a637516e4f410e /libs/ardour/ardour/slave.h
parent2d9ed69fe2f8f35d81bb9bc33c8f4fa8393dd00a (diff)
LTC slave rewrite #2
git-svn-id: svn://localhost/ardour2/branches/3.0@13313 d708f5d6-7413-0410-9779-e7cbd77b26cf
Diffstat (limited to 'libs/ardour/ardour/slave.h')
-rw-r--r--libs/ardour/ardour/slave.h64
1 files changed, 24 insertions, 40 deletions
diff --git a/libs/ardour/ardour/slave.h b/libs/ardour/ardour/slave.h
index 8589473d3b..07e3fd0e1d 100644
--- a/libs/ardour/ardour/slave.h
+++ b/libs/ardour/ardour/slave.h
@@ -342,63 +342,47 @@ public:
framecnt_t resolution () const;
bool requires_seekahead () const { return false; }
framecnt_t seekahead_distance() const;
- bool give_slave_full_control_over_transport_speed() const;
+ bool give_slave_full_control_over_transport_speed() const { return true; }
- Timecode::TimecodeFormat apparent_timecode_format() const;
- std::string approximate_current_position() const;
+ Timecode::TimecodeFormat apparent_timecode_format() const;
+ std::string approximate_current_position() const;
std::string approximate_current_delta() const;
private:
- int parse_ltc(const jack_nframes_t, const jack_default_audio_sample_t * const, const framecnt_t);
- bool process_ltc(framepos_t const, framepos_t const, framecnt_t);
- void init_ltc_dll(framepos_t const, double const);
- void init_engine_dll (framepos_t, framepos_t);
+ void parse_ltc(const jack_nframes_t, const jack_default_audio_sample_t * const, const framecnt_t);
+ void process_ltc(framepos_t const);
+ void init_engine_dll (framepos_t, int32_t);
bool detect_ltc_fps(int, bool);
- bool detect_ltc_discontinuity(LTCFrameExt *);
void reset();
- Session& session;
- bool did_reset_tc_format;
+ Session& session;
+ bool did_reset_tc_format;
Timecode::TimecodeFormat saved_tc_format;
- LTCDecoder *decoder;
+ LTCDecoder * decoder;
+ double frames_per_ltc_frame;
Timecode::Time timecode;
- double frames_per_ltc_frame;
- bool ltc_discontinuity;
-
- framecnt_t monotonic_cnt;
- framecnt_t last_timestamp;
- framecnt_t last_ltc_frame;
- framepos_t ltc_transport_pos;
- double ltc_speed;
- frameoffset_t current_delta;
-
- int ltc_detect_fps_cnt;
- int ltc_detect_fps_max;
- Timecode::TimecodeFormat ltc_timecode;
- Timecode::TimecodeFormat a3e_timecode;
- bool printed_timecode_warning;
- LTCFrame prev_ltc_frame;
- uint64_t frames_in_sequence;
- int delayedlocked;
+ framecnt_t monotonic_cnt;
+ framecnt_t last_timestamp;
+ framecnt_t last_ltc_frame;
+ double ltc_speed;
+ frameoffset_t current_delta;
+ int delayedlocked;
+ int ltc_detect_fps_cnt;
+ int ltc_detect_fps_max;
+ bool printed_timecode_warning;
+ Timecode::TimecodeFormat ltc_timecode;
+ Timecode::TimecodeFormat a3e_timecode;
/* DLL - chase LTC */
+ int transport_direction;
+ int engine_dll_initstate;
double t0; ///< time at the beginning of the MTC quater frame
double t1; ///< calculated end of the MTC quater frame
double e2; ///< second order loop error
- double b, c, omega; ///< DLL filter coefficients
-
- /* DLL - sync engine */
- int transport_direction;
- int engine_dll_initstate;
- double te0; ///< time at the beginning of the engine process
- double te1; ///< calculated sync time
- double ee2; ///< second order loop error
- double be, ce, oe; ///< DLL filter coefficients
-
-
+ double b, c; ///< DLL filter coefficients
};
#endif