mirror of
https://github.com/badaix/snapcast.git
synced 2025-05-12 00:26:41 +02:00
delay
git-svn-id: svn://elaine/murooma/trunk@102 d8a302eb-03bc-478d-80e4-98257eca68ef
This commit is contained in:
parent
2ab66e9b62
commit
88cbbec472
2 changed files with 20 additions and 1 deletions
2
Makefile
2
Makefile
|
@ -1,6 +1,6 @@
|
||||||
VERSION = 0.01
|
VERSION = 0.01
|
||||||
CC = /usr/bin/g++
|
CC = /usr/bin/g++
|
||||||
CFLAGS = -std=gnu++0x -Bstatic -lzmq -Wall -g -O3 -D_REENTRANT -DVERSION=\"$(VERSION)\" -Bdynamic
|
CFLAGS = -std=gnu++0x -Wall -g -O3 -D_REENTRANT -DVERSION=\"$(VERSION)\"
|
||||||
LDFLAGS = -lrt -lzmq -lpthread -lportaudio
|
LDFLAGS = -lrt -lzmq -lpthread -lportaudio
|
||||||
|
|
||||||
OBJ_SERVER = server.o
|
OBJ_SERVER = server.o
|
||||||
|
|
19
client.cpp
19
client.cpp
|
@ -153,6 +153,25 @@ int main (int argc, char *argv[])
|
||||||
stream->setBufferLen(bufferMs);
|
stream->setBufferLen(bufferMs);
|
||||||
initAudio();
|
initAudio();
|
||||||
std::thread playerThread(player);
|
std::thread playerThread(player);
|
||||||
|
|
||||||
|
std::string cmd;
|
||||||
|
while (true)
|
||||||
|
{
|
||||||
|
std::cout << "> ";
|
||||||
|
std::getline(std::cin, cmd);
|
||||||
|
// line = fgets( str, 256, stdin );
|
||||||
|
// if (line == NULL)
|
||||||
|
// continue;
|
||||||
|
// std::string cmd(line);
|
||||||
|
std::cerr << "CMD: " << cmd << "\n";
|
||||||
|
if (cmd == "quit")
|
||||||
|
break;
|
||||||
|
else
|
||||||
|
{
|
||||||
|
stream->setBufferLen(atoi(cmd.c_str()));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
playerThread.join();
|
playerThread.join();
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue