TagLib 1.7.0 (TagLib: wavpackproperties.h Source File)

wavpackproperties.h
Go to the documentation of this file.
00001 /***************************************************************************
00002     copyright            : (C) 2006 by Lukáš Lalinský
00003     email                : lalinsky@gmail.com
00004 
00005     copyright            : (C) 2004 by Allan Sandfeld Jensen
00006     email                : kde@carewolf.org
00007                            (original MPC implementation)
00008  ***************************************************************************/
00009 
00010 /***************************************************************************
00011  *   This library is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU Lesser General Public License version   *
00013  *   2.1 as published by the Free Software Foundation.                     *
00014  *                                                                         *
00015  *   This library is distributed in the hope that it will be useful, but   *
00016  *   WITHOUT ANY WARRANTY; without even the implied warranty of            *
00017  *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU     *
00018  *   Lesser General Public License for more details.                       *
00019  *                                                                         *
00020  *   You should have received a copy of the GNU Lesser General Public      *
00021  *   License along with this library; if not, write to the Free Software   *
00022  *   Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA         *
00023  *   02110-1301  USA                                                       *
00024  *                                                                         *
00025  *   Alternatively, this file is available under the Mozilla Public        *
00026  *   License Version 1.1.  You may obtain a copy of the License at         *
00027  *   http://www.mozilla.org/MPL/                                           *
00028  ***************************************************************************/
00029 
00030 #ifndef TAGLIB_WVPROPERTIES_H
00031 #define TAGLIB_WVPROPERTIES_H
00032 
00033 #include "taglib_export.h"
00034 #include "audioproperties.h"
00035 
00036 namespace TagLib {
00037 
00038   namespace WavPack {
00039 
00040     class File;
00041 
00042     static const uint HeaderSize = 32;
00043 
00045 
00051     class TAGLIB_EXPORT Properties : public AudioProperties
00052     {
00053     public:
00061       Properties(const ByteVector &data, long streamLength, ReadStyle style = Average);
00062 
00066       // BIC: merge with the above constructor
00067       Properties(File *file, long streamLength, ReadStyle style = Average);
00068 
00072       virtual ~Properties();
00073 
00074       // Reimplementations.
00075 
00076       virtual int length() const;
00077       virtual int bitrate() const;
00078       virtual int sampleRate() const;
00079       virtual int channels() const;
00080 
00084       int bitsPerSample() const;
00085 
00089       int version() const;
00090 
00091     private:
00092       Properties(const Properties &);
00093       Properties &operator=(const Properties &);
00094 
00095       void read();
00096       unsigned int seekFinalIndex();
00097 
00098       class PropertiesPrivate;
00099       PropertiesPrivate *d;
00100     };
00101   }
00102 }
00103 
00104 #endif