PortAudio 2.0
patest_wire.c File Reference

Pass input directly to output. More...

#include <stdio.h>
#include <math.h>
#include "portaudio.h"

Data Structures

struct  WireConfig_s
 

Macros

#define SAMPLE_RATE   (44100)
 
#define USE_FLOAT_INPUT   (1)
 
#define USE_FLOAT_OUTPUT   (1)
 
#define INPUT_FORMAT   paFloat32
 
#define OUTPUT_FORMAT   paFloat32
 
#define CONVERT_IN_TO_OUT(in)
 
#define INPUT_DEVICE   (Pa_GetDefaultInputDevice())
 
#define OUTPUT_DEVICE   (Pa_GetDefaultOutputDevice())
 
#define CHECK_FLAG_COUNT(member)
 

Typedefs

typedef struct WireConfig_s WireConfig_t
 
typedef float INPUT_SAMPLE
 
typedef float OUTPUT_SAMPLE
 

Functions

int main (void)
 

Variables

double gInOutScaler = 1.0
 

Detailed Description

Pass input directly to output.

Note that some HW devices, for example many ISA audio cards on PCs, do NOT support full duplex! For a PC, you normally need a PCI based audio card such as the SBLive.

Author
Phil Burk http://www.softsynth.com

While adapting to V19-API, I excluded configs with framesPerCallback=0 because of an assert in file pa_common/pa_process.c. Pieter, Oct 9, 2003.

Macro Definition Documentation

◆ CHECK_FLAG_COUNT

#define CHECK_FLAG_COUNT ( member)
Value:
if( config->member > 0 ) printf("FLAGS SET: " #member " = %d\n", config->member );

◆ CONVERT_IN_TO_OUT

#define CONVERT_IN_TO_OUT ( in)
Value:
float OUTPUT_SAMPLE
Definition patest_wire.c:92
double gInOutScaler
Definition patest_wire.c:98

◆ INPUT_DEVICE

#define INPUT_DEVICE   (Pa_GetDefaultInputDevice())

Referenced by main().

◆ INPUT_FORMAT

#define INPUT_FORMAT   paFloat32

Referenced by main().

◆ OUTPUT_DEVICE

#define OUTPUT_DEVICE   (Pa_GetDefaultOutputDevice())

Referenced by main().

◆ OUTPUT_FORMAT

#define OUTPUT_FORMAT   paFloat32

Referenced by main().

◆ SAMPLE_RATE

#define SAMPLE_RATE   (44100)

◆ USE_FLOAT_INPUT

#define USE_FLOAT_INPUT   (1)

◆ USE_FLOAT_OUTPUT

#define USE_FLOAT_OUTPUT   (1)

Typedef Documentation

◆ INPUT_SAMPLE

typedef float INPUT_SAMPLE

◆ OUTPUT_SAMPLE

typedef float OUTPUT_SAMPLE

◆ WireConfig_t

typedef struct WireConfig_s WireConfig_t

Function Documentation

◆ main()

Variable Documentation

◆ gInOutScaler

double gInOutScaler = 1.0

Referenced by main().