OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2013 The WebM project authors. All Rights Reserved. | 2 * Copyright (c) 2013 The WebM project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
85 decoder.DecodeFrame(video.cxdata(), video.frame_size()); | 85 decoder.DecodeFrame(video.cxdata(), video.frame_size()); |
86 } | 86 } |
87 | 87 |
88 vpx_usec_timer_mark(&t); | 88 vpx_usec_timer_mark(&t); |
89 const double elapsed_secs = double(vpx_usec_timer_elapsed(&t)) | 89 const double elapsed_secs = double(vpx_usec_timer_elapsed(&t)) |
90 / kUsecsInSec; | 90 / kUsecsInSec; |
91 const unsigned frames = video.frame_number(); | 91 const unsigned frames = video.frame_number(); |
92 const double fps = double(frames) / elapsed_secs; | 92 const double fps = double(frames) / elapsed_secs; |
93 | 93 |
94 printf("{\n"); | 94 printf("{\n"); |
| 95 printf("\t\"type\" : \"decode_perf_test\",\n"); |
95 printf("\t\"version\" : \"%s\",\n", VERSION_STRING_NOSP); | 96 printf("\t\"version\" : \"%s\",\n", VERSION_STRING_NOSP); |
96 printf("\t\"videoName\" : \"%s\",\n", video_name); | 97 printf("\t\"videoName\" : \"%s\",\n", video_name); |
97 printf("\t\"threadCount\" : %u,\n", threads); | 98 printf("\t\"threadCount\" : %u,\n", threads); |
98 printf("\t\"decodeTimeSecs\" : %f,\n", elapsed_secs); | 99 printf("\t\"decodeTimeSecs\" : %f,\n", elapsed_secs); |
99 printf("\t\"totalFrames\" : %u,\n", frames); | 100 printf("\t\"totalFrames\" : %u,\n", frames); |
100 printf("\t\"framesPerSecond\" : %f\n", fps); | 101 printf("\t\"framesPerSecond\" : %f\n", fps); |
101 printf("}\n"); | 102 printf("}\n"); |
102 } | 103 } |
103 | 104 |
104 INSTANTIATE_TEST_CASE_P(VP9, DecodePerfTest, | 105 INSTANTIATE_TEST_CASE_P(VP9, DecodePerfTest, |
105 ::testing::ValuesIn(kVP9DecodePerfVectors)); | 106 ::testing::ValuesIn(kVP9DecodePerfVectors)); |
106 | 107 |
107 } // namespace | 108 } // namespace |
OLD | NEW |