diff options
author | jbrjake <jb.rubin@gmail.com> | 2008-06-04 19:56:54 +0000 |
---|---|---|
committer | jbrjake <jb.rubin@gmail.com> | 2008-06-04 19:56:54 +0000 |
commit | 61f09e3aaf680a46703bad685c451c5a83b610cc (patch) | |
tree | 04a0e8c17bafcf116c0fa72dd73a257ba2c6d77b /test/test.c | |
parent | d84fc0bd76e38e708ba392f98b885cd5a54a9c01 (diff) |
CLI: Use the source's audio samplerate unless told otherwise.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1494 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'test/test.c')
-rw-r--r-- | test/test.c | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/test/test.c b/test/test.c index f4e415452..b30af9a8c 100644 --- a/test/test.c +++ b/test/test.c @@ -471,7 +471,6 @@ static int HandleEvents( hb_handle_t * h ) vcodec = HB_VCODEC_X264; job->vbitrate = 1000; default_abitrate = 160; - default_arate = 48000; default_acodec = HB_ACODEC_FAAC; x264opts = strdup("ref=5:mixed-refs:bframes=6:bime:weightb:b-rdo:direct=auto:b-pyramid:me=umh:subme=5:analyse=all:8x8dct:trellis=1:nr=150:no-fast-pskip:filter=2,2"); deinterlace = 1; @@ -519,7 +518,6 @@ static int HandleEvents( hb_handle_t * h ) mux = HB_MUX_MP4; job->vbitrate = 512; default_abitrate = 128; - default_arate = 48000; default_acodec = HB_ACODEC_FAAC; job->width = 512; job->chapter_markers = 1; @@ -531,7 +529,6 @@ static int HandleEvents( hb_handle_t * h ) vcodec = HB_VCODEC_X264; size = 695; default_abitrate = 128; - default_arate = 48000; default_acodec = HB_ACODEC_FAAC; job->width = 640; x264opts = strdup("ref=3:mixed-refs:bframes=16:bime:weightb:b-rdo:b-pyramid:direct=auto:me=umh:subme=6:trellis=1:analyse=all:8x8dct:no-fast-pskip"); @@ -545,7 +542,6 @@ static int HandleEvents( hb_handle_t * h ) mux = HB_MUX_MP4; job->vbitrate = 1000; default_abitrate = 160; - default_arate = 48000; default_acodec = HB_ACODEC_FAAC; } @@ -635,7 +631,6 @@ static int HandleEvents( hb_handle_t * h ) vcodec = HB_VCODEC_X264; job->vbitrate = 1500; default_abitrate = 160; - default_arate = 48000; default_acodec = HB_ACODEC_FAAC; x264opts = strdup("ref=2:bframes=2:subme=5:me=umh"); job->chapter_markers = 1; @@ -650,7 +645,6 @@ static int HandleEvents( hb_handle_t * h ) vcodec = HB_VCODEC_X264; job->vbitrate = 2500; default_abitrate = 160; - default_arate = 48000; default_acodec = HB_ACODEC_FAAC; x264opts = strdup("level=41:subme=5:me=umh"); pixelratio = 1; @@ -674,7 +668,6 @@ static int HandleEvents( hb_handle_t * h ) vcodec = HB_VCODEC_X264; job->vbitrate = 2000; default_abitrate = 160; - default_arate = 48000; default_acodec = HB_ACODEC_FAAC; x264opts = strdup("ref=3:mixed-refs:bframes=3:bime:weightb:b-rdo:direct=auto:me=umh:subme=5:analyse=all:trellis=1:no-fast-pskip"); job->chapter_markers = 1; @@ -689,7 +682,6 @@ static int HandleEvents( hb_handle_t * h ) vcodec = HB_VCODEC_X264; job->vbitrate = 1300; default_abitrate = 160; - default_arate = 48000; default_acodec = HB_ACODEC_FAAC; x264opts = strdup("ref=3:mixed-refs:bframes=6:bime:weightb:direct=auto:b-pyramid:me=umh:subme=6:analyse=all:8x8dct:trellis=1:nr=150:no-fast-pskip"); deinterlace = 1; @@ -707,7 +699,6 @@ static int HandleEvents( hb_handle_t * h ) vcodec = HB_VCODEC_X264; job->vbitrate = 2000; default_abitrate = 160; - default_arate = 48000; default_acodec = HB_ACODEC_FAAC; x264opts = strdup("level=40:ref=2:mixed-refs:bframes=3:bime:weightb:b-rdo:direct=auto:b-pyramid:me=umh:subme=5:analyse=all:no-fast-pskip:filter=-2,-1"); pixelratio = 1; @@ -1009,8 +1000,8 @@ static int HandleEvents( hb_handle_t * h ) if (!is_sample_rate_valid(arate)) { - fprintf(stderr, "Invalid sample rate %d, using default %d\n", arate, default_arate); - arate = default_arate; + fprintf(stderr, "Invalid sample rate %d, using input rate %d\n", arate, audio->in.samplerate); + arate = audio->in.samplerate; } audio->out.samplerate = arate; @@ -1026,7 +1017,7 @@ static int HandleEvents( hb_handle_t * h ) * Unless we only have one input, then use that for all tracks. */ if (i != 1) - arate = default_arate; + arate = audio->in.samplerate; for ( ; i < num_audio_tracks; i++) { audio = hb_list_audio_config_item(job->list_audio, i); |