// tonalisa - software to look at overtone-structures
// Copyright (C) 2016 Dominik Schmidt-Philipp
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, either version 3 of the License, or
// (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see .
//
import QtQuick 2.3
Item {
id: root
width:500; height:70
property string file: activeAudioFile.path
property var pixelSamples: []
property var realSamples: activeAudioFile.samples;
property int nSamples: 0
onRealSamplesChanged: {
var max;
var min;
nSamples = realSamples.length
var samplesPerPixel = nSamples / width
for ( var i=width; i>0; --i ) {
min=0;max=0;
for ( var j=0; j 0 )
select1=mouse.x
else select1=1
}
onPositionChanged: {
if ( mouse.x > 0 )
select1=mouse.x
else select1=1
activeAudioFile.calculateFFT()
}
onReleased: {
activeAudioFile.calculateFFT()
}
}
}
}