/[svn]/linuxsampler/trunk/src/drivers/audio/AudioOutputDeviceArts.cpp
ViewVC logotype

Diff of /linuxsampler/trunk/src/drivers/audio/AudioOutputDeviceArts.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 3765 by schoenebeck, Wed Jan 1 17:48:01 2014 UTC revision 3766 by schoenebeck, Mon Apr 6 12:41:49 2020 UTC
# Line 1  Line 1 
1  /***************************************************************************  /***************************************************************************
2   *                                                                         *   *                                                                         *
3   *   Copyright (C) 2006 Christian Schoenebeck                              *   *   Copyright (C) 2006 - 2020 Christian Schoenebeck                       *
4   *                                                                         *   *                                                                         *
5   *   This library is free software; you can redistribute it and/or modify  *   *   This library is free software; you can redistribute it and/or modify  *
6   *   it under the terms of the GNU General Public License as published by  *   *   it under the terms of the GNU General Public License as published by  *
# Line 169  namespace LinuxSampler { Line 169  namespace LinuxSampler {
169       * Entry point for the thread.       * Entry point for the thread.
170       */       */
171      int AudioOutputDeviceArts::Main() {      int AudioOutputDeviceArts::Main() {
172    
173            #if DEBUG
174            Thread::setNameOfCaller("ArtsAudio");
175            #endif
176    
177          while (true) {          while (true) {
178                TestCancel();
179    
180                // prevent thread from being cancelled
181                // (e.g. to prevent deadlocks while holding mutex lock(s))
182                pushCancelable(false);
183    
184              // let all connected engines render 'FragmentSize' sample points              // let all connected engines render 'FragmentSize' sample points
185              RenderAudio(FragmentSize);              RenderAudio(FragmentSize);
# Line 192  namespace LinuxSampler { Line 202  namespace LinuxSampler {
202                  fprintf(stderr, "AudioOutputDeviceArts: Audio output error, exiting.\n");                  fprintf(stderr, "AudioOutputDeviceArts: Audio output error, exiting.\n");
203                  exit(EXIT_FAILURE);                  exit(EXIT_FAILURE);
204              }              }
205    
206                // now allow thread being cancelled again
207                // (since all mutexes are now unlocked)
208                popCancelable();
209          }          }
210      }      }
211    

Legend:
Removed from v.3765  
changed lines
  Added in v.3766

  ViewVC Help
Powered by ViewVC