From: kramm Date: Sun, 19 May 2002 18:13:43 +0000 (+0000) Subject: * removed "printf"s X-Git-Tag: release-0-3-0-preview~21 X-Git-Url: http://git.asbjorn.it/?a=commitdiff_plain;h=481f699009f197fcec789c94996f4d81fef364e0;p=swftools.git * removed "printf"s * changed blocksize to 1152*2. --- diff --git a/src/wav2swf.c b/src/wav2swf.c index 6bf2ec7..8dfd0db 100644 --- a/src/wav2swf.c +++ b/src/wav2swf.c @@ -10,6 +10,7 @@ #include #include #include "../lib/rfxswf.h" +#include "../lib/log.h" #include "../lib/args.h" #include "wav.h" @@ -54,7 +55,7 @@ void args_callback_usage(char*name) printf("Usage: %s [-o filename] file.wav\n", name); printf("\t-v , --verbose\t\t\t Be more verbose\n"); printf("\t-o , --output filename\t\t set output filename (default: output.swf)\n"); - printf("\t-V , --version\t\t Print program version and exit\n"); + printf("\t-V , --version\t\t\t Print program version and exit\n"); } int args_callback_command(char*name,char*val) { @@ -90,23 +91,15 @@ int main (int argc,char ** argv) exit(1); } convertWAV2mono(&wav,&wav2, 44100); - printWAVInfo(&wav); - printWAVInfo(&wav2); + //printWAVInfo(&wav); + //printWAVInfo(&wav2); samples = (U16*)wav2.data; numsamples = wav2.size/2; - /* the following is a big hack to prevent against - periods of total silence- these get written as - blocks of length 0 by bladeenc, which causes - the flashplayer to crash */ - - for(t=0;t Writing block %d", t); - block1 = &samples[(t*2+0)*blocksize]; - block2 = &samples[(t*2+1)*blocksize]; - swf_SetSoundStreamBlock(tag, block1, blocksize,1); - swf_SetSoundStreamBlock(tag, block2, blocksize,0); + block1 = &samples[t*2*blocksize]; + swf_SetSoundStreamBlock(tag, block1, blocksize*2,1); tag = swf_InsertTag(tag, ST_SHOWFRAME); }