Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
savoirfairelinux
jami-daemon
Commits
47f14109
Commit
47f14109
authored
Jun 15, 2010
by
Alexandre Savard
Browse files
[#3507] Add comments and documentation
parent
91871d4c
Changes
1
Hide whitespace changes
Inline
Side-by-side
sflphone-common/src/audio/echocancel.h
View file @
47f14109
...
...
@@ -116,12 +116,24 @@ class EchoCancel : public Algorithm {
*/
void
setSamplingRate
(
int
smplRate
);
/**
* Set echo canceller state to active/deactive
*/
void
setEchoCancelState
(
bool
state
)
{
_echoActive
=
state
;
}
/**
* Return the echo canceller state
*/
bool
getEchoCancelState
(
void
)
{
return
_echoActive
;
}
/**
* Set the noise suppression state to active/deactive
*/
void
setNoiseSuppressState
(
bool
state
)
{
_noiseActive
=
state
;
}
/**
* Return the noise suppression state
*/
bool
getNoiseSuppressState
(
void
)
{
return
_noiseActive
;
}
private:
...
...
@@ -131,10 +143,19 @@ class EchoCancel : public Algorithm {
*/
void
performEchoCancel
(
SFLDataFormat
*
micData
,
SFLDataFormat
*
spkrData
,
SFLDataFormat
*
outputData
);
/**
* This is the fall back method in case there is no spkr data available
*/
void
performEchoCancelNoSpkr
(
SFLDataFormat
*
micData
,
SFLDataFormat
*
outputData
);
/**
* Compute current instantaneous microphone signal power and store it in internal array
*/
void
updateMicLevel
(
SFLDataFormat
*
micData
);
/**
* Compute current instantaneous spkeaker signal power and store uit in internal array
*/
void
updateSpkrLevel
(
SFLDataFormat
*
spkrData
);
/**
...
...
@@ -176,8 +197,14 @@ class EchoCancel : public Algorithm {
*/
void
decreaseFactor
();
/**
* Perform simple correlation between data1 and data2
*/
int
performCorrelation
(
int
*
data1
,
int
*
data2
,
int
size
);
/**
* Return maximum in data index
*/
int
getMaximumIndex
(
int
*
data
,
int
size
);
/**
...
...
@@ -300,8 +327,14 @@ class EchoCancel : public Algorithm {
*/
int
_adaptCnt
;
/**
* Factor for power estimation
*/
float
_alpha
;
/**
* Termporary spkr level memories
*/
SFLDataFormat
_spkrLevelMem
;
SFLDataFormat
_micLevelMem
;
...
...
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