From 0133c6fd36a20c2e76ea808ae5da606cac52ff26 Mon Sep 17 00:00:00 2001 From: kramm Date: Mon, 6 Jan 2003 18:46:34 +0000 Subject: [PATCH] changed -f to -r option. --- src/wav2swf.1 | 2 +- src/wav2swf.c | 7 ++++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/wav2swf.1 b/src/wav2swf.1 index 58ef992..ff350f1 100644 --- a/src/wav2swf.1 +++ b/src/wav2swf.1 @@ -19,7 +19,7 @@ Print version info and exit \fB\-o\fR, \fB\-\-output\fR \fIfilename\fR Explicitly specify output file. (Otherwise, output will go to output.swf) .TP -\fB\-f\fR, \fB\-\-framerate\fR \fIfps\fR +\fB\-r\fR, \fB\-\-framerate\fR \fIfps\fR Set file framerate to \fIfps\fR frames per second. .TP \fB\-l\fR, \fB\-\-loop\fR \fIn\fR diff --git a/src/wav2swf.c b/src/wav2swf.c index 70315b2..ebd1ad1 100644 --- a/src/wav2swf.c +++ b/src/wav2swf.c @@ -24,7 +24,7 @@ struct options_t options[] = {"v","verbose"}, {"d","definesound"}, {"l","loop"}, - {"f","framerate"}, + {"r","framerate"}, {"V","version"}, {0,0} }; @@ -55,7 +55,7 @@ int args_callback_option(char*name,char*val) verbose ++; return 0; } - else if(!strcmp(name, "f")) { + else if(!strcmp(name, "r")) { float f; sscanf(val, "%f", &f); framerate = f*256; @@ -77,7 +77,7 @@ void args_callback_usage(char*name) printf("\t-v , --verbose\t\t\t Be more verbose\n"); printf("\t-d , --definesound\t\t\t Generate a DefineSound tag instead of streaming sound\n"); printf("\t-l , --loop n\t\t\t Loop sound n times (implies -d)\n"); - printf("\t-f , --framerate fps\t\t\t Set framerate to fps frames per seond\n"); + printf("\t-r , --framerate fps\t\t\t Set framerate to fps frames per seond\n"); printf("\t-o , --output filename\t\t set output filename (default: output.swf)\n"); printf("\t-V , --version\t\t\t Print program version and exit\n"); } @@ -162,6 +162,7 @@ int main (int argc,char ** argv) logf(" Writing block %d", t); block1 = &samples[t*2*blocksize]; swf_SetSoundStreamBlock(tag, block1, 1); + oldframe = (int)framepos; framepos += framesperblock; newframe = (int)framepos; -- 1.7.10.4