Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
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
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
37b07a5e
Commit
37b07a5e
authored
Mar 15, 2018
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pcm/PcmDop: use size_t
parent
73013a3c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
PcmDop.cxx
src/pcm/PcmDop.cxx
+5
-5
No files found.
src/pcm/PcmDop.cxx
View file @
37b07a5e
...
...
@@ -46,19 +46,19 @@ pcm_dsd_to_dop(PcmBuffer &buffer, unsigned channels,
assert
(
audio_valid_channel_count
(
channels
));
assert
(
_src
.
size
%
channels
==
0
);
const
unsigned
num_src_samples
=
_src
.
size
;
const
unsigned
num_src_frames
=
num_src_samples
/
channels
;
const
size_t
num_src_samples
=
_src
.
size
;
const
size_t
num_src_frames
=
num_src_samples
/
channels
;
/* this rounds down and discards the last odd frame; not
elegant, but good enough for now */
const
unsigned
num_frames
=
num_src_frames
/
2
;
const
unsigned
num_samples
=
num_frames
*
channels
;
const
size_t
num_frames
=
num_src_frames
/
2
;
const
size_t
num_samples
=
num_frames
*
channels
;
uint32_t
*
const
dest0
=
(
uint32_t
*
)
buffer
.
GetT
<
uint32_t
>
(
num_samples
),
*
dest
=
dest0
;
auto
src
=
_src
.
data
;
for
(
unsigned
i
=
num_frames
/
2
;
i
>
0
;
--
i
)
{
for
(
size_t
i
=
num_frames
/
2
;
i
>
0
;
--
i
)
{
for
(
unsigned
c
=
channels
;
c
>
0
;
--
c
)
{
/* each 24 bit sample has 16 DSD sample bits
plus the magic 0x05 marker */
...
...
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