mp4tag/mp4properties.h

Go to the documentation of this file.
00001 /***************************************************************************
00002 copyright            : (C) 2005 by Andy Leadbetter
00003 email                : andrew.leadbetter@gmail.com
00004  ***************************************************************************/
00005 
00006 /***************************************************************************
00007  *   This library is free software; you can redistribute it and/or modify  *
00008  *   it  under the terms of the GNU Lesser General Public License version  *
00009  *   2.1 as published by the Free Software Foundation.                     *
00010  *                                                                         *
00011  *   This library is distributed in the hope that it will be useful, but   *
00012  *   WITHOUT ANY WARRANTY; without even the implied warranty of            *
00013  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU     *
00014  *   Lesser General Public License for more details.                       *
00015  *                                                                         *
00016  *   You should have received a copy of the GNU Lesser General Public      *
00017  *   License along with this library; if not, write to the Free Software   *
00018  *   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,            *
00019  *   MA  02110-1301  USA                                                   *
00020  ***************************************************************************/
00021 
00022 #ifndef TAGLIB_MP4PROPERTIES_H
00023 #define TAGLIB_MP4PROPERTIES_H
00024 
00025 #include <audioproperties.h>
00026 #include <tstring.h>
00027 #include <mp4.h>
00028 // mp4.h drags in mp4_config.h that defines these
00029 // get rid of them so they don't conflict with our config.h
00030 #undef VERSION
00031 #undef PACKAGE
00032 
00033 namespace TagLib {
00034 
00035     namespace MP4 {
00036 
00037         class File;
00038 
00044         class Properties : public AudioProperties
00045         {
00046             public:
00050                 Properties(Properties::ReadStyle style);
00051 
00055                 virtual ~Properties();
00056 
00057                 // Reimplementations.
00058 
00059                 virtual int length() const;
00060                 virtual int bitrate() const;
00061                 virtual int sampleRate() const;
00062                 virtual int channels() const;
00063 
00064                 void readMP4Properties(MP4FileHandle mp4File);
00065 
00066 
00067             private:
00068                 void readAudioTrackProperties(MP4FileHandle mp4File, MP4TrackId trackId );
00069                 friend class MP4::File;
00070 
00071                 int m_length;
00072                 int m_bitrate;
00073                 int m_sampleRate;
00074                 int m_channels;
00075 
00076                 Properties(const Properties &);
00077                 Properties &operator=(const Properties &);
00078 
00079                 void read();
00080         };
00081 
00082     }
00083 
00084 }
00085 
00086 #endif

Generated on Mon Aug 6 21:24:20 2007 for plai by  doxygen 1.5.1