X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=src%2Fwav2swf.c;h=f6d3b2c121e4f0878c7d0c7301a9cac556819cef;hb=90e82ae6c7f404670088aba9bebd012ce90ba932;hp=70d51b1d6ff4dc8c9e926f09452d13878a306939;hpb=f92afaf4b15ed78999cd87e0e7b36ce8d5d7f299;p=swftools.git diff --git a/src/wav2swf.c b/src/wav2swf.c index 70d51b1..f6d3b2c 100644 --- a/src/wav2swf.c +++ b/src/wav2swf.c @@ -40,7 +40,6 @@ static struct options_t options[] = { {"o", "output"}, {"r", "framerate"}, {"s", "samplerate"}, -{"b", "bitrate"}, {"d", "definesound"}, {"l", "loop"}, {"C", "cgi"}, @@ -163,7 +162,6 @@ void args_callback_usage(char *name) printf("-o , --output Explicitly specify output file. (Otherwise, output will go to output.swf)\n"); printf("-r , --framerate Set file framerate to frames per second.\n"); printf("-s , --samplerate Set samplerate to frames per second (default: 11025).\n"); - printf("-b , --bitrate bps Set mp3 bitrate to .\n"); printf("-d , --definesound Generate a DefineSound tag instead of streaming sound.\n"); printf("-l , --loop n (Only used with -d)\n"); printf("-C , --cgi For use as CGI- prepend http header, write to stdout.\n"); @@ -240,6 +238,13 @@ int main (int argc,char ** argv) samples = (U16*)wav2.data; numsamples = wav2.size/2; +#ifdef WORDS_BIGENDIAN + /* swap bytes */ + for(t=0;t>8)&0xff | (samples[t]<<8)&0xff00; + } +#endif + if(numsamples%blocksize != 0) { // apply padding, so that block is a multiple of blocksize