From a40848c80f8a002f2f4225c1c16a34743cce54db Mon Sep 17 00:00:00 2001 From: Wan-Teh Chang Date: Tue, 9 Jul 2024 16:57:20 -0700 Subject: [PATCH] Do not include vpx_version.h Replace the VERSION_STRING_NOSP macro by the public API function vpx_codec_version_str(). Treat vpx_version.h as an absolutely internal header of the libvpx library. Change-Id: I86ba8548a62adae91ae7f5caad98169707f3fc64 --- test/decode_perf_test.cc | 6 +++--- test/encode_perf_test.cc | 5 ++--- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/test/decode_perf_test.cc b/test/decode_perf_test.cc index 383fd2d8964..8952b3a9e31 100644 --- a/test/decode_perf_test.cc +++ b/test/decode_perf_test.cc @@ -19,9 +19,9 @@ #include "test/md5_helper.h" #include "test/util.h" #include "test/webm_video_source.h" +#include "vpx/vpx_codec.h" #include "vpx_ports/vpx_timer.h" #include "./ivfenc.h" -#include "./vpx_version.h" using std::make_tuple; @@ -98,7 +98,7 @@ TEST_P(DecodePerfTest, PerfTest) { printf("{\n"); printf("\t\"type\" : \"decode_perf_test\",\n"); - printf("\t\"version\" : \"%s\",\n", VERSION_STRING_NOSP); + printf("\t\"version\" : \"%s\",\n", vpx_codec_version_str()); printf("\t\"videoName\" : \"%s\",\n", video_name); printf("\t\"threadCount\" : %u,\n", threads); printf("\t\"decodeTimeSecs\" : %f,\n", elapsed_secs); @@ -249,7 +249,7 @@ TEST_P(VP9NewEncodeDecodePerfTest, PerfTest) { printf("{\n"); printf("\t\"type\" : \"decode_perf_test\",\n"); - printf("\t\"version\" : \"%s\",\n", VERSION_STRING_NOSP); + printf("\t\"version\" : \"%s\",\n", vpx_codec_version_str()); printf("\t\"videoName\" : \"%s\",\n", kNewEncodeOutputFile); printf("\t\"threadCount\" : %u,\n", threads); printf("\t\"decodeTimeSecs\" : %f,\n", elapsed_secs); diff --git a/test/encode_perf_test.cc b/test/encode_perf_test.cc index b97a948e1a0..5a79c70bc80 100644 --- a/test/encode_perf_test.cc +++ b/test/encode_perf_test.cc @@ -10,13 +10,12 @@ #include #include #include "third_party/googletest/src/include/gtest/gtest.h" -#include "./vpx_config.h" -#include "./vpx_version.h" #include "test/codec_factory.h" #include "test/encode_test_driver.h" #include "test/i420_video_source.h" #include "test/util.h" #include "test/y4m_video_source.h" +#include "vpx/vpx_codec.h" #include "vpx_ports/vpx_timer.h" namespace { @@ -170,7 +169,7 @@ TEST_P(VP9EncodePerfTest, PerfTest) { printf("{\n"); printf("\t\"type\" : \"encode_perf_test\",\n"); - printf("\t\"version\" : \"%s\",\n", VERSION_STRING_NOSP); + printf("\t\"version\" : \"%s\",\n", vpx_codec_version_str()); printf("\t\"videoName\" : \"%s\",\n", display_name.c_str()); printf("\t\"encodeTimeSecs\" : %f,\n", elapsed_secs); printf("\t\"totalFrames\" : %u,\n", frames);