Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
A
audiowmark
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Stefan Westerfeld
audiowmark
Commits
58911f72
Commit
58911f72
authored
Jan 10, 2019
by
Stefan Westerfeld
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Make computing frame ffts a bit faster.
Signed-off-by:
Stefan Westerfeld
<
stefan@space.twc.de
>
parent
12565122
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
audiowmark.cc
src/audiowmark.cc
+4
-4
No files found.
src/audiowmark.cc
View file @
58911f72
...
...
@@ -346,10 +346,10 @@ compute_frame_ffts (const WavData& wav_data)
/* FFT transform */
fftar_float
(
Params
::
frame_size
,
frame
,
frame_fft
);
/* complex<float>
vector and fft_ou
t have the same layout in memory */
vector
<
complex
<
float
>>
out
(
Params
::
frame_size
/
2
+
1
)
;
std
::
copy
(
frame_fft
,
frame_fft
+
out
.
size
()
*
2
,
reinterpret_cast
<
float
*>
(
&
out
[
0
]))
;
fft_out
.
emplace_back
(
ou
t
);
/* complex<float>
and frame_ff
t have the same layout in memory */
const
complex
<
float
>
*
first
=
(
complex
<
float
>
*
)
frame_fft
;
const
complex
<
float
>
*
last
=
first
+
Params
::
frame_size
/
2
+
1
;
fft_out
.
emplace_back
(
first
,
las
t
);
}
}
free_array_float
(
frame
);
...
...
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