Browse Source

Updates to error handling (GS).

tags/4.0.0
Gary Scavone Stephen Sinclair 18 years ago
parent
commit
d0f1bed24b
3 changed files with 151 additions and 157 deletions
  1. +148
    -150
      RtAudio.cpp
  2. +1
    -7
      RtAudio.h
  3. +2
    -0
      RtError.h

+ 148
- 150
RtAudio.cpp
File diff suppressed because it is too large
View File


+ 1
- 7
RtAudio.h View File

@@ -564,12 +564,6 @@ protected:

enum { FAILURE, SUCCESS };

enum ErrorType {
WARNING,
INVALID_CALL,
SYSTEM
};

enum StreamState {
STREAM_STOPPED,
STREAM_RUNNING,
@@ -661,7 +655,7 @@ protected:
void verifyStream( void );

//! Protected common error method to allow global control over error handling.
void error( ErrorType type );
void error( RtError::Type type );

/*!
Protected method used to perform format, channel number, and/or interleaving


+ 2
- 0
RtError.h View File

@@ -21,6 +21,8 @@ class RtError : public std::exception
public:
//! Defined RtError types.
enum Type {
WARNING, /*!< A non-critical error. */
DEBUG_WARNING, /*!< A non-critical error which might be useful for debugging. */
UNSPECIFIED, /*!< The default, unspecified error type. */
NO_DEVICES_FOUND, /*!< No devices found on system. */
INVALID_DEVICE, /*!< An invalid device ID was specified. */


Loading…
Cancel
Save