mirror of
https://github.com/clangen/musikcube.git
synced 2025-01-04 08:42:07 +00:00
esd sort of working
This commit is contained in:
parent
e129b71739
commit
6c597b4f78
@ -235,8 +235,14 @@ void EsdOut::SetFormat(IBuffer *buffer){
|
||||
|
||||
this->waveFormat |= ESD_STREAM;
|
||||
this->waveFormat |= ESD_PLAY;
|
||||
|
||||
this->waveHandle = esd_play_stream(this->waveFormat, (int)this->currentSampleRate, "192.168.10.1:16001", "musik");
|
||||
#ifdef _DEBUG
|
||||
std::cerr << "waveFormat: " << this->waveFormat << std::endl;
|
||||
#endif
|
||||
char* host = getenv("ESPEAKER");
|
||||
#ifdef _DEBUG
|
||||
std::cerr << "host: " << host << std::endl;
|
||||
#endif
|
||||
this->waveHandle = esd_play_stream(this->waveFormat, (int)this->currentSampleRate, host, "musik");
|
||||
#ifdef _DEBUG
|
||||
std::cerr << "waveHandle: " << this->waveHandle << std::endl;
|
||||
#endif
|
||||
|
@ -102,7 +102,7 @@ bool EsdOutBuffer::AddToOutput(){
|
||||
printf("Short write (expected %li, wrote %li)\n", (long)bufferLength, frames);
|
||||
return false;
|
||||
}*/
|
||||
if ( write( *wHandle, *data, bufferLength ) <= 0 )
|
||||
if ( write( *wHandle, data, bufferLength ) <= 0 )
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user