spdif: Handle soundcard asleep, try to wake up with a random bitrate
This commit is contained in:
parent
5d70cecaea
commit
2b50886ed0
@ -80,6 +80,10 @@ func (s *SPDIFSource) Enable() error {
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
|
// If no bitrate, asume soundcard is sleeping, try to wake up with a random bitrate
|
||||||
|
if sr == 0 {
|
||||||
|
sr = 44100
|
||||||
|
}
|
||||||
s.Bitrate = sr
|
s.Bitrate = sr
|
||||||
|
|
||||||
// If no bitrate, asume soundcard is sleeping, try to wake up with a random bitrate
|
// If no bitrate, asume soundcard is sleeping, try to wake up with a random bitrate
|
||||||
|
Loading…
Reference in New Issue
Block a user