1 /***************************************************************************
2 * Copyright (C) 2010 by Simon Andreas Eugster (simon.eu@gmail.com) *
3 * This file is part of kdenlive. See www.kdenlive.org. *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU General Public License as published by *
7 * the Free Software Foundation; either version 2 of the License, or *
8 * (at your option) any later version. *
9 ***************************************************************************/
16 #include "abstractaudioscopewidget.h"
17 #include "ui_spectrogram_ui.h"
21 class Spectrogram : public AbstractAudioScopeWidget {
25 Spectrogram(QWidget *parent = 0);
28 QString widgetName() const;
31 ///// Implemented methods /////
33 QImage renderHUD(uint accelerationFactor);
34 QImage renderAudioScope(uint accelerationFactor, const QVector<int16_t> audioFrame, const int freq, const int num_channels, const int num_samples);
35 QImage renderBackground(uint accelerationFactor);
36 bool isHUDDependingOnInput() const;
37 bool isScopeDependingOnInput() const;
38 bool isBackgroundDependingOnInput() const;
39 virtual void readConfig();
43 Ui::Spectrogram_UI *ui;
46 QList<QVector<float> > m_fftHistory;
47 QImage m_fftHistoryImg;
55 QRect m_innerScopeRect;
58 #endif // SPECTROGRAM_H