Mixxx

/home/maxime/Projets/Mixxx/1.10/mixxx/src/recording/encoder.h

Go to the documentation of this file.
00001 /****************************************************************************
00002                    encoder.h  - encoder API for mixxx
00003                              -------------------
00004     copyright            : (C) 2009 by Phillip Whelan
00005     copyright            : (C) 2010 by Tobias Rafreider
00006  ***************************************************************************/
00007 
00008 /***************************************************************************
00009  *                                                                         *
00010  *   This program is free software; you can redistribute it and/or modify  *
00011  *   it under the terms of the GNU General Public License as published by  *
00012  *   the Free Software Foundation; either version 2 of the License, or     *
00013  *   (at your option) any later version.                                   *
00014  *                                                                         *
00015  ***************************************************************************/
00016 
00017 #ifndef ENCODER_H
00018 #define ENCODER_H
00019 
00020 #include <stdlib.h> // needed for random num gen
00021 #include <time.h> // needed for random num gen
00022 #include <string.h> // needed for memcpy
00023 #include <QDebug>
00024 
00025 #include "engine/engineabstractrecord.h"
00026 #include "controlobjectthreadmain.h"
00027 #include "controlobject.h"
00028 #include "playerinfo.h"
00029 #include "trackinfoobject.h"
00030 
00031 
00032 class Encoder : public QObject {
00033     Q_OBJECT
00034 
00035   public:
00036     Encoder();
00037     virtual ~Encoder();
00038     /*
00039      * General Encoder methods
00040      */
00041     virtual int initEncoder(int bitrate) = 0;
00042     virtual void encodeBuffer(const CSAMPLE *samples, const int size) = 0;
00043     virtual void updateMetaData(char* artist, char* title, char* album) = 0;
00044     virtual void flush() = 0;
00046     static int convertToBitrate(int quality);
00047 };
00048 
00049 #endif // ENCODER_H
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Defines