[xiph-commits] r16986 - in trunk/ao/src: . plugins/pulse
xiphmont at svn.xiph.org
xiphmont at svn.xiph.org
Thu Mar 18 20:56:23 PDT 2010
Author: xiphmont
Date: 2010-03-18 20:56:23 -0700 (Thu, 18 Mar 2010)
New Revision: 16986
Modified:
trunk/ao/src/audio_out.c
trunk/ao/src/plugins/pulse/ao_pulse.c
Log:
Fix mapping offset for pulse
special-case the handling of mono samples as 'mapless' since they don't really map to
anything...
Modified: trunk/ao/src/audio_out.c
===================================================================
--- trunk/ao/src/audio_out.c 2010-03-19 03:04:44 UTC (rev 16985)
+++ trunk/ao/src/audio_out.c 2010-03-19 03:56:23 UTC (rev 16986)
@@ -930,6 +930,12 @@
sformat.matrix = _sanitize_matrix(format->channels, format->matrix, device);
if(!sformat.matrix)
awarn("Input channel matrix invalid; ignoring.\n");
+
+ /* special-case handling of 'M'. */
+ if(sformat.channels==1 && sformat.matrix && !strcmp(sformat.matrix,"M")){
+ free(sformat.matrix);
+ sformat.matrix=NULL;
+ }
}
/* If device init was able to declare a static channel mapping
Modified: trunk/ao/src/plugins/pulse/ao_pulse.c
===================================================================
--- trunk/ao/src/plugins/pulse/ao_pulse.c 2010-03-19 03:04:44 UTC (rev 16985)
+++ trunk/ao/src/plugins/pulse/ao_pulse.c 2010-03-19 03:56:23 UTC (rev 16986)
@@ -141,7 +141,7 @@
device->internal = internal;
device->output_matrix_order = AO_OUTPUT_MATRIX_PERMUTABLE;
- device->output_matrix = strdup("L,R,C,BC,BL,BR,LFE,CL,CR,SL,SR,"
+ device->output_matrix = strdup("M,L,R,C,BC,BL,BR,LFE,CL,CR,SL,SR,"
"A0,A1,A2,A3,A4,A5,A6,A7,A8,A9,"
"A10,A11,A12,A13,A14,A15,A16,A17,A18,A19,"
"A20,A21,A22,A23,A24,A25,A26,A27,A28,A29,"
More information about the commits
mailing list