[xiph-cvs] cvs commit: ao/src Makefile.am audio_out.c

Jack Moffitt jack at xiph.org
Sat May 5 17:14:00 PDT 2001



jack        01/05/05 17:13:59

  Modified:    doc      DRIVERS
               include/ao ao.h
               src      Makefile.am audio_out.c
  Log:
  Stan Seibert's ao_raw device.

Revision  Changes    Path
1.3       +12 -0     ao/doc/DRIVERS

Index: DRIVERS
===================================================================
RCS file: /usr/local/cvsroot/ao/doc/DRIVERS,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- DRIVERS	2001/02/02 10:02:06	1.2
+++ DRIVERS	2001/05/06 00:13:58	1.3
@@ -59,6 +59,18 @@
         "file" - Sets the output file.  By default, this is
                  "output.wav".
 
+raw
+---
+Raw sample output.  Writes the sound data to disk in uncompressed,
+headerless form using the byte order specified.
+	Option keys:
+		"file" - Sets the output file.  Use "-" if you want to write
+		to stdout.  By default this is "output.raw".
+		
+		"byteorder" - Sets the byte order used in the output.  Use
+		"native" for native machine byte order, "big" for 
+		big-endian order, and "little" for little-endian order. By
+		default this is "native".
 
 ADDING NEW DRIVERS
 

1.12      +1 -0      ao/include/ao/ao.h

Index: ao.h
===================================================================
RCS file: /usr/local/cvsroot/ao/include/ao/ao.h,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -r1.11 -r1.12
--- ao.h	2001/02/24 01:31:46	1.11
+++ ao.h	2001/05/06 00:13:59	1.12
@@ -75,6 +75,7 @@
 
 #define AO_NULL     0
 #define AO_WAV      1
+#define AO_RAW	    2
 
 /* --- Functions --- */
 

1.5       +1 -1      ao/src/Makefile.am

Index: Makefile.am
===================================================================
RCS file: /usr/local/cvsroot/ao/src/Makefile.am,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -r1.4 -r1.5
--- Makefile.am	2000/10/30 00:46:41	1.4
+++ Makefile.am	2001/05/06 00:13:59	1.5
@@ -7,7 +7,7 @@
 
 lib_LTLIBRARIES = libao.la
 
-libao_la_SOURCES = audio_out.c ao_wav.c ao_null.c
+libao_la_SOURCES = audio_out.c ao_raw.c ao_wav.c ao_null.c
 libao_la_LDFLAGS = -version-info @LIB_CURRENT@:@LIB_REVISION@:@LIB_AGE@
 
 

1.14      +9 -3      ao/src/audio_out.c

Index: audio_out.c
===================================================================
RCS file: /usr/local/cvsroot/ao/src/audio_out.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- audio_out.c	2001/02/28 07:50:11	1.13
+++ audio_out.c	2001/05/06 00:13:59	1.14
@@ -55,6 +55,7 @@
 
 extern ao_functions_t ao_null;
 extern ao_functions_t ao_wav;
+extern ao_functions_t ao_raw;
 
 driver_tree_t *driver_head = NULL;
 
@@ -97,6 +98,7 @@
 {
         driver_tree_t *dnull;
         driver_tree_t *dwav;
+	driver_tree_t *draw;
         driver_tree_t *plugin;
         driver_tree_t *driver;
         DIR *plugindir;
@@ -114,12 +116,16 @@
                 dwav = (driver_tree_t *)malloc(sizeof(driver_tree_t));
                 dwav->functions = &ao_wav;
                 dwav->handle = NULL;
+		draw = (driver_tree_t *)malloc(sizeof(driver_tree_t));
+		draw->functions = &ao_raw;
+		draw->handle = NULL;
                 
                 dnull->next = dwav;
-		dwav->next = NULL;
+		dwav->next = draw;
+		draw->next = NULL;
 
                 driver_head = dnull;		
-		driver = dwav;
+		driver = draw;
 
                 /* now insert any plugins we find */
                 plugindir = opendir(AO_PLUGIN_PATH);
@@ -151,7 +157,7 @@
         if (!driver_head) return;
 
         /* unload and free all the plugins */
-	driver = driver->next->next;
+	driver = driver->next->next->next;  /* Skip null, wav, and raw driver */
         while (driver) {
                 if (driver->functions) free(driver->functions);
                 if (driver->handle) dlclose(driver->handle);

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'cvs-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.



More information about the commits mailing list