- Allow to configure MediaCodec Java wrapper to use VP8
and H.264 codec.
- Save H.264 config frames with SPS and PPS NALUs and append them to every key frame.
- Correctly handle the case when one encoded frame may generate several output NALUs.
- Add code to find H.264 start codes.
- Add a flag (non configurable yet) to use H.264 in AppRTCDemo.
- Improve MediaCodec logging.
R=wzh@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/43379004
Cr-Commit-Position: refs/heads/master@{#8465}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8465 4adac7df-926f-26a2-2b94-8c16560cd09d
This CL is part II in a major refactoring effort. See https://webrtc-codereview.appspot.com/33969004 for part I.
- Removes unused code and old WEBRTC logging macros
- Now uses optimal sample rate and buffer size in Java AudioTrack (used hard-coded sample rate before)
- Makes code more inline with the implementation in Chrome
- Adds helper methods for JNI handling to improve readability
- Changes the threading model (high-prio audio thread now lives in Java-land and C++ only works as proxy)
- Simplified the delay estimate
- Adds basic thread checks
- Removes all locks in C++ land
- Removes all locks in Java
- Improves construction/destruction
- Additional cleanup
Tested using AppRTCDemo and WebRTCDemo APKs on N6, N5, N7, Samsung Galaxy S4 and
Samsung Galaxy S4 mini (which uses 44.1kHz as native sample rate).
BUG=NONE
R=magjed@webrtc.org, perkj@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/39169004
Cr-Commit-Position: refs/heads/master@{#8460}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8460 4adac7df-926f-26a2-2b94-8c16560cd09d
The Codec class is a big class and objects of the Codec class are passed
around by value. That means that inlined operations would be duplicated
at many places, in particular inside STL.
By not inlining Codec methods, webrtc shrinks by 50 KB in
a Linux x64 clang build.
Total change: -54147 bytes
==========================
+2810 - Source: /home/bratell/src/chromium/src/third_party/libjingle/source/talk/media/base/codec.cc - (gained 2920, lost 110)
-1003 - Source: /home/bratell/src/chromium/src/third_party/libjingle/source/talk/media/base/codec.h - (gained 0, lost 1003)
-1129 - Source: /home/bratell/src/chromium/src/third_party/libjingle/source/talk/media/sctp/sctpdataengine.cc - (gained 1660, lost 2789)
-1190 - Source: /home/bratell/src/chromium/src/third_party/libjingle/source/talk/media/base/rtpdataengine.cc - (gained 1408, lost 2598)
-1747 - Source: /home/bratell/src/chromium/src/third_party/libjingle/source/talk/session/media/mediasession.cc - (gained 803, lost 2550)
-2141 - Source: /home/bratell/src/chromium/src/third_party/libjingle/source/talk/media/webrtc/webrtcvideoengine.cc - (gained 1679, lost 3820)
-2250 - Source: /home/bratell/src/chromium/src/third_party/libjingle/source/talk/app/webrtc/webrtcsdp.cc - (gained 1224, lost 3474)
-2927 - Source: /usr/include/c++/4.8/bits/stl_vector.h - (gained 0, lost 2927)
-3729 - Source: /home/bratell/src/chromium/src/third_party/libjingle/source/talk/media/webrtc/webrtcvideoengine2.cc - (gained 10925, lost 14654)
-6369 - Source: /usr/include/c++/4.8/bits/vector.tcc - (gained 0, lost 6369)
-10582 - Source: /usr/include/c++/4.8/bits/stl_heap.h - (gained 0, lost 10582)
-19324 - Source: /usr/include/c++/4.8/bits/stl_algo.h - (gained 743, lost 20067)
BUG=
R=juberti@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/40729005
Cr-Commit-Position: refs/heads/master@{#8436}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8436 4adac7df-926f-26a2-2b94-8c16560cd09d
Fetching the current codec for sake of gathering stats, is frequently blocked since it's done by acquiring the same lock as is held while encoding frames. This can mean tens of milliseconds.
To improve this, I'm taking advantage of the fact that the codec information is set on the same thread as is used to query the information. This means that locking isn't needed for querying this information. I'm adding checks to make sure debug builds will crash if this isn't followed.
An alternative to this approach could be to add one more lock that is specifically used for the codec information variable. This would also decouple querying codec information from the encoder itself, but still requires a lock.
This patch depends on making ThreadChecker part of rtc_base_approved:
https://webrtc-codereview.appspot.com/40539004/
BUG=2822
R=mflodman@webrtc.org, pthatcher@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/37779004
Cr-Commit-Position: refs/heads/master@{#8435}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8435 4adac7df-926f-26a2-2b94-8c16560cd09d
This reverts commit 1c3e728aa9.
Reason: Fails test running on Nexus 9 bots - org.webrtc.VideoCapturerAndroidTest#testStartStopWithDifferentResolutions.
Note that all other tests pass so it seems like there is resolution supported by the device that can't use YV12.
TBR=glaznev@webrtc.org
BUG=4011
Review URL: https://webrtc-codereview.appspot.com/42389004
Cr-Commit-Position: refs/heads/master@{#8414}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8414 4adac7df-926f-26a2-2b94-8c16560cd09d
Instead of sending a black frame that's the size of the VideoFormat send
a black frame in the format we're already sending. This prevents
expensive encoder reconfiguration when the sending format is a different
resolution. This speeds up setting a null capturer (removing the
capturer) significantly as it doesn't entail an encoder reconfiguration.
R=mflodman@webrtc.org, pthatcher@webrtc.org
BUG=1788
Review URL: https://webrtc-codereview.appspot.com/39179004
Cr-Commit-Position: refs/heads/master@{#8405}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8405 4adac7df-926f-26a2-2b94-8c16560cd09d
It’s possible to implement cricket::VideoFrame::CopyToBuffer using the virtual interface. This removes the need for subclasses to implement their own versions. This CL also fixes a bug in cricket::VideoFrame::CopyToPlanes which currently assumes that GetUPitch() == GetVPitch(), otherwise it may segfault.
I think this CL should land regardless, but the main purpose is to pave the way for for planned changes to I420VideoFrame. See https://review.webrtc.org/38879004.
R=fbarchard@google.com, perkj@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/39889004
Cr-Commit-Position: refs/heads/master@{#8403}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8403 4adac7df-926f-26a2-2b94-8c16560cd09d
Modifies WebRtcVideoSendStream to use a default width/height of 16px.
This significantly reduces SetRemoteDescription time under
WebRtcVideoEngine2. Also preventing (expensive) reconfigurations due to
incoming frames when the channel is not sending yet.
Tests have been modified to generate a frame before expecting a certain
encoder size to have been configured.
Also adding tracing to WebRtcVideoSendStream::InputFrame as it can lead
to reconfigurations of the encoder which is expensive and it should show
up in chrome://tracing.
BUG=1788
R=stefan@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/42369004
Cr-Commit-Position: refs/heads/master@{#8381}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8381 4adac7df-926f-26a2-2b94-8c16560cd09d
For now:
java_helpers - JNI convenience functions etc. Can in theory be moved to libjingle / webrtc general one day.
classreferenceholder - app/webrtc specific Java class loader.
androidvideocapturer_jni - the jni part of the video capturer I added.
peerconnection_jni - all the rest.
This also move all jni specifics into ns webrtc_jni to avoid naming collision.
R=glaznev@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/38099004
Cr-Commit-Position: refs/heads/master@{#8363}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8363 4adac7df-926f-26a2-2b94-8c16560cd09d
PeerConnectionTest.java currently works, but only on a device with
network interfaces up. This is not a problem for desktop, but it is a
problem when running on Android devices since the devices in the lab
generally don't have network (due to the chaotic radio environment in
the device labs, devices are simply kept in flight mode).
The test does work if one modifies this line in the file
webrtc/base/network.cc:
bool ignored = ((cursor->ifa_flags & IFF_LOOPBACK) ||
IsIgnoredNetwork(*network));
If we remove the IFF_LOOPBACK clause, the test starts working on
an Android device in flight mode. This is nice - we're running the
call and packets interact with the OS network stack, which is good
for this end-to-end test. We can't just remove the clause though since
having loopback is undesirable for everyone except the test (right)?
so we need to make this behavior configurable.
This CL takes a stab at a complete solution where we pass a boolean
all the way through the Java PeerConnectionFactory down to the
BasicNetworkManager. This comes as a heavy price in interface
changes though. It's pretty out of proportion, but fundamentally we
need some way of telling the network manager that it is on Android
and in test mode. Passing the boolean all the way through is one way.
Another way might be to put the loopback filter behind an ifdef and
link a custom libjingle_peerconnection.so with the test. That is hacky
but doesn't pollute the interfaces. Not sure how to solve that in GYP
but it could mean some duplication between the production and
test .so files.
It would have been perfect to use flags here, but then we need to
hook up gflags parsing to some main() somewhere to make sure the
flag gets parsed, and make sure to pass that flag in our tests.
I'm not sure how that can be done.
Making the loopback filtering conditional is exactly how we solved the
equivalent problem in content_browsertests in Chrome, and it worked
great.
That's all I could think of.
BUG=4181
R=perkj@webrtc.org, pthatcher@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/36769004
Cr-Commit-Position: refs/heads/master@{#8344}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8344 4adac7df-926f-26a2-2b94-8c16560cd09d
Removes buffer/texture path separation inside WebRtcVideoEngine and
DeliverTextureFrame(). This unifies frame delivery with
WebRtcVideoEngine2 which is expected to automagically work with texture
frames after this change.
BUG=1788
R=magjed@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/38069005
Cr-Commit-Position: refs/heads/master@{#8326}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8326 4adac7df-926f-26a2-2b94-8c16560cd09d
This is a big refactoring of the existing C++/JNI/Java support for audio recording in native WebRTC:
- Removes unused code and old WEBRTC logging macros
- Now uses optimal sample rate and buffer size in Java AudioRecord (used hard-coded sample rate before)
- Makes code more inline with the implementation in Chrome
- Adds helper methods for JNI handling to improve readability
- Changes the threading model (high-prio audio thread now lives in Java-land and C++ only works as proxy)
- Adds basic thread checks
- Removes all locks in C++ land
- Removes all locks in Java
- Improves construction/destruction
- Additional cleanup
Tested using AppRTCDemo and WebRTCDemo APKs on N6, N5, N7, Samsung Galaxy S4 and
Samsung Galaxy S4 mini (which uses 44.1kHz as native sample rate).
BUG=NONE
R=magjed@webrtc.org, perkj@webrtc.org, pthatcher@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/33969004
Cr-Commit-Position: refs/heads/master@{#8325}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8325 4adac7df-926f-26a2-2b94-8c16560cd09d
This CL performs the following renames of targets to
make GYP and GN more unified and make the targets that
have the same name as the module and include the external
render/capture implementation (the internal one is only
used by WebRTC tests).
This makes it natural to declare dependencies in GN
without having to specify the target.
Summary of the renames:
GYP:
video_render_module_impl -> video_render (new target)
video_capture_module_impl -> video_capture (new target)
GN:
video_capture -> video_capture_module (now identical to the GYP target)
video_capture_impl -> video_capture
video_render -> video_render_module (now identical to the GYP target)
video_render_impl -> video_render
BUG=456815
R=andresp@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/35099004
Cr-Commit-Position: refs/heads/master@{#8323}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8323 4adac7df-926f-26a2-2b94-8c16560cd09d
Removes AddRenderCallback from ViERenderer and implements
VideoReceiveStream on top of DeliverI420Frame like WebRtcVideoEngine
currently does today.
Also adds ::IsTextureSupported() to the VideoRenderer interface to
permit querying whether an external renderer supports texture rendering.
R=stefan@webrtc.orgTBR=mflodman@webrtc.org
BUG=1667
Review URL: https://webrtc-codereview.appspot.com/34169004
Cr-Commit-Position: refs/heads/master@{#8299}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8299 4adac7df-926f-26a2-2b94-8c16560cd09d
with stride > width.
Recent libvpx update generates output video frames with stride
value greater than width, which was not supported by Android OpenGL
video renderer (Android GLES2 doesn't have GL_UNPACK_ROW_LENGTH
to provide stride information for buffer in glTexImage2D call).
Fix it by implementing native frame copying for Java
VideoRenderer.I420Frame implementation.
BUG=4248
R=braveyao@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/40639004
Cr-Commit-Position: refs/heads/master@{#8252}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8252 4adac7df-926f-26a2-2b94-8c16560cd09d
The surrounding similar methods all used unsigned char, using unsigned int in
this case looks like an accident, especially since the function passes on the
value in question to a function expecting a uint8.
BUG=none
TEST=none
R=mflodman@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/40529004
Cr-Commit-Position: refs/heads/master@{#8228}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8228 4adac7df-926f-26a2-2b94-8c16560cd09d
* Remove "dead" and "alive" variables.
* Remove critical section
* Skip synchronizing with the worker thread to verify startup (no need).
* Remove implementation of SetNotAlive()
* Always set thread name
* Add thread checks for correct usage.
Also added some TODOs for myself for the ThreadWrapper interface.
I'm removing the HasNoMonitorThread test since it is no longer relevant and ends up checking the wrong thing (ProcessThread - a generic thread type) in the wrong way (parsing a debug log) :) I think it served a purpose some years ago, but things have changed since.
BUG=2902
R=henrika@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/37069004
Cr-Commit-Position: refs/heads/master@{#8220}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8220 4adac7df-926f-26a2-2b94-8c16560cd09d
This fixes a two year old TODO of deleting dead code :)
In cases where the _id or id_ member variable is being used for tracing,
I changed the member to at least be const.
It doesn't look like id's are that useful anymore so maybe the next step is to get rid of them.
BUG=
R=henrika@webrtc.org, perkj@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/37849004
Cr-Commit-Position: refs/heads/master@{#8201}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8201 4adac7df-926f-26a2-2b94-8c16560cd09d
Accept incoming pings before remote answer is set, to reduce connection latency.
Set ICE connection state to 'checking' after setting the remote answer, so that it can transition into 'connected' if the peer reflexive connection is up before any remote candidate is set. See more details in crbug/446908
BUG=4068, crbug/446908
R=juberti@webrtc.org, pthatcher@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/38709004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8141 4adac7df-926f-26a2-2b94-8c16560cd09d
This is something I stumbled upon while looking at string copying we do (in spades) and did a simple change to not be constantly copying things around needlessly. There's a lot more that can be done in these files of course so this is sort of a reminder for future code edits that it's possible to design interfaces/function in a way that's more performance aware and avoid forcing creation of copies, while still being very simple. Also, we can use lambdas now :)
BUG=
R=perkj@webrtc.org, pthatcher@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/41589004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8131 4adac7df-926f-26a2-2b94-8c16560cd09d
Summary of changes:
* We're now using an enum for types instead of strings which both eliminates unecessary string creations+copies and further restricts the type to a known set at compile time.
* IDs are now a separate type instead of a string, copying of Values is not possible and values are const to allow grabbing references outside of the statscollector.
* StatsReport member variables are no longer public.
* Consolidated code in StatsCollector (e.g. merged PrepareLocalReport and PrepareRemoteReport).
* Refactored methods that forced copies of string (e.g. ExtractValueFromReport).
* More asserts for thread correctness.
* Using std::list for the StatsSet instead of a set since order is not important and updates are more efficient in list<>.
BUG=2822
R=hta@webrtc.org, perkj@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/40439004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8110 4adac7df-926f-26a2-2b94-8c16560cd09d
> Update StatsCollector's interface in preparation of more changes.
>
> This CL is the first of three and this one contains interface additions (not deletion for backwards compatibility) as well as a few necessary updates to internal code.
>
> The next CL will be in Chromium to consume the new new methods and remove dependency on the old ones.
>
> The third CL will then contain the bulk of the updates and improvements and be compatible with this interface.
>
> BUG=2822
> R=perkj@webrtc.org
>
> Review URL: https://webrtc-codereview.appspot.com/36829004TBR=tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/37669004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8096 4adac7df-926f-26a2-2b94-8c16560cd09d
This CL is the first of three and this one contains interface additions (not deletion for backwards compatibility) as well as a few necessary updates to internal code.
The next CL will be in Chromium to consume the new new methods and remove dependency on the old ones.
The third CL will then contain the bulk of the updates and improvements and be compatible with this interface.
BUG=2822
R=perkj@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/36829004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8095 4adac7df-926f-26a2-2b94-8c16560cd09d
Current maximum encoder width and height for Android is
hard-coded to 1280x720, so if device is rotated to portrait
orientation only part 720x1280 camera frame is extracted and
scaled to 1280x720. Increasing maximum height to 1280 allows
feeding video encoder with rotated 720x1280 frames directly
without scaling.
R=pthatcher@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/35739004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8042 4adac7df-926f-26a2-2b94-8c16560cd09d
In order to do that, the signaling thread is also changed to wrap the current thread unless an external signaling thread thread is specified in the call to CreatePeerConnectionFactory.
This cleans up the PeerConnectionFactory and makes sure a user of the API will always access the factory on the signaling thread.
Note that both Chrome and the Android implementation use an external signaling thread.
R=tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/35429004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8039 4adac7df-926f-26a2-2b94-8c16560cd09d
Reasons for revert:
1. glaznev discovered potentially related problems using the Android AppRTCDemo.
2. We're trying to do an M41 webrtc roll in Chromium, and this CL is risky.
> Support associated payload type when registering Rtx payload type.
>
> Major changes include,
> - Add associated payload type for SetRtxSendPayloadType & SetRtxReceivePayloadType.
> - Receiver: Restore RTP packets by the new RTX-APT map.
> - Sender: Send RTP packets by checking RTX-APT map.
> - Add RTX payload type for RED in the default codec list.
>
> BUG=4024
> R=pbos@webrtc.org, stefan@webrtc.org
> TBR=mflodman@webrtc.org
>
> Review URL: https://webrtc-codereview.appspot.com/26259004
>
> Patch from Changbin Shao <changbin.shao@intel.com>.
TBR=pbos@webrtc.org, stefan@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/33829004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8033 4adac7df-926f-26a2-2b94-8c16560cd09d
This reverts r7980.
It was causing the ICE connected state to happen while still in the new state rather than going through the checking state, which was causing an ASSERT to fire, which was causing a crash.
Review URL: https://webrtc-codereview.appspot.com/41429004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8031 4adac7df-926f-26a2-2b94-8c16560cd09d
- Add separate looper threads for peer connection and websocket
signaling classes.
- To improve the connection speed start peer connection factory
initialization once EGL context is ready in parallel with the room
connection.
- Add asynchronious http request class and start using it in
webscoket signaling and room parameters extractor.
- Add helper looper based executor class.
- Port some of henrika changes from
https://webrtc-codereview.appspot.com/36629004/ to fix sensor
crashes on non L devices - will remove the change if CL will
be submitted soon.
R=jiayl@webrtc.org, wzh@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/41369004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8006 4adac7df-926f-26a2-2b94-8c16560cd09d
This enables OpenSSL by default for Windows, see
8e72e1d..271c6cc/build/common.gypi
which required libjingle_tests.gyp to be updated since the
targets in third_party/nss/nss.gyp was moved into a condition in
https://codereview.chromium.org/694643002.
New Android dependencies are required due to being introduced in
build/android/pylib/remote/device/remote_device_test_run.py
of 5c49978f09
This should also fix Android test execution that started failing after
https://codereview.chromium.org/815213002 was submitted, since
it's based on e2a338fac9
Relevant other changes:
* src/buildtools: 535aff2..23a4e2f
* src/third_party/android_tools: 4f723e2..8fe116f
* src/third_party/boringssl/src: 00505ec..306e520
* src/third_party/icu: 53ecf0f..51c1a4c
* src/third_party/libvpx: 9fbec81..d3f3dce
* src/tools/swarming_client: 1d4965c..119b084
Details: 8e72e1d..271c6cc/DEPS
Clang version updated 218707:223108:
8e72e1d..271c6cc/tools/clang/scripts/update.sh
Due to this, we had to disable deadlock detection for TSan
due to a bug in Clang (see webrtc:
BUG=4106
R=pbos@webrtc.org, pthatcher@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/36459004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8003 4adac7df-926f-26a2-2b94-8c16560cd09d
First unit test will create peer connection client, run
for a few second, close it and verify that there were
no any errors and local video was rendered.
Second unit test will run peer connection in a loopback mode.
To run the test from command line install AppRTCDemoTest.apk
and execute the command:
adb shell am instrument -w org.appspot.apprtc.test/android.test.InstrumentationTestRunner
R=jiayl@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/33609004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7991 4adac7df-926f-26a2-2b94-8c16560cd09d
Summary:
- Creates a list of available (possible to select) audio devices.
- Automatically selects (routes audio) the "best/default" audio device.
- If possible, starts a proximity sensor that will switch between headset earpiece and speaker phone based on how close the a person's ear the mobile device is held.
TBR=glaznev
BUG=4103,4109
Review URL: https://webrtc-codereview.appspot.com/31239004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7978 4adac7df-926f-26a2-2b94-8c16560cd09d
This fixes a variety of MSVC warnings about value truncations when implicitly
storing the 64-bit values we get back from e.g. TimeTicks in 32-bit objects, and
removes the need for a number of explicit casts.
This also moves a number of constants so they're declared right where they're used, which is easier to read and maintain, and makes some of them of integral type rather than using the "enum hack".
BUG=chromium:81439
TEST=none
R=tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/33649004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7905 4adac7df-926f-26a2-2b94-8c16560cd09d
Expose adapter_type from Candidate such that we could add jmidata on top of this.
Created a new type of report just for Ice candidate. The candidate's id is used as part of report identifier. This code change only reports the best connection's local candidate's adapter type. There should be cleaning later to move other candidate's attributes to the new report.
This is migrated from issue 32599004
BUG=
R=juberti@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/36379004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7885 4adac7df-926f-26a2-2b94-8c16560cd09d
Original cl description:
Change Android PeerConnectionUnittest to build using Chrome macros.
The purpose is to be able to run the tests using Chromes buildbots. To run:
CHECKOUT_SOURCE_ROOT=`pwd` build/android/test_runner.py instrumentation --test-apk=libjingle_peerconnection_android_unittest
This also add a new build target to build java PeerConnection using Chromes build macros.
BUG=4031
R=kjellander@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/26349004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7874 4adac7df-926f-26a2-2b94-8c16560cd09d
- Do not allow connection output when sending http delete
request to ws server - this causes IOException for KK and JB devices.
- Avoid creating dialog box with error message when activity
has been already closed / paused -
this causes resource leak error message for KK devices.
- Plus some code clean up to support async http messages in
websocket channel wrapper and use Handler for running
peerconnection client funcitons on UI thread.
R=jiayl@webrtc.org, tkchin@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/31159004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7836 4adac7df-926f-26a2-2b94-8c16560cd09d
The purpose is to be able to run the tests using Chromes buildbots. To run:
CHECKOUT_SOURCE_ROOT=`pwd` build/android/test_runner.py instrumentation --test-apk=libjingle_peerconnection_android_unittest
This also add a new build target to build java PeerConnection using Chromes build macros.
BUG=4031
R=kjellander@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/28189004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7826 4adac7df-926f-26a2-2b94-8c16560cd09d
The reason is that the desktop apprtcdemo only handle one MediaStream and this doesn't play audio if it receive two streams.
TEST=Test that a call with audio and video can be setup between an Android device and a desktop client using apprtc.appspot.com.
BUG=4051,3786
R=henrika@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/31069004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7781 4adac7df-926f-26a2-2b94-8c16560cd09d
This reverts commit 308e7ff613.
Original cl description:
This adds an Android apk for running tests on the Java layer of PeerConnection.
The only testcase is currently the same test we run on Java standalone.
To run the test adb shell am instrument -w org.webrtc.test/android.test.InstrumentationTestRunner
BUG=4031
R=kjellander@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/32529004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7748 4adac7df-926f-26a2-2b94-8c16560cd09d
These parameters are set by the x-google-*-bitrate SDP parameters. This
is implemented on a Call level instead of per-stream like the currently
underlying VideoEngine implementation to allow this refactoring to not
reconfigure the VideoCodec at all but rather adjust bandwidth-estimator
parameters.
Also implements SetMaxSendBandwidth in WebRtcVideoEngine2 as it's a SDP
parameter and allowing it to be dynamically readjusted in Call.
R=mflodman@webrtc.org, stefan@webrtc.org
BUG=1788
Review URL: https://webrtc-codereview.appspot.com/26199004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7746 4adac7df-926f-26a2-2b94-8c16560cd09d
for Android AppRTCDemo when using WebSocket signaling.
- Add loopback support for new signaling. In loopback mode
only room connection is established, WebSocket connection is
not opened and all candidate/sdp messages are automatically
routed back.
- Fix command line support both for channek and new signaling.
Exit from application when room connection is closed and add
an option to run application for certain time period and exit.
- Plus some fixes for WebSocket signaling - support
POST (not used for now) and DELETE request to WebSocket server
and making sure that all available TURN server are used by
peer connection client.
BUG=3995,3937
R=jiayl@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/24339004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7725 4adac7df-926f-26a2-2b94-8c16560cd09d
The purpose of this CL is to add a new file in libjingle without breaking Chromium in the process. The plan is to do the following:
1. Land a no-op videoframefactory.cc in webrtc (this file).
2. Wait for it to roll into Chromium.
3. Modify libjingle.gyp in Chromium to include this file.
4. Make the real change in webrtc with the real implementation of this file.
5. Wait for the change to roll into Chromium.
R=tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/28049004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7712 4adac7df-926f-26a2-2b94-8c16560cd09d
This didn't compile on the FYI bots. Example error:
FAILED: E:\b\depot_tools\python276_bin\python.exe gyp-win-tool link-with-manifests environment.x86 True chrome_child.dll "E:\b\depot_tools\python276_bin\python.exe gyp-win-tool link-wrapper environment.x86 False link.exe /nologo /IMPLIB:chrome_child.dll.lib /DLL /OUT:chrome_child.dll @chrome_child.dll.rsp" 2 mt.exe rc.exe "obj\chrome\chrome_child_dll.chrome_child.dll.intermediate.manifest" obj\chrome\chrome_child_dll.chrome_child.dll.generated.manifest
content_renderer.lib(content_renderer.webrtc_video_capturer_adapter.obj) : error LNK2001: unresolved external symbol "public: virtual class cricket::VideoFrame * __thiscall cricket::VideoFrameFactory::CreateAliasedFrame(struct cricket::CapturedFrame const *,int,int,int,int)const " (?CreateAliasedFrame@VideoFrameFactory@cricket@@UBEPAVVideoFrame@2@PBUCapturedFrame@2@HHHH@Z)
libjingle_webrtc_common.lib(libjingle_webrtc_common.peerconnectionfactory.obj) : error LNK2001: unresolved external symbol "public: virtual class cricket::VideoFrame * __thiscall cricket::VideoFrameFactory::CreateAliasedFrame(struct cricket::CapturedFrame const *,int,int,int,int)const " (?CreateAliasedFrame@VideoFrameFactory@cricket@@UBEPAVVideoFrame@2@PBUCapturedFrame@2@HHHH@Z)
libjingle_webrtc_common.lib(libjingle_webrtc_common.videocapturer.obj) : error LNK2001: unresolved external symbol "public: virtual class cricket::VideoFrame * __thiscall cricket::VideoFrameFactory::CreateAliasedFrame(struct cricket::CapturedFrame const *,int,int,int,int)const " (?CreateAliasedFrame@VideoFrameFactory@cricket@@UBEPAVVideoFrame@2@PBUCapturedFrame@2@HHHH@Z)
libjingle_webrtc_common.lib(libjingle_webrtc_common.dummydevicemanager.obj) : error LNK2001: unresolved external symbol "public: virtual class cricket::VideoFrame * __thiscall cricket::VideoFrameFactory::CreateAliasedFrame(struct cricket::CapturedFrame const *,int,int,int,int)const " (?CreateAliasedFrame@VideoFrameFactory@cricket@@UBEPAVVideoFrame@2@PBUCapturedFrame@2@HHHH@Z)
chrome_child.dll : fatal error LNK1120: 1 unresolved externals
> cricket::VideoAdapter: Drop frames before spending time converting/scaling, not after.
>
> In VideoCapturer::OnFrameCaptured, we currently convert cricket::CapturedFrame to cricket::VideoFrame and then send that to VideoAdapter::AdaptFrame. AdaptFrame may then decide to drop the frame. It would be faster to drop the frame before converting to cricket::VideoFrame.
>
> This CL refactors VideoAdapter with a new function AdaptFrameResolution that takes captured resolution as input and output adapted resolution, or 0x0 if the frame should be dropped. Using that function, frames can be dropped before any conversion takes place.
>
> R=fbarchard@google.com, perkj@webrtc.org, tommi@webrtc.org
>
> Committed: https://code.google.com/p/webrtc/source/detail?r=7702
>
> Review URL: https://webrtc-codereview.appspot.com/29949004TBR=magjed@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/28019004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7708 4adac7df-926f-26a2-2b94-8c16560cd09d
In VideoCapturer::OnFrameCaptured, we currently convert cricket::CapturedFrame to cricket::VideoFrame and then send that to VideoAdapter::AdaptFrame. AdaptFrame may then decide to drop the frame. It would be faster to drop the frame before converting to cricket::VideoFrame.
This CL refactors VideoAdapter with a new function AdaptFrameResolution that takes captured resolution as input and output adapted resolution, or 0x0 if the frame should be dropped. Using that function, frames can be dropped before any conversion takes place.
R=fbarchard@google.com, perkj@webrtc.org, tommi@webrtc.org
Committed: https://code.google.com/p/webrtc/source/detail?r=7702
Review URL: https://webrtc-codereview.appspot.com/29949004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7707 4adac7df-926f-26a2-2b94-8c16560cd09d
Rease for revert: failed internal test cases
> cricket::VideoAdapter: Drop frames before spending time converting/scaling, not after.
>
> In VideoCapturer::OnFrameCaptured, we currently convert cricket::CapturedFrame to cricket::VideoFrame and then send that to VideoAdapter::AdaptFrame. AdaptFrame may then decide to drop the frame. It would be faster to drop the frame before converting to cricket::VideoFrame.
>
> This CL refactors VideoAdapter with a new function AdaptFrameResolution that takes captured resolution as input and output adapted resolution, or 0x0 if the frame should be dropped. Using that function, frames can be dropped before any conversion takes place.
>
> R=fbarchard@google.com, perkj@webrtc.org, tommi@webrtc.org
>
> Review URL: https://webrtc-codereview.appspot.com/29949004TBR=magjed@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/24279004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7703 4adac7df-926f-26a2-2b94-8c16560cd09d
In VideoCapturer::OnFrameCaptured, we currently convert cricket::CapturedFrame to cricket::VideoFrame and then send that to VideoAdapter::AdaptFrame. AdaptFrame may then decide to drop the frame. It would be faster to drop the frame before converting to cricket::VideoFrame.
This CL refactors VideoAdapter with a new function AdaptFrameResolution that takes captured resolution as input and output adapted resolution, or 0x0 if the frame should be dropped. Using that function, frames can be dropped before any conversion takes place.
R=fbarchard@google.com, perkj@webrtc.org, tommi@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/29949004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7702 4adac7df-926f-26a2-2b94-8c16560cd09d
Previously DataChannel::SendQueuedDataMessages continues the loop of sending queued messages if the channel is blocked, which will cause message reordering if the channel becomes unblocked during the loop, i.e. messages attempted after the unblocking will be sent earlier than the older messages attempted before the unblocking.
BUG=3979
R=pthatcher@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/25149004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@7690 4adac7df-926f-26a2-2b94-8c16560cd09d