aboutsummaryrefslogtreecommitdiffstats
path: root/src/player_thread.c
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2008-10-10 14:47:58 +0200
committerMax Kellermann <max@duempel.org>2008-10-10 14:47:58 +0200
commit0b4dfae22e883d376bc44e1e2d78f201d045970b (patch)
tree755cbfeff4158a09c6970824612488b3702a8c7b /src/player_thread.c
parent8c33b64847c5ead45ade665afc9ad16a04a693f2 (diff)
downloadmpd-0b4dfae22e883d376bc44e1e2d78f201d045970b.tar.gz
mpd-0b4dfae22e883d376bc44e1e2d78f201d045970b.tar.xz
mpd-0b4dfae22e883d376bc44e1e2d78f201d045970b.zip
player: added player_control.audio_format
This replaces the attributes bits, channels, sampleRate.
Diffstat (limited to 'src/player_thread.c')
-rw-r--r--src/player_thread.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/src/player_thread.c b/src/player_thread.c
index efb7d7ab5..c5a51a00a 100644
--- a/src/player_thread.c
+++ b/src/player_thread.c
@@ -62,9 +62,7 @@ static int waitOnDecode(int *decodeWaitedOn)
pc.totalTime = pc.fileTime;
pc.bitRate = 0;
- pc.sampleRate = 0;
- pc.bits = 0;
- pc.channels = 0;
+ audio_format_clear(&pc.audio_format);
*decodeWaitedOn = 1;
return 0;
@@ -253,9 +251,7 @@ static void do_play(void)
closeAudioDevice();
}
pc.totalTime = dc.totalTime;
- pc.sampleRate = dc.audioFormat.sample_rate;
- pc.bits = dc.audioFormat.bits;
- pc.channels = dc.audioFormat.channels;
+ pc.audio_format = dc.audioFormat;
sizeToTime = audioFormatSizeToTime(&ob.audioFormat);
}
else {