Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(593)

Side by Side Diff: source/libvpx/test/vpx_temporal_svc_encoder.sh

Issue 390713002: libvpx: Pull from upstream (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/deps/third_party/libvpx/
Patch Set: libvpx: Pull from upstream Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « source/libvpx/test/vp9_thread_test.cc ('k') | source/libvpx/vp8/decoder/onyxd_if.c » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/bin/sh 1 #!/bin/sh
2 ## 2 ##
3 ## Copyright (c) 2014 The WebM project authors. All Rights Reserved. 3 ## Copyright (c) 2014 The WebM project authors. All Rights Reserved.
4 ## 4 ##
5 ## Use of this source code is governed by a BSD-style license 5 ## Use of this source code is governed by a BSD-style license
6 ## that can be found in the LICENSE file in the root of the source 6 ## that can be found in the LICENSE file in the root of the source
7 ## tree. An additional intellectual property rights grant can be found 7 ## tree. An additional intellectual property rights grant can be found
8 ## in the file PATENTS. All contributing project authors may 8 ## in the file PATENTS. All contributing project authors may
9 ## be found in the AUTHORS file in the root of the source tree. 9 ## be found in the AUTHORS file in the root of the source tree.
10 ## 10 ##
11 ## This file tests the libvpx vpx_temporal_svc_encoder example. To add new 11 ## This file tests the libvpx vpx_temporal_svc_encoder example. To add new
12 ## tests to this file, do the following: 12 ## tests to this file, do the following:
13 ## 1. Write a shell function (this is your test). 13 ## 1. Write a shell function (this is your test).
14 ## 2. Add the function to vpx_tsvc_encoder_tests (on a new line). 14 ## 2. Add the function to vpx_tsvc_encoder_tests (on a new line).
15 ## 15 ##
16 . $(dirname $0)/tools_common.sh 16 . $(dirname $0)/tools_common.sh
17 17
18 # Environment check: $YUV_RAW_INPUT is required. 18 # Environment check: $YUV_RAW_INPUT is required.
19 vpx_tsvc_encoder_verify_environment() { 19 vpx_tsvc_encoder_verify_environment() {
20 if [ ! -e "${YUV_RAW_INPUT}" ]; then 20 if [ ! -e "${YUV_RAW_INPUT}" ]; then
21 echo "Libvpx test data must exist in LIBVPX_TEST_DATA_PATH." 21 echo "Libvpx test data must exist in LIBVPX_TEST_DATA_PATH."
22 return 1 22 return 1
23 fi 23 fi
24 if [ "$(vpx_config_option_enabled CONFIG_TEMPORAL_DENOISING)" != "yes" ]; then
25 elog "Warning: Temporal denoising is disabled! Spatial denoising will be " \
26 "used instead, which is probably not what you want for this test."
27 fi
24 } 28 }
25 29
26 # Runs vpx_temporal_svc_encoder using the codec specified by $1 and output file 30 # Runs vpx_temporal_svc_encoder using the codec specified by $1 and output file
27 # name by $2. Additional positional parameters are passed directly to 31 # name by $2. Additional positional parameters are passed directly to
28 # vpx_temporal_svc_encoder. 32 # vpx_temporal_svc_encoder.
29 vpx_tsvc_encoder() { 33 vpx_tsvc_encoder() {
30 local encoder="${LIBVPX_BIN_PATH}/vpx_temporal_svc_encoder" 34 local encoder="${LIBVPX_BIN_PATH}/vpx_temporal_svc_encoder"
31 encoder="${encoder}${VPX_TEST_EXE_SUFFIX}" 35 encoder="${encoder}${VPX_TEST_EXE_SUFFIX}"
32 local codec="$1" 36 local codec="$1"
33 local output_file_base="$2" 37 local output_file_base="$2"
34 local output_file="${VPX_TEST_OUTPUT_DIR}/${output_file_base}" 38 local output_file="${VPX_TEST_OUTPUT_DIR}/${output_file_base}"
35 local timebase_num="1" 39 local timebase_num="1"
36 local timebase_den="1000" 40 local timebase_den="1000"
37 local speed="6" 41 local speed="6"
38 local frame_drop_thresh="30" 42 local frame_drop_thresh="30"
39 43
40 shift 2 44 shift 2
41 45
42 if [ ! -x "${encoder}" ]; then 46 if [ ! -x "${encoder}" ]; then
43 elog "${encoder} does not exist or is not executable." 47 elog "${encoder} does not exist or is not executable."
44 return 1 48 return 1
45 fi 49 fi
46 50
47 eval "${encoder}" "${YUV_RAW_INPUT}" "${output_file}" "${codec}" \ 51 eval "${VPX_TEST_PREFIX}" "${encoder}" "${YUV_RAW_INPUT}" "${output_file}" \
48 "${YUV_RAW_INPUT_WIDTH}" "${YUV_RAW_INPUT_HEIGHT}" \ 52 "${codec}" "${YUV_RAW_INPUT_WIDTH}" "${YUV_RAW_INPUT_HEIGHT}" \
49 "${timebase_num}" "${timebase_den}" "${speed}" "${frame_drop_thresh}" \ 53 "${timebase_num}" "${timebase_den}" "${speed}" "${frame_drop_thresh}" \
50 "$@" \ 54 "$@" \
51 ${devnull} 55 ${devnull}
52 } 56 }
53 57
54 # Confirms that all expected output files exist given the output file name 58 # Confirms that all expected output files exist given the output file name
55 # passed to vpx_temporal_svc_encoder. 59 # passed to vpx_temporal_svc_encoder.
56 # The file name passed to vpx_temporal_svc_encoder is joined with the stream 60 # The file name passed to vpx_temporal_svc_encoder is joined with the stream
57 # number and the extension .ivf to produce per stream output files. Here $1 is 61 # number and the extension .ivf to produce per stream output files. Here $1 is
58 # file name, and $2 is expected number of files. 62 # file name, and $2 is expected number of files.
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after
277 vpx_tsvc_encoder_vp9_mode_4 281 vpx_tsvc_encoder_vp9_mode_4
278 vpx_tsvc_encoder_vp9_mode_5 282 vpx_tsvc_encoder_vp9_mode_5
279 vpx_tsvc_encoder_vp9_mode_6 283 vpx_tsvc_encoder_vp9_mode_6
280 vpx_tsvc_encoder_vp9_mode_7 284 vpx_tsvc_encoder_vp9_mode_7
281 vpx_tsvc_encoder_vp9_mode_8 285 vpx_tsvc_encoder_vp9_mode_8
282 vpx_tsvc_encoder_vp9_mode_9 286 vpx_tsvc_encoder_vp9_mode_9
283 vpx_tsvc_encoder_vp9_mode_10 287 vpx_tsvc_encoder_vp9_mode_10
284 vpx_tsvc_encoder_vp9_mode_11" 288 vpx_tsvc_encoder_vp9_mode_11"
285 289
286 run_tests vpx_tsvc_encoder_verify_environment "${vpx_tsvc_encoder_tests}" 290 run_tests vpx_tsvc_encoder_verify_environment "${vpx_tsvc_encoder_tests}"
OLDNEW
« no previous file with comments | « source/libvpx/test/vp9_thread_test.cc ('k') | source/libvpx/vp8/decoder/onyxd_if.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698