+ if (BE_INT(au_hdr.channels) == 1) {
+ sbc.mode = SBC_MODE_MONO;
+ if (joint || dualchannel) {
+ fprintf(stderr, "Audio is mono but joint or "
+ "dualchannel mode has been specified\n");
+ goto done;
+ }
+ } else if (joint && !dualchannel)
+ sbc.mode = SBC_MODE_JOINT_STEREO;
+ else if (!joint && dualchannel)
+ sbc.mode = SBC_MODE_DUAL_CHANNEL;
+ else if (!joint && !dualchannel)
+ sbc.mode = SBC_MODE_STEREO;
+ else {
+ fprintf(stderr, "Both joint and dualchannel "
+ "mode have been specified\n");
+ goto done;
+ }