Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-daemon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
jami-daemon
Commits
0c0d2c30
Commit
0c0d2c30
authored
16 years ago
by
Alexandre Savard
Browse files
Options
Downloads
Patches
Plain Diff
Minor modification to samplerate converter
parent
d29214be
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/iaxvoiplink.cpp
+1
-3
1 addition, 3 deletions
src/iaxvoiplink.cpp
src/samplerateconverter.cpp
+4
-2
4 additions, 2 deletions
src/samplerateconverter.cpp
with
5 additions
and
5 deletions
src/iaxvoiplink.cpp
+
1
−
3
View file @
0c0d2c30
...
@@ -218,7 +218,6 @@ IAXVoIPLink::getEvent()
...
@@ -218,7 +218,6 @@ IAXVoIPLink::getEvent()
if
(
call
){
if
(
call
){
// _debug("Are we recording");
call
->
recAudio
.
recData
(
spkrDataConverted
,
micData
,
nbSampleForRec_
,
nbSampleForRec_
);
call
->
recAudio
.
recData
(
spkrDataConverted
,
micData
,
nbSampleForRec_
,
nbSampleForRec_
);
}
}
...
@@ -230,7 +229,6 @@ IAXVoIPLink::getEvent()
...
@@ -230,7 +229,6 @@ IAXVoIPLink::getEvent()
sendRegister
(
""
);
sendRegister
(
""
);
}
}
// _debug("IAXVoIPLink::getEvent() \n");
// reinitialize speaker buffer for recording (when recording a voice mail)
// reinitialize speaker buffer for recording (when recording a voice mail)
for
(
int
i
=
0
;
i
<
nbSampleForRec_
;
i
++
)
for
(
int
i
=
0
;
i
<
nbSampleForRec_
;
i
++
)
spkrDataConverted
[
i
]
=
0
;
spkrDataConverted
[
i
]
=
0
;
...
...
This diff is collapsed.
Click to expand it.
src/samplerateconverter.cpp
+
4
−
2
View file @
0c0d2c30
...
@@ -64,8 +64,10 @@ void SamplerateConverter::init( void ) {
...
@@ -64,8 +64,10 @@ void SamplerateConverter::init( void ) {
// libSamplerateConverter-related
// libSamplerateConverter-related
// Set the converter type for the upsampling and the downsampling
// Set the converter type for the upsampling and the downsampling
// interpolator SRC_SINC_BEST_QUALITY
// interpolator SRC_SINC_BEST_QUALITY
_src_state_mic
=
src_new
(
SRC_LINEAR
,
1
,
&
_src_err
);
// interpolator SRC_SINC_FASTEST
_src_state_spkr
=
src_new
(
SRC_LINEAR
,
1
,
&
_src_err
);
// interpolator SRC_LINEAR
_src_state_mic
=
src_new
(
SRC_SINC_FASTEST
,
1
,
&
_src_err
);
_src_state_spkr
=
src_new
(
SRC_SINC_FASTEST
,
1
,
&
_src_err
);
int
nbSamplesMax
=
(
int
)
(
getFrequence
()
*
getFramesize
()
/
1000
);
int
nbSamplesMax
=
(
int
)
(
getFrequence
()
*
getFramesize
()
/
1000
);
_floatBufferDownMic
=
new
float32
[
nbSamplesMax
];
_floatBufferDownMic
=
new
float32
[
nbSamplesMax
];
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment