Changeset 2099:858f02f3765e in roaraudio
- Timestamp:
- 07/21/09 13:20:23 (15 years ago)
- Branch:
- default
- Phase:
- public
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
libroardsp/convert.c
r2098 r2099 33 33 */ 34 34 35 #define DEBUG 35 36 #include "libroardsp.h" 36 37 //#define free(p) {ROAR_WARN("free(%p) = ?", (p)); free((p)); ROAR_WARN("free(%p): OK", (p));} … … 745 746 746 747 // calcumate number of input samples: 747 samples = (inlen * 8) / (from->channels * from->bits); 748 samples = (inlen * 8) / (from->bits); 749 750 ROAR_WARN("roar_conv2(*): input samples: %i", samples); 748 751 749 752 // calculate size per frame … … 751 754 752 755 needed_buffer *= samples; 756 needed_buffer /= from->channels; 753 757 754 758 if ( from->rate < to->rate ) … … 797 801 if ( to->channels > from->channels ) { 798 802 ROAR_WARN("roar_conv2(*): channels: %i->%i", from->channels, to->channels); 799 if ( roar_conv_chans(out, cin, samples , from->channels, to->channels, cinfo.bits) == -1 )803 if ( roar_conv_chans(out, cin, samples/from->channels, from->channels, to->channels, cinfo.bits) == -1 ) 800 804 return -1; 801 805
Note: See TracChangeset
for help on using the changeset viewer.