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
a86aaef4
Commit
a86aaef4
authored
Aug 23, 2014
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
output/alsa: support native DSD playback
Translate SampleFormat::DSD to SND_PCM_FORMAT_DSD_U8, which was added to alsa-lib 1.0.27.1.
parent
e463244d
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
0 deletions
+14
-0
NEWS
NEWS
+2
-0
AlsaOutputPlugin.cxx
src/output/plugins/AlsaOutputPlugin.cxx
+12
-0
No files found.
NEWS
View file @
a86aaef4
...
...
@@ -52,6 +52,8 @@ ver 0.19 (not yet released)
- mp4v2: support playback of MP4 files.
* encoder:
- shine: new encoder plugin
* output
- alsa: support native DSD playback
* threads:
- the update thread runs at "idle" priority
- the output thread runs at "real-time" priority
...
...
src/output/plugins/AlsaOutputPlugin.cxx
View file @
a86aaef4
...
...
@@ -22,6 +22,7 @@
#include "../OutputAPI.hxx"
#include "mixer/MixerList.hxx"
#include "pcm/PcmExport.hxx"
#include "config/ConfigError.hxx"
#include "util/Manual.hxx"
#include "util/Error.hxx"
#include "util/Domain.hxx"
...
...
@@ -32,6 +33,11 @@
#include <string>
#if SND_LIB_VERSION >= 0x1001c
/* alsa-lib supports DSD since version 1.0.27.1 */
#define HAVE_ALSA_DSD
#endif
static
const
char
default_device
[]
=
"default"
;
static
constexpr
unsigned
MPD_ALSA_BUFFER_TIME_US
=
500000
;
...
...
@@ -236,8 +242,14 @@ get_bitformat(SampleFormat sample_format)
{
switch
(
sample_format
)
{
case
SampleFormat
:
:
UNDEFINED
:
return
SND_PCM_FORMAT_UNKNOWN
;
case
SampleFormat
:
:
DSD
:
#ifdef HAVE_ALSA_DSD
return
SND_PCM_FORMAT_DSD_U8
;
#else
return
SND_PCM_FORMAT_UNKNOWN
;
#endif
case
SampleFormat
:
:
S8
:
return
SND_PCM_FORMAT_S8
;
...
...
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