From 0c21a7a0d5b84dc6726462f0fbe51b8c32433262 Mon Sep 17 00:00:00 2001 From: Michael Krelin Date: Fri, 11 Aug 2006 16:01:56 +0000 Subject: initial commit into repository --- (limited to 'include/midillo/MTrk.h') diff --git a/include/midillo/MTrk.h b/include/midillo/MTrk.h new file mode 100644 index 0000000..0884388 --- a/dev/null +++ b/include/midillo/MTrk.h @@ -0,0 +1,54 @@ +#ifndef __MIDILLO_MTRK_H +#define __MIDILLO_MTRK_H + +#include +#include +#include +#include +#include + +/** + * @file + * @brief MTrk -- track chunk container + */ + +namespace midillo { + using std::istream; + using std::ostream; + + /** + * MTrk track chunk container class + */ + class MTrk_t : public chunk_t { + public: + /** + * MIDI events contained in the track + */ + events_t events; + + /** + * Load MTrk chunk from the stream + * @param s input stream + */ + void load(istream& s); + + /** + * Save MTrk chunk to the stream + * @param s output stream + */ + void save(ostream& s) const; + + /** + * Dump textual representation of MTrk chunk to stream + * @param s output stream + */ + void dump(ostream& s) const; + }; + + inline ostream& operator<<(ostream& s,const MTrk_t& mtrk) { + mtrk.dump(s); return s; + } + +} + +#endif /* __MIDILLO_MTRK_H */ -- cgit v0.9.0.2