Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
Institute of Technical Acoustics (ITA)
VACore
Commits
0a71acec
Commit
0a71acec
authored
Sep 12, 2018
by
Dipl.-Ing. Jonas Stienen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Adapting changes in ITABase convering enumerations of modes etc
parent
4d344b64
Changes
13
Hide whitespace changes
Inline
Side-by-side
Showing
13 changed files
with
48 additions
and
49 deletions
+48
-49
src/Audiosignals/VAMachineSignalSource.cpp
src/Audiosignals/VAMachineSignalSource.cpp
+1
-1
src/Rendering/Binaural/AirTrafficNoise/VAAirTrafficNoiseAudioRenderer.cpp
...naural/AirTrafficNoise/VAAirTrafficNoiseAudioRenderer.cpp
+8
-8
src/Rendering/Binaural/ArtificialReverb/VABinauralArtificialReverb.cpp
.../Binaural/ArtificialReverb/VABinauralArtificialReverb.cpp
+5
-6
src/Rendering/Binaural/FreeField/VABinauralFreeFieldAudioRenderer.cpp
...g/Binaural/FreeField/VABinauralFreeFieldAudioRenderer.cpp
+4
-4
src/Rendering/Binaural/OutdoorNoise/VABinauralOutdoorNoiseAudioRenderer.cpp
...ural/OutdoorNoise/VABinauralOutdoorNoiseAudioRenderer.cpp
+4
-4
src/Rendering/Binaural/RoomAcoustics/VARoomAcousticsAudioRenderer.cpp
...g/Binaural/RoomAcoustics/VARoomAcousticsAudioRenderer.cpp
+6
-6
src/Rendering/Prototyping/FreeField/VAPrototypeFreeFieldAudioRenderer.cpp
...ototyping/FreeField/VAPrototypeFreeFieldAudioRenderer.cpp
+1
-1
src/Rendering/Prototyping/GenericPath/VAPTGenericPathAudioRenderer.cpp
.../Prototyping/GenericPath/VAPTGenericPathAudioRenderer.cpp
+2
-2
src/Rendering/Prototyping/HearingAid/VAPTHearingAidRenderer.cpp
...ndering/Prototyping/HearingAid/VAPTHearingAidRenderer.cpp
+8
-8
src/Reproduction/Binaural/VAAmbisonicsBinauralMixdownReproduction.cpp
...tion/Binaural/VAAmbisonicsBinauralMixdownReproduction.cpp
+2
-2
src/Reproduction/Binaural/VABinauralMixdownReproduction.cpp
src/Reproduction/Binaural/VABinauralMixdownReproduction.cpp
+2
-2
src/Reproduction/Binaural/VAHeadphonesReproduction.cpp
src/Reproduction/Binaural/VAHeadphonesReproduction.cpp
+4
-4
src/Reproduction/Binaural/VANCTCReproduction.cpp
src/Reproduction/Binaural/VANCTCReproduction.cpp
+1
-1
No files found.
src/Audiosignals/VAMachineSignalSource.cpp
View file @
0a71acec
...
...
@@ -183,7 +183,7 @@ const float* CVAMachineSignalSource::GetStreamBlock( const CVAAudiostreamState*
if
(
m_bCrossfadeSounds
)
{
// Fade in stopping sample buffer
m_sbOut
.
Crossfade
(
sbOutTemp
,
0
,
iSamplesWritten
,
ITA
_FADE_IN
,
ITASampleBuffer
::
COSINE_SQUARE
);
m_sbOut
.
Crossfade
(
sbOutTemp
,
0
,
iSamplesWritten
,
ITA
Base
::
CrossfadeDirection
::
FROM_SOURCE
,
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
}
else
{
...
...
src/Rendering/Binaural/AirTrafficNoise/VAAirTrafficNoiseAudioRenderer.cpp
View file @
0a71acec
...
...
@@ -873,11 +873,11 @@ void CVABinauralAirTrafficNoiseAudioRenderer::ProcessStream( const ITAStreamInfo
pPath
->
oRefSoundPath
.
pThirdOctaveFilterBank
->
Process
(
ctxAudio
.
m_sbTempBufR
.
data
(),
ctxAudio
.
m_sbTempBufR
.
data
()
);
// inplace
pPath
->
oDirSoundPath
.
pFIRConvolverChL
->
Process
(
ctxAudio
.
m_sbTempBufD
.
data
(),
(
*
pPath
->
pSoundReceiver
->
psfOutput
)[
0
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
oRefSoundPath
.
pFIRConvolverChL
->
Process
(
ctxAudio
.
m_sbTempBufR
.
data
(),
(
*
pPath
->
pSoundReceiver
->
psfOutput
)[
0
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
oDirSoundPath
.
pFIRConvolverChL
->
Process
(
ctxAudio
.
m_sbTempBufD
.
data
(),
(
*
pPath
->
pSoundReceiver
->
psfOutput
)[
0
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
pPath
->
oRefSoundPath
.
pFIRConvolverChL
->
Process
(
ctxAudio
.
m_sbTempBufR
.
data
(),
(
*
pPath
->
pSoundReceiver
->
psfOutput
)[
0
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
pPath
->
oDirSoundPath
.
pFIRConvolverChR
->
Process
(
ctxAudio
.
m_sbTempBufD
.
data
(),
(
*
pPath
->
pSoundReceiver
->
psfOutput
)[
1
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
oRefSoundPath
.
pFIRConvolverChR
->
Process
(
ctxAudio
.
m_sbTempBufR
.
data
(),
(
*
pPath
->
pSoundReceiver
->
psfOutput
)[
1
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
oDirSoundPath
.
pFIRConvolverChR
->
Process
(
ctxAudio
.
m_sbTempBufD
.
data
(),
(
*
pPath
->
pSoundReceiver
->
psfOutput
)[
1
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
pPath
->
oRefSoundPath
.
pFIRConvolverChR
->
Process
(
ctxAudio
.
m_sbTempBufR
.
data
(),
(
*
pPath
->
pSoundReceiver
->
psfOutput
)[
1
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
spit
++
;
}
...
...
@@ -1259,10 +1259,10 @@ CVABATNSoundPath::CVABATNSoundPath( double dSamplerate, int iBlocklength, int iH
oRefSoundPath
.
pFIRConvolverChL
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
oDirSoundPath
.
pFIRConvolverChR
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
oRefSoundPath
.
pFIRConvolverChR
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
oDirSoundPath
.
pFIRConvolverChL
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
oRefSoundPath
.
pFIRConvolverChL
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
oDirSoundPath
.
pFIRConvolverChR
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
oRefSoundPath
.
pFIRConvolverChR
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
oDirSoundPath
.
pFIRConvolverChL
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
oRefSoundPath
.
pFIRConvolverChL
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
oDirSoundPath
.
pFIRConvolverChR
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
oRefSoundPath
.
pFIRConvolverChR
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
oDirSoundPath
.
pFIRConvolverChL
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
oRefSoundPath
.
pFIRConvolverChL
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
oDirSoundPath
.
pFIRConvolverChR
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
...
...
src/Rendering/Binaural/ArtificialReverb/VABinauralArtificialReverb.cpp
View file @
0a71acec
...
...
@@ -509,8 +509,7 @@ void CVABinauralArtificialReverbAudioRenderer::Reset()
{
CBARPath
*
pPath
(
*
it
);
int
iNumRefs
=
pPath
->
GetNumReferences
();
assert
(
iNumRefs
==
1
);
assert
(
pPath
->
GetNumReferences
()
==
1
);
pPath
->
RemoveReference
();
++
it
;
...
...
@@ -828,8 +827,8 @@ void CVABinauralArtificialReverbAudioRenderer::ProcessStream( const ITAStreamInf
const
float
*
pfIn
=
pListener
->
psbInput
->
data
();
float
*
pfOutL
=
(
*
pListener
->
psfOutput
)[
0
].
data
();
float
*
pfOutR
=
(
*
pListener
->
psfOutput
)[
1
].
data
();
pListener
->
pConvolverL
->
Process
(
pfIn
,
pfOutL
,
ITA
UPConvolution
::
OUTPUT_
OVERWRITE
);
pListener
->
pConvolverR
->
Process
(
pfIn
,
pfOutR
,
ITA
UPConvolution
::
OUTPUT_
OVERWRITE
);
pListener
->
pConvolverL
->
Process
(
pfIn
,
pfOutL
,
ITA
Base
::
MixingMethod
::
OVERWRITE
);
pListener
->
pConvolverR
->
Process
(
pfIn
,
pfOutR
,
ITA
Base
::
MixingMethod
::
OVERWRITE
);
pListener
->
psbInput
->
Zero
();
// clear input for next block
...
...
@@ -991,11 +990,11 @@ CVABinauralArtificialReverbAudioRenderer::Listener* CVABinauralArtificialReverbA
pListener
->
psbInput
=
new
ITASampleBuffer
(
GetBlocklength
(),
true
);
pListener
->
pConvolverL
=
new
ITAUPConvolution
(
GetBlocklength
(),
m_iMaxReverbFilterLengthSamples
);
pListener
->
pConvolverL
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pListener
->
pConvolverL
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pListener
->
pConvolverL
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
int
(
GetBlocklength
()
),
32
)
);
pListener
->
pConvolverR
=
new
ITAUPConvolution
(
GetBlocklength
(),
m_iMaxReverbFilterLengthSamples
);
pListener
->
pConvolverR
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pListener
->
pConvolverR
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pListener
->
pConvolverR
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
int
(
GetBlocklength
()
),
32
)
);
assert
(
pListener
->
pData
);
...
...
src/Rendering/Binaural/FreeField/VABinauralFreeFieldAudioRenderer.cpp
View file @
0a71acec
...
...
@@ -763,8 +763,8 @@ void CVABinauralFreeFieldAudioRenderer::ProcessStream( const ITAStreamInfo* pStr
pPath
->
pThirdOctaveFilterBank
->
Process
(
psbInput
->
data
(),
ctxAudio
.
m_sbTempL
.
data
()
);
pPath
->
pVariableDelayLineChR
->
Process
(
&
(
ctxAudio
.
m_sbTempL
),
&
(
ctxAudio
.
m_sbTempR
)
);
pPath
->
pVariableDelayLineChL
->
Process
(
&
(
ctxAudio
.
m_sbTempL
),
&
(
ctxAudio
.
m_sbTempL
)
);
// inplace
pPath
->
pFIRConvolverChL
->
Process
(
ctxAudio
.
m_sbTempL
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
0
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
pFIRConvolverChR
->
Process
(
ctxAudio
.
m_sbTempR
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
1
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
pFIRConvolverChL
->
Process
(
ctxAudio
.
m_sbTempL
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
0
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
pPath
->
pFIRConvolverChR
->
Process
(
ctxAudio
.
m_sbTempR
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
1
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
spit
++
;
}
...
...
@@ -1162,7 +1162,7 @@ CVABFFSoundPath::CVABFFSoundPath( double dSamplerate, int iBlocklength, int iHRI
pVariableDelayLineChR
=
new
CITAVariableDelayLine
(
dSamplerate
,
iBlocklength
,
fReserverdMaxDelaySamples
,
m_iDefaultVDLSwitchingAlgorithm
);
pFIRConvolverChL
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
pFIRConvolverChL
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pFIRConvolverChL
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pFIRConvolverChL
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
pFIRConvolverChL
->
SetGain
(
0.0
f
,
true
);
ITAUPFilter
*
pHRIRFilterChL
=
pFIRConvolverChL
->
RequestFilter
();
...
...
@@ -1170,7 +1170,7 @@ CVABFFSoundPath::CVABFFSoundPath( double dSamplerate, int iBlocklength, int iHRI
pFIRConvolverChL
->
ExchangeFilter
(
pHRIRFilterChL
);
pFIRConvolverChR
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
pFIRConvolverChR
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pFIRConvolverChR
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pFIRConvolverChR
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
pFIRConvolverChR
->
SetGain
(
0.0
f
,
true
);
ITAUPFilter
*
pHRIRFilterChR
=
pFIRConvolverChR
->
RequestFilter
();
...
...
src/Rendering/Binaural/OutdoorNoise/VABinauralOutdoorNoiseAudioRenderer.cpp
View file @
0a71acec
...
...
@@ -492,10 +492,10 @@ CVABATNSoundPath::CVABATNSoundPath( double dSamplerate, int iBlocklength, int iH
oRefSoundPath
.
pFIRConvolverChL
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
oDirSoundPath
.
pFIRConvolverChR
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
oRefSoundPath
.
pFIRConvolverChR
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
oDirSoundPath
.
pFIRConvolverChL
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
oRefSoundPath
.
pFIRConvolverChL
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
oDirSoundPath
.
pFIRConvolverChR
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
oRefSoundPath
.
pFIRConvolverChR
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
oDirSoundPath
.
pFIRConvolverChL
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
oRefSoundPath
.
pFIRConvolverChL
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
oDirSoundPath
.
pFIRConvolverChR
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
oRefSoundPath
.
pFIRConvolverChR
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
oDirSoundPath
.
pFIRConvolverChL
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
oRefSoundPath
.
pFIRConvolverChL
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
oDirSoundPath
.
pFIRConvolverChR
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
...
...
src/Rendering/Binaural/RoomAcoustics/VARoomAcousticsAudioRenderer.cpp
View file @
0a71acec
...
...
@@ -549,7 +549,7 @@ ComplexSoundPath::ComplexSoundPath( double dSamplerate, int iBlocklength, int iR
// Falter
int
iRIRConvolverLength
=
pParentFilterPool
->
GetMaxFilterlength
();
pRIRConvolverCh0
=
new
ITAUPConvolution
(
iBlocklength
,
iRIRConvolverLength
,
pParentFilterPool
);
pRIRConvolverCh0
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pRIRConvolverCh0
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pRIRConvolverCh0
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
ITAUPFilter
*
pRIRFilterCh0
=
pRIRConvolverCh0
->
RequestFilter
();
pRIRFilterCh0
->
Zeros
();
...
...
@@ -557,7 +557,7 @@ ComplexSoundPath::ComplexSoundPath( double dSamplerate, int iBlocklength, int iR
pRIRConvolverCh0
->
ReleaseFilter
(
pRIRFilterCh0
);
pRIRConvolverCh1
=
new
ITAUPConvolution
(
iBlocklength
,
iRIRConvolverLength
,
pParentFilterPool
);
pRIRConvolverCh1
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pRIRConvolverCh1
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pRIRConvolverCh1
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
ITAUPFilter
*
pRIRFilterCh1
=
pRIRConvolverCh1
->
RequestFilter
();
pRIRFilterCh1
->
Zeros
();
...
...
@@ -1853,12 +1853,12 @@ void CVARoomAcousticsAudioRenderer::ProcessStream( const ITAStreamInfo* pStreamI
}
pPath
->
pMediumPropagationVDL
->
Process
(
psbInput
,
&
m_psbVDLTempOut
);
pPath
->
pRIRConvolverCh0
->
Process
(
m_psbVDLTempOut
.
data
(),
pfOutputCh0
,
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
pRIRConvolverCh1
->
Process
(
m_psbVDLTempOut
.
data
(),
pfOutputCh1
,
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
pRIRConvolverCh0
->
Process
(
m_psbVDLTempOut
.
data
(),
pfOutputCh0
,
ITA
Base
::
MixingMethod
::
ADD
);
pPath
->
pRIRConvolverCh1
->
Process
(
m_psbVDLTempOut
.
data
(),
pfOutputCh1
,
ITA
Base
::
MixingMethod
::
ADD
);
// Direct in, no VDL
//pPath->pRIRConvolverCh0->process(psbInput->data(), pfOutputCh0, ITA
UPConvolution::OUTPUT_MIX
);
//pPath->pRIRConvolverCh1->process(psbInput->data(), pfOutputCh1, ITA
UPConvolution::OUTPUT_MIX
);
//pPath->pRIRConvolverCh0->process(psbInput->data(), pfOutputCh0, ITA
Base::MixingMethod::ADD
);
//pPath->pRIRConvolverCh1->process(psbInput->data(), pfOutputCh1, ITA
Base::MixingMethod::ADD
);
pPath
->
oProfiler
.
dLastConvProcessing
=
pPath
->
oProfiler
.
swConvolve
.
stop
();
m_swConvolveStream
.
stop
();
...
...
src/Rendering/Prototyping/FreeField/VAPrototypeFreeFieldAudioRenderer.cpp
View file @
0a71acec
...
...
@@ -760,7 +760,7 @@ void CVAPrototypeFreeFieldAudioRenderer::ProcessStream( const ITAStreamInfo* pSt
{
ITASampleBuffer
&
sfTarget
=
(
*
pPath
->
pReceiver
->
psfOutput
)[
i
];
ITAUPConvolution
*
pFIRConvolver
=
pPath
->
vpFIRFilterBanks
[
i
];
pFIRConvolver
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
sfTarget
.
GetData
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pFIRConvolver
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
sfTarget
.
GetData
(),
ITA
Base
::
MixingMethod
::
ADD
);
}
spit
++
;
...
...
src/Rendering/Prototyping/GenericPath/VAPTGenericPathAudioRenderer.cpp
View file @
0a71acec
...
...
@@ -143,7 +143,7 @@ CVAPTGenericSoundPath::CVAPTGenericSoundPath( double dSamplerate, int iBlockleng
for
(
int
n
=
0
;
n
<
iNumChannels
;
n
++
)
{
ITAUPConvolution
*
pFIRConvolver
=
new
ITAUPConvolution
(
iBlocklength
,
iIRFilterLength
);
pFIRConvolver
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pFIRConvolver
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pFIRConvolver
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
pFIRConvolver
->
SetGain
(
1.0
f
,
true
);
ITAUPFilter
*
pHRIRFilterChL
=
pFIRConvolver
->
RequestFilter
();
...
...
@@ -824,7 +824,7 @@ void CVAPTGenericPathAudioRenderer::HandleProcessStream( ITADatasourceRealizatio
{
ITAUPConvolution
*
pConvolver
=
pPath
->
vpFIRConvolver
[
n
];
pConvolver
->
SetGain
(
fSoundSourceGain
);
pConvolver
->
Process
(
m_sfTempBuffer
.
GetData
(),
(
*
pPath
->
pListener
->
psfOutput
)[
n
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pConvolver
->
Process
(
m_sfTempBuffer
.
GetData
(),
(
*
pPath
->
pListener
->
psfOutput
)[
n
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
}
spit
++
;
...
...
src/Rendering/Prototyping/HearingAid/VAPTHearingAidRenderer.cpp
View file @
0a71acec
...
...
@@ -740,10 +740,10 @@ void CVAPTHearingAidRenderer::ProcessStream( const ITAStreamInfo* pStreamInfo )
pPath
->
pVariableDelayLine
->
Process
(
psbInput
,
&
(
ctxAudio
.
m_sbTemp
)
);
pPath
->
pThirdOctaveFilterBank
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
ctxAudio
.
m_sbTemp
.
data
()
);
// inplace
pPath
->
pFIRConvolverChL1
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
0
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
pFIRConvolverChR1
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
1
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
pFIRConvolverChL2
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
2
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
pFIRConvolverChR2
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
3
].
data
(),
ITA
UPConvolution
::
OUTPUT_MIX
);
pPath
->
pFIRConvolverChL1
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
0
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
pPath
->
pFIRConvolverChR1
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
1
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
pPath
->
pFIRConvolverChL2
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
2
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
pPath
->
pFIRConvolverChR2
->
Process
(
ctxAudio
.
m_sbTemp
.
data
(),
(
*
pPath
->
pListener
->
psfOutput
)[
3
].
data
(),
ITA
Base
::
MixingMethod
::
ADD
);
spit
++
;
}
...
...
@@ -1211,7 +1211,7 @@ CVAPTHASoundPath::CVAPTHASoundPath( double dSamplerate, int iBlocklength, int iH
pVariableDelayLine
=
new
CITAVariableDelayLine
(
dSamplerate
,
iBlocklength
,
fReserverdMaxDelaySamples
,
m_iDefaultVDLSwitchingAlgorithm
);
pFIRConvolverChL1
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
pFIRConvolverChL1
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pFIRConvolverChL1
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pFIRConvolverChL1
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
pFIRConvolverChL1
->
SetGain
(
0
,
true
);
ITAUPFilter
*
pHRIRFilterChL1
=
pFIRConvolverChL1
->
RequestFilter
();
...
...
@@ -1219,7 +1219,7 @@ CVAPTHASoundPath::CVAPTHASoundPath( double dSamplerate, int iBlocklength, int iH
pFIRConvolverChL1
->
ExchangeFilter
(
pHRIRFilterChL1
);
pFIRConvolverChL2
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
pFIRConvolverChL2
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pFIRConvolverChL2
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pFIRConvolverChL2
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
pFIRConvolverChL2
->
SetGain
(
0
,
true
);
ITAUPFilter
*
pHRIRFilterChL2
=
pFIRConvolverChL2
->
RequestFilter
();
...
...
@@ -1227,7 +1227,7 @@ CVAPTHASoundPath::CVAPTHASoundPath( double dSamplerate, int iBlocklength, int iH
pFIRConvolverChL2
->
ExchangeFilter
(
pHRIRFilterChL2
);
pFIRConvolverChR1
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
pFIRConvolverChR1
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pFIRConvolverChR1
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pFIRConvolverChR1
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
pFIRConvolverChR1
->
SetGain
(
0
,
true
);
ITAUPFilter
*
pHRIRFilterChR1
=
pFIRConvolverChR1
->
RequestFilter
();
...
...
@@ -1235,7 +1235,7 @@ CVAPTHASoundPath::CVAPTHASoundPath( double dSamplerate, int iBlocklength, int iH
pFIRConvolverChR1
->
ExchangeFilter
(
pHRIRFilterChR1
);
pFIRConvolverChR2
=
new
ITAUPConvolution
(
iBlocklength
,
iHRIRFilterLength
);
pFIRConvolverChR2
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pFIRConvolverChR2
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pFIRConvolverChR2
->
SetFilterCrossfadeLength
(
(
std
::
min
)(
iBlocklength
,
32
)
);
pFIRConvolverChR2
->
SetGain
(
0
,
true
);
ITAUPFilter
*
pHRIRFilterChR2
=
pFIRConvolverChR2
->
RequestFilter
();
...
...
src/Reproduction/Binaural/VAAmbisonicsBinauralMixdownReproduction.cpp
View file @
0a71acec
...
...
@@ -294,7 +294,7 @@ CMixdownStreamFilter::CMixdownStreamFilter( int iNumLoudspeaker, double dSampleR
{
ITAUPConvolution
*
pConvolver
=
new
ITAUPConvolution
(
(
int
)
GetBlocklength
(),
iMaxFilterLength
,
pFilterPool
);
pConvolver
->
SetFilterExchangeTrigger
(
pTrigger
);
pConvolver
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pConvolver
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pConvolver
->
SetFilterCrossfadeLength
(
(
int
)
GetBlocklength
()
);
pConvolver
->
ExchangeFilter
(
pDirac
);
...
...
@@ -326,7 +326,7 @@ void CMixdownStreamFilter::ProcessStream( const ITAStreamInfo* pStreamInfo )
int
iIndexLeft
=
2
*
i
+
0
;
int
iIndexRight
=
2
*
i
+
1
;
const
float
*
pfInputData
=
pdsInput
->
GetBlockPointer
(
i
,
pStreamInfo
);
int
iWriteMode
=
(
i
==
0
)
?
ITA
UPConvolution
::
OUTPUT_OVERWRITE
:
ITAUPConvolution
::
OUTPUT_MIX
;
int
iWriteMode
=
(
i
==
0
)
?
ITA
Base
::
MixingMethod
::
OVERWRITE
:
ITABase
::
MixingMethod
::
ADD
;
vpConvolver
[
iIndexLeft
]
->
Process
(
pfInputData
,
pfBinauralOutputDataChL
,
iWriteMode
);
vpConvolver
[
iIndexRight
]
->
Process
(
pfInputData
,
pfBinauralOutputDataChR
,
iWriteMode
);
}
...
...
src/Reproduction/Binaural/VABinauralMixdownReproduction.cpp
View file @
0a71acec
...
...
@@ -217,7 +217,7 @@ StreamFilter::StreamFilter( int iNumChannels, double dSampleRate, int iBlockLeng
{
ITAUPConvolution
*
pConvolver
=
new
ITAUPConvolution
(
(
int
)
GetBlocklength
(),
iMaxFilterLength
,
pFilterPool
);
pConvolver
->
SetFilterExchangeTrigger
(
pTrigger
);
pConvolver
->
SetFilterExchange
Mode
(
ITAUPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
pConvolver
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunction
::
COSINE_SQUARE
);
pConvolver
->
SetFilterCrossfadeLength
(
(
int
)
GetBlocklength
()
);
pConvolver
->
ExchangeFilter
(
pDirac
);
...
...
@@ -246,7 +246,7 @@ void StreamFilter::ProcessStream( const ITAStreamInfo* pStreamInfo )
int
iIndexLeft
=
2
*
i
+
0
;
int
iIndexRight
=
2
*
i
+
1
;
const
float
*
pfInputData
=
pdsInput
->
GetBlockPointer
(
i
,
pStreamInfo
);
int
iWriteMode
=
(
i
==
0
)
?
ITA
UPConvolution
::
OUTPUT_OVERWRITE
:
ITAUPConvolution
::
OUTPUT_MIX
;
int
iWriteMode
=
(
i
==
0
)
?
ITA
Base
::
MixingMethod
::
OVERWRITE
:
ITABase
::
MixingMethod
::
ADD
;
vpConvolver
[
iIndexLeft
]
->
Process
(
pfInputData
,
pfBinauralOutputDataChL
,
iWriteMode
);
vpConvolver
[
iIndexRight
]
->
Process
(
pfInputData
,
pfBinauralOutputDataChR
,
iWriteMode
);
}
...
...
src/Reproduction/Binaural/VAHeadphonesReproduction.cpp
View file @
0a71acec
...
...
@@ -272,10 +272,10 @@ HPEQStreamFilter::HPEQStreamFilter( double dSampleRate, int iBlockLength, const
,
fGain
(
1.0
f
)
{
pConvolverLeft
=
new
ITAUPConvolution
(
GetBlocklength
(),
sfHpIRinv
.
length
()
);
pConvolverLeft
->
SetFilterExchange
Mode
(
ITAUPConvolu
tion
::
SWITCH
);
pConvolverLeft
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunc
tion
::
SWITCH
);
pConvolverRight
=
new
ITAUPConvolution
(
GetBlocklength
(),
sfHpIRinv
.
length
()
);
pConvolverRight
->
SetFilterExchange
Mode
(
ITAUPConvolu
tion
::
SWITCH
);
pConvolverRight
->
SetFilterExchange
FadingFunction
(
ITABase
::
FadingFunc
tion
::
SWITCH
);
ExchangeFilter
(
sfHpIRinv
);
}
...
...
@@ -313,8 +313,8 @@ void HPEQStreamFilter::ProcessStream( const ITAStreamInfo* pStreamInfo )
const
float
*
pfInputDataLeft
=
pdsInput
->
GetBlockPointer
(
0
,
pStreamInfo
);
const
float
*
pfInputDataRight
=
pdsInput
->
GetBlockPointer
(
1
,
pStreamInfo
);
pConvolverLeft
->
Process
(
pfInputDataLeft
,
pfBinauralOutputDataChL
,
ITA
UPConvolution
::
OUTPUT_
OVERWRITE
);
pConvolverRight
->
Process
(
pfInputDataRight
,
pfBinauralOutputDataChR
,
ITA
UPConvolution
::
OUTPUT_
OVERWRITE
);
pConvolverLeft
->
Process
(
pfInputDataLeft
,
pfBinauralOutputDataChL
,
ITA
Base
::
MixingMethod
::
OVERWRITE
);
pConvolverRight
->
Process
(
pfInputDataRight
,
pfBinauralOutputDataChR
,
ITA
Base
::
MixingMethod
::
OVERWRITE
);
pConvolverLeft
->
SetGain
(
fGain
);
pConvolverRight
->
SetGain
(
fGain
);
...
...
src/Reproduction/Binaural/VANCTCReproduction.cpp
View file @
0a71acec
...
...
@@ -137,7 +137,7 @@ CVANCTCReproduction::CVANCTCReproduction( const CVAAudioReproductionInitParams&
oNCTCStreamConf
.
iFilterLength
=
oNCTCConf
.
iCTCFilterLength
;
conf
.
OptInteger
(
"CTCFilterCrossfadeLength"
,
oNCTCStreamConf
.
iFilterCrossfadeLength
,
128
);
conf
.
OptInteger
(
"CTCFilterExchangeMode"
,
oNCTCStreamConf
.
iFilterExchangeMode
,
ITA
UPConvolution
::
CROSSFADE_
COSINE_SQUARE
);
conf
.
OptInteger
(
"CTCFilterExchangeMode"
,
oNCTCStreamConf
.
iFilterExchangeMode
,
ITA
Base
::
FadingFunction
::
COSINE_SQUARE
);
conf
.
OptBool
(
"UseTrackedListenerHRIR"
,
m_bTrackedListenerHRIR
,
false
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment