We use Optional in our public API, so its header should be in
webrtc/api/.
BUG=webrtc:8205
Review-Url: https://codereview.webrtc.org/3011943002
Cr-Commit-Position: refs/heads/master@{#19693}
Files under the tools directory were untracked by GN.
This cl creates a target for them. The target is testonly because it
depends on "webrtc/test:rtp_test_utils".
BUG=webrtc:7651
NOTRY=True
Review-Url: https://codereview.webrtc.org/2886713002
Cr-Commit-Position: refs/heads/master@{#19683}
This is done to make UBSan testing more convenient in integration with projects using WebRTC
Some blacklist entries were obsolete so don't need a replacement
Also fix one of the warnings (thanks, kwiberg@)
BUG=webrtc:8189, webrtc:5486, webrtc:5491
Review-Url: https://codereview.webrtc.org/3009123002
Cr-Commit-Position: refs/heads/master@{#19682}
This change adds several tests for WindowFinder implmenetations.
One of the tests uses ScreenDrawer to create a foreground window or console
window (on Windows) and ensures WindowFinder can return its window_id().
The other ensures WindowFinder always returns kNullWindowId if the |pos| is out
of the screens.
Bug: webrtc:7950
Change-Id: I0cc8794e201c2fa042ea8e693434f1b0fa05b47a
Reviewed-on: https://chromium-review.googlesource.com/639591
Reviewed-by: Jamie Walch <jamiewalch@chromium.org>
Commit-Queue: Zijie He <zijiehe@chromium.org>
Cr-Commit-Position: refs/heads/master@{#19676}
This change attaches top-left to the DesktopFrames generated by DesktopCapturer
implementations. Some implementations won't need to attach the top-left because
of the platform specification, e.g. coordinates in X11 always starts from
(0, 0), and we support only one screen.
After this change, we can use the new MouseCursorMonitor::Create() function in
DesktopCaptureDevice.
Bug: webrtc:7950
Change-Id: I82c24f4dd9451e32afafb6474f82c32cadcb425c
Reviewed-on: https://chromium-review.googlesource.com/644787
Reviewed-by: Jamie Walch <jamiewalch@chromium.org>
Commit-Queue: Zijie He <zijiehe@chromium.org>
Cr-Commit-Position: refs/heads/master@{#19675}
The warnings were (all signed integer overflow):
webrtc/common_audio/signal_processing/levinson_durbin.c:46:25
12 * 268435456 cannot be represented in type 'int'
webrtc/modules/audio_processing/aecm/aecm_core.cc:930:69
522240 * 6115 cannot be represented in type 'int'
webrtc/modules/audio_processing/aecm/aecm_core_c.cc:455:36
72293096 * 50 cannot be represented in type 'int'
webrtc/modules/pacing/alr_detector.cc:70:48
1000000000 * 65 cannot be represented in type 'int'
webrtc/modules/rtp_rtcp/source/rtp_sender.cc:947:20
1929277286 + 321546521 cannot be represented in type 'int'
BUG=webrtc:8195
Review-Url: https://codereview.webrtc.org/3005003002
Cr-Commit-Position: refs/heads/master@{#19670}
If not indicated otherwise, allow adding a packet to the retransmission
history at least every 1/15s in order to reduce frame dropping.
BUG=webrtc:7694
Review-Url: https://codereview.webrtc.org/2999063002
Cr-Commit-Position: refs/heads/master@{#19665}
First CL to avoid working with wrapping picture ids. After the references of
a frame has been determined they are then unwrapped.
BUG=webrtc:7874
Review-Url: https://codereview.webrtc.org/2985283002
Cr-Commit-Position: refs/heads/master@{#19663}
We use ArrayView in our public API, so its header should be in
webrtc/api/.
BUG=none
Review-Url: https://codereview.webrtc.org/3007763002
Cr-Commit-Position: refs/heads/master@{#19658}
Untracked headers fly under the 'gn check' radar and in the long term
this can cause problems like unnoticed cyclic dependencies.
This cl creates a synthetic target for this header since no other
targets in webrtc/modules/pacing/BUILD.gn seem to be related to it.
BUG=webrtc:7649
NOTRY=True
Review-Url: https://codereview.webrtc.org/2887593003
Cr-Commit-Position: refs/heads/master@{#19656}
Changes made:
* VideoProcessorIntegrationTest definition goes in .h file.
* Member function definitions go into .cc file.
* Tests move to _libvpx.cc and _openh264.cc files.
BUG=webrtc:6634
Review-Url: https://codereview.webrtc.org/3008913002
Cr-Commit-Position: refs/heads/master@{#19637}
This is good for a few reasons:
- We avoid grabing a lock twice.
- We avoid an unnecessary copy.
- We avoid a race where a packet could potentially be removed before the
second time we call GetCodecHeader.
BUG=None
Review-Url: https://codereview.webrtc.org/3009833002
Cr-Commit-Position: refs/heads/master@{#19635}
This CL contains automatically applied fixes suggested by the
ClangTidy analyzer (http://clang.llvm.org/extra/clang-tidy/). The
following kinds of fixes is present:
* renaming variables when the names in the method signature don't
match the names in the method definition
(ClangTidy:readability-inconsistent-declaration-parameter-name)
* ClangTidy:readability-container-size-empty,
ClangTidy:misc-unused-using-decls,
ClangTidy:performance-unnecessary-value-param,
ClangTidy:readability-redundant-control-flow
This is a 'pilot' CL to check if automatic code analyzers can
feasibly be integrated into the WebRTC infrastructuve.
The renamings have been manually expected for consistency with
surrounding code. In echo_cancellation.cc, I changed several names in
the function implementation to match the function declaration. The
tool suggested changing everything to match the function definitions
instead.
Bug: None
Change-Id: Id3b7ba18c51f15b025f26090c7bdcc642e48d8fd
Reviewed-on: https://chromium-review.googlesource.com/635766
Reviewed-by: Karl Wiberg <kwiberg@webrtc.org>
Commit-Queue: Alex Loiko <aleloi@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#19630}
Bug: webrtc:8098
Change-Id: If313c8069a16bfb3c2752dcca7fb1cfca24c1caf
Reviewed-on: https://chromium-review.googlesource.com/643299
Reviewed-by: Michael T <tschumim@webrtc.org>
Reviewed-by: Ivo Creusen <ivoc@webrtc.org>
Commit-Queue: Minyue Li <minyue@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#19627}
Per discussion in
https://chromium-review.googlesource.com/c/external/webrtc/+/641814, the
behavior of IsWindowOnScreen() functions when native APIs fail should be
flipped. I.e. window is *not* on screen if OS cannot find it.
Bug: chromium:758554
Change-Id: Ife449a5261fcd89c37595e29a0b1802fcf3c42a5
Reviewed-on: https://chromium-review.googlesource.com/644290
Reviewed-by: Jamie Walch <jamiewalch@chromium.org>
Commit-Queue: Zijie He <zijiehe@chromium.org>
Cr-Commit-Position: refs/heads/master@{#19617}
GetCroppingWindowRect() is too generic and easy to be misused. For example, in
WindowCapturerWin, it's used to calculate the DesktopRect of the target window,
which is inaccurate. See the screenshot in the bug, it wrongly crops borders on
Windows 8+.
So GetCroppingWindowRect() should be removed eventually, the logic should be
placed in CroppingWindowCapturerWin. But since it's still used in the deprecated
logic in MouseCursorMonitorWin, I would prefer to remove this function after
MouseCursorMonitor improvement has been finished.
But before that, WindowCapturerWin should use GetWindowDrawableRect() instead of
GetCroppedWindowRect() to avoid the wrongly cropping behavior on Windows 8+.
Bug: webrtc:8157
Change-Id: I012b663dced8105623c563dbe55ffcb8d7f17f75
Reviewed-on: https://chromium-review.googlesource.com/642092
Commit-Queue: Zijie He <zijiehe@chromium.org>
Reviewed-by: Jamie Walch <jamiewalch@chromium.org>
Cr-Commit-Position: refs/heads/master@{#19614}
As discussed in change
https://chromium-review.googlesource.com/c/external/webrtc/+/634043, the name of
IsWindowMinimized() functions is too confusing. IsWindowOnScreen() is preferred,
since it describes the behavior of the functions more accurately.
This change does not flip the default behavior of these functions to avoid a
behavior change. TODO has been added; and the flipping will happen in a
following change.
Bug: chromium:758554
Change-Id: I009c0fa57142756e5c83f76b2a3561253db1b67f
Reviewed-on: https://chromium-review.googlesource.com/641814
Commit-Queue: Zijie He <zijiehe@chromium.org>
Reviewed-by: Jamie Walch <jamiewalch@chromium.org>
Cr-Commit-Position: refs/heads/master@{#19613}
also C++ code (see https://bugs.chromium.org/p/webrtc/issues/detail?id=7743
for more information).
To achieve this we have created 2 targets (desktop_capture_objc and
desktop_capture_generic) and desktop_capture will act as a proxy between these
targets (this way we can avoid a circular dependency between
desktop_capture_generic and desktop_capture_objc).
BUG=webrtc:7743
Review-Url: https://codereview.webrtc.org/2989053002
Cr-Commit-Position: refs/heads/master@{#19607}
* First do all frame processing, then do all rate control
statistics calculations. This means that we only need to
synchronize once.
* Run the VideoProcessor on a task queue, thus supporting Android
HW codecs.
* Add some unit tests for the VideoProcessor.
BUG=webrtc:6634
Review-Url: https://codereview.webrtc.org/2997283002
Cr-Commit-Position: refs/heads/master@{#19604}
This CL increases the amount of API call jitter that is allowed in AEC3
without causing resets of AEC3. This increase is now possible, as non-
causal alignments will be detected by the newly imposed delay bound.
BUG=8175
Review-Url: https://codereview.webrtc.org/3012553002
Cr-Commit-Position: refs/heads/master@{#19603}
directives in our DEPS files are not needed anymore.
Includes from webrtc/rtc_base are also whitelisted in webrtc/DEPS
so we don't have to whitelist it in all the others DEPS files.
BUG=webrtc:7634
NOTRY=True
Review-Url: https://codereview.webrtc.org/3006583002
Cr-Commit-Position: refs/heads/master@{#19601}
The extension ID for transport sequence number is added to the list of
known RTP header extensions. Also, the minimum and maximum waiting
time for packets is now aggregated as minimum and maximum,
respectively, not as averages.
BUG=none
Review-Url: https://codereview.webrtc.org/3004783003
Cr-Commit-Position: refs/heads/master@{#19593}
This change adds one temporary use_desktop_relative_cursor_position_ flag in
DesktopAndCursorComposer. It's automatically set according to the consturctor
used.
When the flag is true, DesktopAndCursorComposer uses the newly added
MouseCursorMonitor::Callback::OnCursorPosition(), which is the absolute position
of the cursor in the full desktop coordinate, and DesktopCapturer::IsOccluded()
to decide whether the mouse cursor should be drawn on the DesktopFrame.
When the flag is false, the behavior of DesktopAndCursorComposer is unchanged.
This flag will be removed together with the deprecated constructor of
DesktopAndCursorComposer.
Currently the new DesktopAndCursorComposer constructor is not used, so no
behavior change is expected.
Bug: webrtc:7950
Change-Id: I7235e32fa325a21c4a2594613764a9f81d76dfbc
Reviewed-on: https://chromium-review.googlesource.com/641075
Commit-Queue: Zijie He <zijiehe@chromium.org>
Reviewed-by: Jamie Walch <jamiewalch@chromium.org>
Cr-Commit-Position: refs/heads/master@{#19592}
XWindowAttributes.x and y are in the coordinate of the parent window, so
XTranslateCoordinates() should be used to do the translation.
Meanwhile this change reduces the scope of the XErrorTrap in GetWindowList()
function to ensure the callback can use other XErrorTrap to cover other X
function calls.
Bug: webrtc:7950
Change-Id: I520227b11704c5a0cb665d9de86925ed4e86540d
Reviewed-on: https://chromium-review.googlesource.com/639590
Reviewed-by: Jamie Walch <jamiewalch@chromium.org>
Commit-Queue: Zijie He <zijiehe@chromium.org>
Cr-Commit-Position: refs/heads/master@{#19591}
In this change,
bool DesktopCapturer::IsOccluded(const DesktopVector& pos);
is added to DesktopCapturer interface. This function returns true if the |pos|
is hidden by other elements on the display.
The function expects to return false for ScreenCapturer implementations:
everything is visible on the screen.
In WindowCapturer implementations, WindowFinder is expected to be used to help
detect the WindowId under |pos|. If the window_id_ equals to the window id
returned by WindowFinder, this function returns false.
To ensure the correct coordinate is used, a comment is also added to
WindowFinder::GetWindowUnderPoint() function. Considering it's used only in
desktop_capture module, using system coordinate is simpler.
Bug: webrtc:7950
Change-Id: I8ac4fbd5f4a612388f1593907805cfb2c359f70f
Reviewed-on: https://chromium-review.googlesource.com/636784
Reviewed-by: Jamie Walch <jamiewalch@chromium.org>
Commit-Queue: Zijie He <zijiehe@chromium.org>
Cr-Commit-Position: refs/heads/master@{#19590}
This CL fixes a small bug, causing the matlab plot script to contain
empty vectors. Also, the script file name is fixed, to avoid two
periods (.) in the file name; matlab did not like that.
BUG=none
Review-Url: https://codereview.webrtc.org/3004813002
Cr-Commit-Position: refs/heads/master@{#19586}
Will remove default implementations as well once landed and removed
in Chrome as well.
These two AudioDeviceModule APIs are removed:
int32_t SetWaveOutVolume(uint16_t volumeLeft, uint16_t volumeRight)
int32_t WaveOutVolume(uint16_t* volumeLeft, uint16_t* volumeRight) const
BUG=webrtc:7306
Review-Url: https://codereview.webrtc.org/3006793002
Cr-Commit-Position: refs/heads/master@{#19581}
Cleanup CL. Start using new AudioRecord.Builder class for creating
AudioRecord Java instances. Exists from API 23.
BUG=webrtc:7962
Review-Url: https://codereview.webrtc.org/3007673002
Cr-Commit-Position: refs/heads/master@{#19571}
This CL replaces:
namespace webrtc_jni {
with:
namespace webrtc {
namespace jni {
The main benefit is that we don't have to use the webrtc:: qualifier
inside the jni namespace so we can reduce some clutter.
BUG=None
Review-Url: https://codereview.webrtc.org/3009613002
Cr-Commit-Position: refs/heads/master@{#19569}
Headers webrtc/video_receive_stream.h and webrtc/video_send_stream.h
have been moved to webrtc/call in https://codereview.webrtc.org/3000253002,
this CL is just switching WebRTC internal dependencies to actual headers
instead of depending on the backward compatibility ones.
BUG=webrtc:8107
Review-Url: https://codereview.webrtc.org/3007553002
Cr-Commit-Position: refs/heads/master@{#19561}
This allows returning RTPFragmentationHeader from a method and assigning
the results to a variable.
BUG=webrtc:7760
Review-Url: https://codereview.webrtc.org/3002283002
Cr-Commit-Position: refs/heads/master@{#19556}
remove rtc_base_approved from the public_deps list of rtc_task_queue.
BUG=webrtc:8160
NOTRY=True
Review-Url: https://codereview.webrtc.org/3008553002
Cr-Commit-Position: refs/heads/master@{#19551}