Delete rtc_base/format_macros.h

It defined RTC_PRIuS, which was needed for compatibility with MSVC
prior to version 2015.

Bug: webrtc:6424
Change-Id: I5668d473376201cad3e8da65927c967fc397804b
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/261314
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Reviewed-by: Tomas Gunnarsson <tommi@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#36814}
This commit is contained in:
Niels Möller
2022-05-09 09:21:14 +02:00
committed by WebRTC LUCI CQ
parent cc50b04c02
commit ea1e6f44f8
31 changed files with 68 additions and 166 deletions

View File

@ -22,7 +22,6 @@
/* include API */
#include "modules/audio_coding/codecs/isac/main/include/isac.h"
#include "modules/audio_coding/codecs/isac/main/util/utility.h"
#include "rtc_base/format_macros.h"
/* Defines */
#define SEED_FILE \
@ -887,7 +886,7 @@ int main(int argc, char* argv[]) {
#endif
}
printf("\n");
printf("total bits = %" RTC_PRIuS " bits\n", totalbits);
printf("total bits = %zu bits\n", totalbits);
printf("measured average bitrate = %0.3f kbits/s\n",
(double)totalbits * (sampFreqKHz) / totalsmpls);
if (doTransCoding) {
@ -906,14 +905,16 @@ int main(int argc, char* argv[]) {
(100 * runtime / length_file));
if (maxStreamLen30 != 0) {
printf("Maximum payload size 30ms Frames %" RTC_PRIuS
" bytes (%0.3f kbps)\n",
maxStreamLen30, maxStreamLen30 * 8 / 30.);
printf(
"Maximum payload size 30ms Frames %zu"
" bytes (%0.3f kbps)\n",
maxStreamLen30, maxStreamLen30 * 8 / 30.);
}
if (maxStreamLen60 != 0) {
printf("Maximum payload size 60ms Frames %" RTC_PRIuS
" bytes (%0.3f kbps)\n",
maxStreamLen60, maxStreamLen60 * 8 / 60.);
printf(
"Maximum payload size 60ms Frames %zu"
" bytes (%0.3f kbps)\n",
maxStreamLen60, maxStreamLen60 * 8 / 60.);
}
// fprintf(stderr, "\n");
@ -921,12 +922,12 @@ int main(int argc, char* argv[]) {
fprintf(stderr, " %0.1f kbps",
(double)totalbits * (sampFreqKHz) / totalsmpls);
if (maxStreamLen30 != 0) {
fprintf(stderr, " plmax-30ms %" RTC_PRIuS " bytes (%0.0f kbps)",
maxStreamLen30, maxStreamLen30 * 8 / 30.);
fprintf(stderr, " plmax-30ms %zu bytes (%0.0f kbps)", maxStreamLen30,
maxStreamLen30 * 8 / 30.);
}
if (maxStreamLen60 != 0) {
fprintf(stderr, " plmax-60ms %" RTC_PRIuS " bytes (%0.0f kbps)",
maxStreamLen60, maxStreamLen60 * 8 / 60.);
fprintf(stderr, " plmax-60ms %zu bytes (%0.0f kbps)", maxStreamLen60,
maxStreamLen60 * 8 / 60.);
}
if (doTransCoding) {
fprintf(stderr, " transcoding rate %.0f kbps",

View File

@ -28,7 +28,6 @@
/* include API */
#include "modules/audio_coding/codecs/isac/main/include/isac.h"
#include "modules/audio_coding/codecs/isac/main/util/utility.h"
#include "rtc_base/format_macros.h"
/* max number of samples per frame (= 60 ms frame) */
#define MAX_FRAMESAMPLES_SWB 1920
@ -420,7 +419,7 @@ int main(int argc, char* argv[]) {
printf("\n");
printf("Measured bit-rate........... %0.3f kbps\n", rate);
printf("Measured RCU bit-ratre...... %0.3f kbps\n", rateRCU);
printf("Maximum bit-rate/payloadsize %0.3f / %" RTC_PRIuS "\n",
printf("Maximum bit-rate/payloadsize %0.3f / %zu\n",
maxStreamLen * 8 / 0.03, maxStreamLen);
printf("Measured packet-loss........ %0.1f%% \n",
100.0f * (float)lostPacketCntr / (float)packetCntr);

View File

@ -10,7 +10,6 @@
#include "api/audio_codecs/opus/audio_encoder_opus.h"
#include "modules/audio_coding/neteq/tools/audio_loop.h"
#include "rtc_base/format_macros.h"
#include "rtc_base/time_utils.h"
#include "test/gtest.h"
#include "test/testsupport/file_utils.h"

View File

@ -11,7 +11,6 @@
#include <memory>
#include "modules/audio_coding/codecs/opus/opus_interface.h"
#include "rtc_base/format_macros.h"
#include "test/gtest.h"
#include "test/testsupport/file_utils.h"
@ -70,8 +69,7 @@ class OpusFecTest : public TestWithParam<coding_param> {
void OpusFecTest::SetUp() {
channels_ = get<0>(GetParam());
bit_rate_ = get<1>(GetParam());
printf("Coding %" RTC_PRIuS " channel signal at %d bps.\n", channels_,
bit_rate_);
printf("Coding %zu channel signal at %d bps.\n", channels_, bit_rate_);
in_filename_ = test::ResourcePath(get<2>(GetParam()), get<3>(GetParam()));

View File

@ -11,7 +11,6 @@
#include "modules/audio_coding/codecs/tools/audio_codec_speed_test.h"
#include "rtc_base/checks.h"
#include "rtc_base/format_macros.h"
#include "test/gtest.h"
#include "test/testsupport/file_utils.h"
@ -100,7 +99,7 @@ void AudioCodecSpeedTest::EncodeDecode(size_t audio_duration_sec) {
size_t time_now_ms = 0;
float time_ms;
printf("Coding %d kHz-sampled %" RTC_PRIuS "-channel audio at %d bps ...\n",
printf("Coding %d kHz-sampled %zu-channel audio at %d bps ...\n",
input_sampling_khz_, channels_, bit_rate_);
while (time_now_ms < audio_duration_sec * 1000) {