summaryrefslogtreecommitdiff
path: root/muse2/muse/driver/alsatimer.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'muse2/muse/driver/alsatimer.cpp')
-rw-r--r--muse2/muse/driver/alsatimer.cpp29
1 files changed, 14 insertions, 15 deletions
diff --git a/muse2/muse/driver/alsatimer.cpp b/muse2/muse/driver/alsatimer.cpp
index 20f7ab88..cf211a2f 100644
--- a/muse2/muse/driver/alsatimer.cpp
+++ b/muse2/muse/driver/alsatimer.cpp
@@ -1,12 +1,12 @@
- //=========================================================
- // MusE
- // Linux Music Editor
- // $Id: alsatimer.cpp,v 1.1.2.9 2009/03/28 01:46:10 terminator356 Exp $
- //
- // Plenty of code borrowed from timer.c example in
- // alsalib 1.0.7
- //
- // (C) Copyright 2004 Robert Jonsson (rj@spamatica.se)
+//=========================================================
+// MusE
+// Linux Music Editor
+// $Id: alsatimer.cpp,v 1.1.2.9 2009/03/28 01:46:10 terminator356 Exp $
+//
+// Plenty of code borrowed from timer.c example in
+// alsalib 1.0.7
+//
+// (C) Copyright 2004 Robert Jonsson (rj@spamatica.se)
//
// This program is free software; you can redistribute it and/or
// modify it under the terms of the GNU General Public License
@@ -22,10 +22,10 @@
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
//
- //=========================================================
+//=========================================================
- #include "alsatimer.h"
- #include <climits>
+#include "alsatimer.h"
+#include <climits>
#define TIMER_DEBUG 0
@@ -73,7 +73,7 @@ namespace MusECore {
int max_ids = sizeof(test_ids) / sizeof(int);
long best_res = LONG_MAX;
//int best_dev = -1; // SND_TIMER_GLOBAL_SYSTEM;
- int best_dev = SND_TIMER_GLOBAL_SYSTEM; // p3.3.51
+ int best_dev = SND_TIMER_GLOBAL_SYSTEM;
int i;
if (id || info || params) {
@@ -107,14 +107,13 @@ namespace MusECore {
device = best_dev;
}
- // p3.3.51 Removed.
//if(best_dev==-1)
// return -1; // no working timer found
sprintf(timername, "hw:CLASS=%i,SCLASS=%i,CARD=%i,DEV=%i,SUBDEV=%i", devclass, sclass, card, device, subdevice);
if ((err = snd_timer_open(&handle, timername, SND_TIMER_OPEN_NONBLOCK))<0) {
fprintf(stderr, "AlsaTimer::initTimer(): timer open %i (%s)\n", err, snd_strerror(err));
- return -1; // p3.3.51
+ return -1;
}
if ((err = snd_timer_info(handle, info)) < 0) {