Remove warning suppression flags from sdk/android.
Bug: webrtc:9251 Change-Id: Iafd10a09dd34dfdd590711bb5c6a36d08298d1e7 Reviewed-on: https://webrtc-review.googlesource.com/79882 Reviewed-by: Sami Kalliomäki <sakal@webrtc.org> Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org> Cr-Commit-Position: refs/heads/master@{#23513}
This commit is contained in:
committed by
Commit Bot
parent
267287407a
commit
ab55c34ef1
@ -22,18 +22,6 @@ group("android") {
|
||||
}
|
||||
}
|
||||
|
||||
config("libjingle_peerconnection_jni_warnings_config") {
|
||||
# The warnings below are enabled by default. Since GN orders compiler flags
|
||||
# for a target before flags from configs, the only way to disable such
|
||||
# warnings is by having them in a separate config, loaded from the target.
|
||||
if (!is_win) {
|
||||
cflags = [
|
||||
"-Wno-sign-compare",
|
||||
"-Wno-unused-variable",
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
generate_jni("generated_base_jni") {
|
||||
sources = [
|
||||
"api/org/webrtc/NetworkMonitor.java",
|
||||
@ -347,8 +335,6 @@ rtc_static_library("video_jni") {
|
||||
"src/jni/yuvhelper.cc",
|
||||
]
|
||||
|
||||
configs += [ ":libjingle_peerconnection_jni_warnings_config" ]
|
||||
|
||||
# TODO(jschuh): Bug 1348: fix this warning.
|
||||
configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
|
||||
|
||||
@ -569,8 +555,6 @@ rtc_static_library("peerconnection_jni") {
|
||||
"src/jni/pc/turncustomizer.h",
|
||||
]
|
||||
|
||||
configs += [ ":libjingle_peerconnection_jni_warnings_config" ]
|
||||
|
||||
if (is_clang) {
|
||||
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
|
||||
suppressed_configs += [
|
||||
@ -645,8 +629,6 @@ rtc_static_library("libjingle_peerconnection_metrics_default_jni") {
|
||||
"src/jni/androidmetrics.cc",
|
||||
]
|
||||
|
||||
configs += [ ":libjingle_peerconnection_jni_warnings_config" ]
|
||||
|
||||
deps = [
|
||||
":base_jni",
|
||||
":generated_metrics_jni",
|
||||
|
||||
@ -24,6 +24,7 @@
|
||||
#include "rtc_base/bind.h"
|
||||
#include "rtc_base/checks.h"
|
||||
#include "rtc_base/logging.h"
|
||||
#include "rtc_base/numerics/safe_conversions.h"
|
||||
#include "rtc_base/scoped_ref_ptr.h"
|
||||
#include "rtc_base/thread.h"
|
||||
#include "rtc_base/timeutils.h"
|
||||
@ -120,7 +121,7 @@ class MediaCodecVideoDecoder : public VideoDecoder, public rtc::MessageHandler {
|
||||
int current_bytes_; // Encoded bytes in the current statistics interval.
|
||||
int current_decoding_time_ms_; // Overall decoding time in the current second
|
||||
int current_delay_time_ms_; // Overall delay time in the current second.
|
||||
uint32_t max_pending_frames_; // Maximum number of pending input frames.
|
||||
int32_t max_pending_frames_; // Maximum number of pending input frames.
|
||||
H264BitstreamParser h264_bitstream_parser_;
|
||||
std::deque<rtc::Optional<uint8_t>> pending_frame_qps_;
|
||||
|
||||
@ -482,7 +483,8 @@ int32_t MediaCodecVideoDecoder::DecodeOnCodecThread(
|
||||
uint8_t* buffer =
|
||||
reinterpret_cast<uint8_t*>(jni->GetDirectBufferAddress(j_input_buffer));
|
||||
RTC_CHECK(buffer) << "Indirect buffer??";
|
||||
int64_t buffer_capacity = jni->GetDirectBufferCapacity(j_input_buffer);
|
||||
size_t buffer_capacity = rtc::dchecked_cast<size_t>(
|
||||
jni->GetDirectBufferCapacity(j_input_buffer));
|
||||
if (CheckException(jni) || buffer_capacity < inputImage._length) {
|
||||
ALOGE << "Input frame size "<< inputImage._length <<
|
||||
" is bigger than buffer size " << buffer_capacity;
|
||||
|
||||
@ -79,7 +79,7 @@ __android_log_print(ANDROID_LOG_VERBOSE, TAG_ENCODER, __VA_ARGS__)
|
||||
|
||||
namespace {
|
||||
// Maximum time limit between incoming frames before requesting a key frame.
|
||||
const size_t kFrameDiffThresholdMs = 350;
|
||||
const int64_t kFrameDiffThresholdMs = 350;
|
||||
const int kMinKeyFrameInterval = 6;
|
||||
const char kCustomQPThresholdsFieldTrial[] = "WebRTC-CustomQPThresholds";
|
||||
} // namespace
|
||||
@ -213,8 +213,8 @@ class MediaCodecVideoEncoder : public VideoEncoder {
|
||||
bool inited_;
|
||||
bool use_surface_;
|
||||
enum libyuv::FourCC encoder_fourcc_; // Encoder color space format.
|
||||
int last_set_bitrate_kbps_; // Last-requested bitrate in kbps.
|
||||
int last_set_fps_; // Last-requested frame rate.
|
||||
uint32_t last_set_bitrate_kbps_; // Last-requested bitrate in kbps.
|
||||
uint32_t last_set_fps_; // Last-requested frame rate.
|
||||
int64_t current_timestamp_us_; // Current frame timestamps in us.
|
||||
int frames_received_; // Number of frames received by encoder.
|
||||
int frames_encoded_; // Number of frames encoded by encoder.
|
||||
@ -923,7 +923,9 @@ int32_t MediaCodecVideoEncoder::SetRateAllocation(
|
||||
last_set_fps_ = frame_rate;
|
||||
}
|
||||
bool ret = Java_MediaCodecVideoEncoder_setRates(
|
||||
jni, j_media_codec_video_encoder_, last_set_bitrate_kbps_, last_set_fps_);
|
||||
jni, j_media_codec_video_encoder_,
|
||||
rtc::dchecked_cast<int>(last_set_bitrate_kbps_),
|
||||
rtc::dchecked_cast<int>(last_set_fps_));
|
||||
if (CheckException(jni) || !ret) {
|
||||
ProcessHWError(true /* reset_if_fallback_unavailable */);
|
||||
return sw_fallback_required_ ? WEBRTC_VIDEO_CODEC_OK
|
||||
|
||||
@ -159,7 +159,7 @@ void VideoDecoderWrapper::OnDecodedFrame(
|
||||
const JavaRef<jobject>& j_decode_time_ms,
|
||||
const JavaRef<jobject>& j_qp) {
|
||||
RTC_DCHECK_RUNS_SERIALIZED(&callback_race_checker_);
|
||||
const uint64_t timestamp_ns = GetJavaVideoFrameTimestampNs(env, j_frame);
|
||||
const int64_t timestamp_ns = GetJavaVideoFrameTimestampNs(env, j_frame);
|
||||
|
||||
FrameExtraInfo frame_extra_info;
|
||||
{
|
||||
|
||||
@ -70,7 +70,7 @@ class VideoEncoderWrapper : public VideoEncoder {
|
||||
|
||||
private:
|
||||
struct FrameExtraInfo {
|
||||
uint64_t capture_time_ns; // Used as an identifier of the frame.
|
||||
int64_t capture_time_ns; // Used as an identifier of the frame.
|
||||
|
||||
uint32_t timestamp_rtp;
|
||||
};
|
||||
|
||||
@ -200,9 +200,6 @@ void Matrix::Crop(float xFraction,
|
||||
Multiply(crop_matrix, old.elem_, this->elem_);
|
||||
}
|
||||
|
||||
// Aligning pointer to 64 bytes for improved performance, e.g. use SIMD.
|
||||
static const int kBufferAlignment = 64;
|
||||
|
||||
NativeHandleImpl::NativeHandleImpl(int id, const Matrix& matrix)
|
||||
: oes_texture_id(id), sampling_matrix(matrix) {}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user