Remove Complex.h from WTF
authorandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 12 May 2013 21:27:43 +0000 (21:27 +0000)
committerandersca@apple.com <andersca@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 12 May 2013 21:27:43 +0000 (21:27 +0000)
commita8ad8ffc3a6a08340f8c753acaa02fa79c158403
tree2132bf0c442bb77df7f427641f05b5d927e46feb
parent969731580045bb151beb7de0e42b666714abe3e0
Remove Complex.h from WTF
https://bugs.webkit.org/show_bug.cgi?id=115989

Reviewed by Beth Dakin.

Source/WebCore:

Replace Complex declarations with std::complex<double>. Pass by value since the struct
is small enough to go into two registers on X86-64.

* Modules/webaudio/RealtimeAnalyser.cpp:
(WebCore::RealtimeAnalyser::doFFTAnalysis):
(WebCore::RealtimeAnalyser::getFloatFrequencyData):
(WebCore::RealtimeAnalyser::getByteFrequencyData):
(WebCore::RealtimeAnalyser::getByteTimeDomainData):
* platform/audio/Biquad.cpp:
(WebCore::Biquad::setZeroPolePairs):
(WebCore::Biquad::setAllpassPole):
(WebCore::Biquad::getFrequencyResponse):
* platform/audio/Biquad.h:
* platform/audio/FFTFrame.cpp:
(WebCore::FFTFrame::interpolateFrequencyComponents):
(WebCore::FFTFrame::extractAverageGroupDelay):
(WebCore::FFTFrame::addConstantGroupDelay):

Source/WTF:

Complex.h contains a typedef and a single function (that already has an equivalent in the STL).
The header is used by three files in WebCore, so just use std::complex<double> and std::polar directly.

* GNUmakefile.list.am:
* WTF.vcproj/WTF.vcproj:
* WTF.vcxproj/WTF.vcxproj:
* WTF.vcxproj/WTF.vcxproj.filters:
* WTF.xcodeproj/project.pbxproj:
* wtf/CMakeLists.txt:
* wtf/Complex.h: Removed.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@149970 268f45cc-cd09-0410-ab3c-d52691b4dbfc
13 files changed:
Source/WTF/ChangeLog
Source/WTF/GNUmakefile.list.am
Source/WTF/WTF.vcproj/WTF.vcproj
Source/WTF/WTF.vcxproj/WTF.vcxproj
Source/WTF/WTF.vcxproj/WTF.vcxproj.filters
Source/WTF/WTF.xcodeproj/project.pbxproj
Source/WTF/wtf/CMakeLists.txt
Source/WTF/wtf/Complex.h [deleted file]
Source/WebCore/ChangeLog
Source/WebCore/Modules/webaudio/RealtimeAnalyser.cpp
Source/WebCore/platform/audio/Biquad.cpp
Source/WebCore/platform/audio/Biquad.h
Source/WebCore/platform/audio/FFTFrame.cpp