Commit Graph

1009 Commits

Author SHA1 Message Date
Ralph Giles
1cd421b9df Bug 1369950 - Remove aom_codec_stream_info_t sz field references. r=gerald
Upstream has removed the requirement to set this when
initializing the stream_info struct.

MozReview-Commit-ID: 24OJ550Ral

--HG--
extra : rebase_source : 501fd9f51084a4b6f779462536e94c71cf8c5bb7
2017-05-09 11:10:51 -07:00
Jean-Yves Avenard
5e8ee8b868 Bug 1345342: Cancel pending requests. r=jya
If the pending first frame decoding was cancelled, the next call to decode could lead to a crash.

MozReview-Commit-ID: 6Q4eKUzqOly

--HG--
extra : rebase_source : 3640a2edd07fdbd4811295c0088a4086ac579b26
2017-06-04 12:03:25 +02:00
Cameron McCormack
76df568747 Backed out changeset ff724e355b2d (bug 1345342) per jya's request. 2017-06-05 15:58:41 +08:00
Jean-Yves Avenard
f5de325f6f Bug 1345342: Cancel pending requests. r=jya
If the pending first frame decoding was cancelled, the next call to decode could lead to a crash.

MozReview-Commit-ID: 6Q4eKUzqOly

--HG--
extra : rebase_source : 620efb39265944998c23c184e831a5b71f9b437f
2017-06-04 12:03:25 +02:00
James Willcox
5dee9f6c40 Bug 1367287 - Release video surface when decoder is shut down r=jolin
MozReview-Commit-ID: GgWYSzBx7ZF
2017-06-02 10:14:12 -05:00
Jean-Yves Avenard
a9142498ec Bug 1360006: Whitelist VP9 decoder to intel GPU only. r=mattwoodrow
We enable by default the VP9 hardware decoder on intel GPU.

MozReview-Commit-ID: FzMzbpZErjQ

--HG--
extra : rebase_source : f34c969f7dda1ef24224e982f31d5e43cfae7cc0
2017-06-01 22:17:56 +02:00
Ralph Giles
d282fd8a60 Bug 1368839 - Add av1 to MediaSource.isTypeSupported. r=gerald
When av1 video playback is enabled, declare it as supported
in the webm container in MediaSource.IsTypeSupported.

Also support special mime types of the form

  video/webm; codecs=vp9.experimental.<git-commit-id>

so test sites can verify playback support of particular encodings
while the av1 bitstream is under development.

MozReview-Commit-ID: GS4n7cPxfQ7

--HG--
extra : rebase_source : a595942242304ccf97a341474b6e2e1e869e7a77
2017-05-30 16:37:20 -07:00
Jean-Yves Avenard
ba837c02ae Bug 1313398: P4. Check that the out of band extradata hasn't changed. r=gerald
On android, where decoders can sometimes be recycled, the h264converter can be fed over its lifetime MediaRawData with different mExtraData.
So we need to ensure that not only, the inband ones don't change, but that the out of band one hasn't changed either.

This is a condition we could totally ignore on desktop, as when the resolution change the H264Converter is destroyed.

MozReview-Commit-ID: 7w6ku6by1Qi

--HG--
extra : rebase_source : d35f07b372ef0623dbd74384aa5d3a865a3e067a
2017-05-31 22:03:55 +02:00
Jean-Yves Avenard
33005dac56 Bug 1313398: P3. Don't always check if the decoder supports being recycled. r=gerald
The value never changes on a system, so there's no point checking it every single time

MozReview-Commit-ID: KTSslluQsKw

--HG--
extra : rebase_source : 40274727d0e7202087a8282eedb2c78404212f31
2017-05-31 21:43:53 +02:00
Jean-Yves Avenard
72d70a10d9 Bug 1313398: P1. Fix indent. r=gerald
MozReview-Commit-ID: 3eBq1mrR98D

--HG--
extra : rebase_source : 33e5fc37bfb8022a193c8d77e5a9dce5c638635b
2017-05-31 16:12:40 +02:00
Alfredo Yang
55d6ddef12 Bug 1365872 - remove parsing mp4v mCodecSpecificConfig which is for b2g. r=jya
MozReview-Commit-ID: G3l6AtEH0hO

--HG--
extra : rebase_source : bad9f7ae16715acb53826a494203cd7bbee138b3
2017-05-18 16:54:43 +08:00
Jean-Yves Avenard
b35c566d48 Bug 1364870: [ffmpeg] only check format if frame has been decoded. r=gerald
The format member isn't set when an audio frame hasn't been decoded yet.

MozReview-Commit-ID: IgUj6bjVzdF

--HG--
extra : rebase_source : bb47fa523384f9a85ee7d0ed5b6de4fe2c73526a
2017-05-19 09:52:12 +02:00
John Lin
d888243796 Bug 1363276 - discard video output buffers according to presentation time rather than size. r=esawin
This works around an Android 4.2.2 bug that reports incorrect sizes for hardware buffers.

MozReview-Commit-ID: 4rAu8d1RwOJ

--HG--
extra : rebase_source : f63ad96427b90dc24e0cb84319f256d1ec354b5e
2017-05-05 16:19:47 +08:00
JW Wang
4b91acd0b1 Bug 1364834 - Fix rounding error in WaveDataDecoder::ProcessDecode(). r=jya
The duration is rounded down to 0 if |frames| is smaller than |mInfo.mRate|.
We should call FramesToTimeUnit() instead.

MozReview-Commit-ID: E7eOQuD48x2

--HG--
extra : rebase_source : 1edabb9a9fe495f89a13df71d73d3b9aef49fa9d
2017-05-15 17:25:26 +08:00
James Willcox
4649c2acf0 Bug 1322650 - Don't use AndroidBridge to get API version in media stack r=jolin
AndroidBridge is not available in child processes.

MozReview-Commit-ID: KlBs8F1Bu1O
2017-05-15 09:37:57 -05:00
James Willcox
cf48e4bebd Bug 1322650 - Support a 'continuous' mode for SurfaceTexture r=jgilbert
This is needed to support Flash on Android

MozReview-Commit-ID: 5yNIoZHonla
2017-05-15 09:37:50 -05:00
James Willcox
b69402b0ba Bug 1322650 - Make video decoding work with new SurfaceTexture API r=jolin 2017-05-15 09:37:49 -05:00
Ralph Giles
cfe9afb991 Bug 1363857 - Add missing includes to FFmpegLibWrapper. r=gerald
This was working because of the unified build, but passing
--enable-av1 changed the source partitioning in such a way
that the referenced defines and symbols were no longer available.

MozReview-Commit-ID: CRjyhLtOhoM

--HG--
extra : rebase_source : bce3810fcff39669c4578f1b545fb619be691e38
2017-05-10 14:57:25 -07:00
Kris Maglione
b588cdc5bb Bug 1361900: Part 1 - Make CDMProxy.h compatible with mozilla::Result. r=JamesCheng
MozReview-Commit-ID: DiO7IPFYKbE

--HG--
extra : rebase_source : 500e32854c50e2381fd9de3a3533611be1426329
extra : source : 9e3064aec4bb16542f9cc93a89f7a257b6716a98
2017-05-12 12:08:43 -07:00
Sebastian Hengst
7b52c82b67 Backed out changeset 9e3064aec4bb (bug 1361900) for crashing Marionette's test_timeouts.py TestTimeouts.test_reset_timeout on Linux debug with e10s. r=backout 2017-05-13 18:56:06 +02:00
Kris Maglione
49ed37ac3d Bug 1361900: Part 1 - Make CDMProxy.h compatible with mozilla::Result. r=JamesCheng
MozReview-Commit-ID: DiO7IPFYKbE

--HG--
extra : rebase_source : defeef269706ba81ee35272818e468e3ae0b2b19
2017-05-12 12:08:43 -07:00
Iris Hsiao
e22349b74b Backed out 11 changesets (bug 1322650) for media test failures on android. a=backout
Backed out changeset 31bd912fba54 (bug 1322650)
Backed out changeset 4d486c7469eb (bug 1322650)
Backed out changeset 4cf8f4d5064c (bug 1322650)
Backed out changeset 3cb108f7492f (bug 1322650)
Backed out changeset bd53533c108e (bug 1322650)
Backed out changeset 3522917d8f10 (bug 1322650)
Backed out changeset 2c2c1e33eccc (bug 1322650)
Backed out changeset 2f19977cd6ab (bug 1322650)
Backed out changeset 4519296a323e (bug 1322650)
Backed out changeset e56e5e1c8786 (bug 1322650)
Backed out changeset 96fe52231b57 (bug 1322650)

--HG--
extra : amend_source : b11d2181d8f545f4ed1074f09986eddab0b637c8
2017-05-12 10:21:14 +08:00
Wes Kocher
3b736de62a Merge m-c to inbound, a=merge
MozReview-Commit-ID: ADbja7mAY4s
2017-05-11 17:41:11 -07:00
James Willcox
22e9b1e4cc Bug 1322650 - Don't use AndroidBridge to get API version in media stack r=jolin
AndroidBridge is not available in child processes.

MozReview-Commit-ID: KlBs8F1Bu1O
2017-05-11 15:42:45 -05:00
James Willcox
40d0e705e9 Bug 1322650 - Support a 'continuous' mode for SurfaceTexture r=jgilbert
This is needed to support Flash on Android

MozReview-Commit-ID: 5yNIoZHonla
2017-05-11 15:42:44 -05:00
James Willcox
31b30cd5c9 Bug 1322650 - Make video decoding work with new SurfaceTexture API r=jolin
MozReview-Commit-ID: EXQ5YDSMMGL
2017-05-11 15:42:43 -05:00
JW Wang
4018e22ad9 Bug 1362910. P2 - fix callers. r=gerald
Since RefPtr<T>&& can't be converted to T* implicitly, we need to change
T* to RefPtr<T> in resolve/reject callbacks to make it compile again.

We should review the changes later to look for the opportunity to
optimize away unnecessary AddRef/Release pairs.

MozReview-Commit-ID: 22rHQ8dhxJv

--HG--
extra : rebase_source : 1b09f353d6e86d60c93a2746333585ec0dba8526
2017-05-11 08:30:39 +08:00
JW Wang
20f3ad9f2f Bug 1362912. P2 - fix the callers. r=gerald
MozReview-Commit-ID: LdYcIWAFDUn

--HG--
extra : rebase_source : eb943f7e5b7674c3397fce3ad0e8193b4c0ddc01
extra : source : fdfd468b6edbabf3830eb78fc705f6d6682b7126
2017-05-09 23:31:32 +08:00
Ralph Giles
dcaee36bbc Bug 1314147 - Add AOMDecoder to AgnosticDecoderModule. r=jya
Conditionally enable the AV1 decoder as part of the
agnostic PlatformDecoderModule factory.

MozReview-Commit-ID: ApZ1CMvdLE

--HG--
extra : rebase_source : 33cedc6bd6243ccd2019ea40dc9b989921c63b98
2017-04-19 13:30:32 -07:00
Ralph Giles
76e68522c8 Bug 1314147 - Add AOMDecoder. r=jya
Port the VPXDecoder interface to libaom which uses
the same api with the names changed. I've removed
the alpha support for now.

MozReview-Commit-ID: IdxcVWhNgVl

--HG--
extra : rebase_source : 5f3a84fb9a827f01c80057eb520bde184c41f0b9
2017-04-19 13:19:32 -07:00
Wes Kocher
21203b47b5 Merge inbound to m-c a=merge
MozReview-Commit-ID: JgXkqrOwl3N
2017-05-03 13:40:24 -07:00
Ralph Giles
dcb3a85e19 Bug 1358662 - Implement keyframe and framesize VPXDecoder helpers. r=jya
Encapsulate code from WebMDemuxer to query keyframe and frame
resolution inside VPXDecoder, so we have a clean wrapper for
all the libvpx functions we use.

MozReview-Commit-ID: ASRRhNl0A41

--HG--
extra : rebase_source : e0a27e946a60e0c33ecf4908f1e09436f836e123
2017-04-24 15:05:01 -07:00
Ralph Giles
318e6f6af0 Bug 1358662 - Store VPXDecoder codec as an enum. r=jya
Use the enum we already have here instead of converting
to an int when we pass it around, giving us better
type checking.

MozReview-Commit-ID: Gj4xmtQnzw2

--HG--
extra : rebase_source : fc7769c9650c59f52bfd8611e6cabb8e5b6d7068
2017-04-24 15:02:54 -07:00
Chris Pearce
12f8d2203e Bug 1352556 - Validate output of MFGetAttributeSize. r=gerald
MozReview-Commit-ID: J1NirhKfTK6
2017-05-01 16:12:27 +12:00
JW Wang
aab9f27e0f Bug 1359309. P1 - give mozilla::TaskQueue a name which will be useful in debugging Dispatch() failures. r=jya
MozReview-Commit-ID: 5FAVNo32fl7

--HG--
extra : rebase_source : 761fca752429d95e97be699976283baa35c64abb
extra : intermediate-source : 83282a7a5adbe7046212da85f9d16e39faa4bd5c
extra : source : 924af3ea0aa86888fd2745020be7900e6eb614f0
2017-04-25 14:57:55 +08:00
JW Wang
80c9f230f3 Bug 1359715 - let functions in MediaData.h take TimeUnit instead of int64_t. r=kaku
We want to replace the use of int64_t for microseconds by TimeUnit
whenever possible since int64_t is ambiguous which could be microseconds
or milliseconds.

MozReview-Commit-ID: LRz9d4yKBYJ

--HG--
extra : rebase_source : 1f73f1f338142b3183491d04726821a881ccabbe
extra : intermediate-source : 88e167b7b06303d10d92cd5317502f405d1c553e
extra : source : 98deb30ec93d395f9951f5fc488170ae35e29675
2017-04-24 17:33:05 +08:00
Sebastian Hengst
388d65b332 Backed out changeset 20e051241152 (bug 1358662) 2017-04-25 22:36:21 +02:00
Sebastian Hengst
22303ff8eb Backed out changeset 5da7e883ba70 (bug 1358662) 2017-04-25 22:36:20 +02:00
Ralph Giles
20c544fb86 Bug 1358662 - Implement keyframe and framesize VPXDecoder helpers. r=jya
Encapsulate code from WebMDemuxer to query keyframe and frame
resolution inside VPXDecoder, so we have a clean wrapper for
all the libvpx functions we use.

MozReview-Commit-ID: ASRRhNl0A41

--HG--
extra : rebase_source : a1421462f6fc66a2abd965782ec408a8bcf7fe1f
2017-04-24 15:05:01 -07:00
Ralph Giles
83de6e82b7 Bug 1358662 - Store VPXDecoder codec as an enum. r=jya
Use the enum we already have here instead of converting
to an int when we pass it around, giving us better
type checking.

MozReview-Commit-ID: Gj4xmtQnzw2

--HG--
extra : rebase_source : 95f582e655f1a942dfb68cbba588c44afbb8a38f
2017-04-24 15:02:54 -07:00
JW Wang
f2ea37e57b Bug 1357986 - Use helper functions of TimeUnit to make code more readable. r=kaku
1. using media::TimeUnit to save some typing.
2. replace TimeUnit() with TimeUnit::Zero().
3. replace TimeUnit::FromXXX(0) with TimeUnit::Zero().
4. replace TimeUnit::FromMicroseconds(std::numeric_limits<int64_t>::max()) with TimeUnit::FromInfinity().
5. replace some uses of int64_t with TimeUnit.
6. replace t > TimeUnit() with t.IsPositive().

MozReview-Commit-ID: 6hC94PXx86i

--HG--
extra : rebase_source : 1ea3b409e6ec12915f3e1a00359d6ff4152c8917
extra : intermediate-source : e31a12ad0e7a4840119036f261ed17eaaff85734
extra : source : ae07ee48000c4a52da0e4fd502b4d690ec51ce1f
2017-04-17 16:35:04 +08:00
JW Wang
302d82c85a Bug 1356530 - Change the type of MediaData::mTime to TimeUnit since int64_t is ambiguous. r=kaku
MozReview-Commit-ID: 4bVeqIuWO2O

--HG--
extra : rebase_source : d504ac15a6dc59ad42f3ab80faf23f629d74315f
extra : intermediate-source : 6e52995b6c8146451d98dffc62f6907755dc856e
extra : source : 82d2649cdafb5a6389f6858c23578811933580c9
2017-04-14 17:13:36 +08:00
JW Wang
235f1f55ed Bug 1356506 - change the type of MediaData::mTimecode to TimeUnit since int64_t is ambiguous. r=gerald
MozReview-Commit-ID: 7dO5OOUuORz

--HG--
extra : rebase_source : 1c1c020700d9180ef9f85d7e2e679f498ab71fce
extra : intermediate-source : d173c820bef7a113e28e9732c42e8c1af36160ab
extra : source : 04c08a780526ca3a5ac4d1a6f9b7ae30d9957e92
2017-04-14 14:52:14 +08:00
Mike Hommey
33a7e408ce Bug 1357323 - Remove the gonk code that was referenced by the build system. r=gps
--HG--
extra : rebase_source : 1d30ebcbdbcf596c944e1eec981f85db341485e5
2017-04-18 17:46:39 +09:00
Mike Hommey
34e619d1c1 Bug 1357323 - Remove support for gonk in the build system. r=gps
Everything depending on the widget being gonk can go away, as well as
everything depending on MOZ_AUDIO_CHANNEL_MANAGER, which was only
defined on gonk builds under b2g/ (which goes away in bug 1357326).

--HG--
extra : rebase_source : 9f0aeeb7eea8417fa4e06d662d566d67ecaf2a24
2017-04-18 16:56:09 +09:00
JW Wang
6359124d70 Bug 1355756. P3 - let CreateAndCopyData() and its friends take TimeUnit for duration. r=gerald
MozReview-Commit-ID: ES0on9VCuu3

--HG--
extra : rebase_source : 8d3e80ec2e1923587b5865516a16bfff9009397d
extra : intermediate-source : 3e59c61b1ccef78e3e8fe52791d7104aade7930c
extra : source : 46fd639ea6a2219bbed70f6555a2acf03ec01a7a
2017-04-12 17:46:09 +08:00
JW Wang
464497b945 Bug 1355756. P1 - change the type of MediaData::mDuration to TimeUnit. r=gerald
MozReview-Commit-ID: 3d4bUYtSuMI

--HG--
extra : rebase_source : 94c821b6d381421035e6a12cbe038436055c5822
extra : intermediate-source : 9a06beffc736486f47b9cf05e7f482e726d53068
extra : source : fdbdcd5c1474f04dc1dbde66fcf3a9ecec953053
2017-04-12 17:27:34 +08:00
Jay Harris
6ce213e795 Bug 1338011 - Adds an intermediate fallback when the GPU process crashes - r=gerald
MozReview-Commit-ID: 9x1ckaWagcE

--HG--
extra : rebase_source : 2962f8572dd36b2dfecb7bb30ba515fc7c6323c9
2017-04-15 09:34:01 +12:00
JW Wang
f45fa7374e Bug 1355740 - Change the type of TrackInfo::mDuration to TimeUnit. r=jya
MozReview-Commit-ID: P7aqw4d5Vk

--HG--
extra : rebase_source : f22743fec9c8b70cbb092e3b26e252e7a4cb0b31
extra : source : 2413cd58f073b734a2cb85cec3658942bfd46e08
2017-04-12 16:41:36 +08:00
John Lin
6e70175957 Bug 1349883 - part 4: strengthen precondition of ReturnDecodedData(). r=jya
MozReview-Commit-ID: 2jLNlrHEE0b

--HG--
extra : rebase_source : af780e3b10f915302aa1deaba18a324266fa1dc0
2017-04-07 17:17:17 +08:00
John Lin
ab9060d531 Bug 1349883 - part 3: resolve decode promise according to buffer status. r=jya
MozReview-Commit-ID: JwOOi56t30Y

--HG--
extra : rebase_source : 48f0cc0bfde3f84cc0574c5a5da6c738112c843f
2017-04-07 17:07:02 +08:00
James Willcox
224324d56d Bug 1344347 - Move Android out-of-process decoder service into GeckoView r=jolin
MozReview-Commit-ID: QTnp95uhQV


--HG--
rename : mobile/android/base/aidl/org/mozilla/gecko/media/FormatParam.aidl => mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/media/FormatParam.aidl
rename : mobile/android/base/aidl/org/mozilla/gecko/media/ICodec.aidl => mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/media/ICodec.aidl
rename : mobile/android/base/aidl/org/mozilla/gecko/media/ICodecCallbacks.aidl => mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/media/ICodecCallbacks.aidl
rename : mobile/android/base/aidl/org/mozilla/gecko/media/IMediaDrmBridge.aidl => mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/media/IMediaDrmBridge.aidl
rename : mobile/android/base/aidl/org/mozilla/gecko/media/IMediaDrmBridgeCallbacks.aidl => mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/media/IMediaDrmBridgeCallbacks.aidl
rename : mobile/android/base/aidl/org/mozilla/gecko/media/IMediaManager.aidl => mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/media/IMediaManager.aidl
rename : mobile/android/base/aidl/org/mozilla/gecko/media/Sample.aidl => mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/media/Sample.aidl
rename : mobile/android/base/aidl/org/mozilla/gecko/media/SessionKeyInfo.aidl => mobile/android/geckoview/src/main/aidl/org/mozilla/gecko/media/SessionKeyInfo.aidl
rename : mobile/android/base/java/org/mozilla/gecko/media/AsyncCodec.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/AsyncCodec.java
rename : mobile/android/base/java/org/mozilla/gecko/media/AsyncCodecFactory.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/AsyncCodecFactory.java
rename : mobile/android/base/java/org/mozilla/gecko/media/Codec.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/Codec.java
rename : mobile/android/base/java/org/mozilla/gecko/media/CodecProxy.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/CodecProxy.java
rename : mobile/android/base/java/org/mozilla/gecko/media/FormatParam.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/FormatParam.java
rename : mobile/android/base/java/org/mozilla/gecko/media/GeckoMediaDrm.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/GeckoMediaDrm.java
rename : mobile/android/base/java/org/mozilla/gecko/media/GeckoMediaDrmBridgeV21.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/GeckoMediaDrmBridgeV21.java
rename : mobile/android/base/java/org/mozilla/gecko/media/GeckoMediaDrmBridgeV23.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/GeckoMediaDrmBridgeV23.java
rename : mobile/android/base/java/org/mozilla/gecko/media/JellyBeanAsyncCodec.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/JellyBeanAsyncCodec.java
rename : mobile/android/base/java/org/mozilla/gecko/media/MediaDrmProxy.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/MediaDrmProxy.java
rename : mobile/android/base/java/org/mozilla/gecko/media/MediaManager.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/MediaManager.java
rename : mobile/android/base/java/org/mozilla/gecko/media/RemoteMediaDrmBridge.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/RemoteMediaDrmBridge.java
rename : mobile/android/base/java/org/mozilla/gecko/media/RemoteMediaDrmBridgeStub.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/RemoteMediaDrmBridgeStub.java
rename : mobile/android/base/java/org/mozilla/gecko/media/SamplePool.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/SamplePool.java
rename : mobile/android/base/java/org/mozilla/gecko/media/SessionKeyInfo.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/media/SessionKeyInfo.java
rename : mobile/android/base/java/org/mozilla/gecko/mozglue/SharedMemory.java => mobile/android/geckoview/src/main/java/org/mozilla/gecko/mozglue/SharedMemory.java
2017-04-06 14:32:58 -05:00
Munro Mengjue Chiang
8c7e3d6e57 Bug 1265755 - Support encoder case for CodecProxy; r=jolin
MozReview-Commit-ID: 4cEZQs8spo7

--HG--
extra : rebase_source : 33989d576cbd15194c5d740745fd5ddf35958346
2017-03-30 08:51:12 +08:00
Munro Mengjue Chiang
0d0b538b3e Bug 1265755 - separate JavaCallbacksSupport class declaration to a different header file; r=jolin
MozReview-Commit-ID: 7Vj3G47n2bu

--HG--
extra : rebase_source : 9dac50f9a4c405b2461e7f677c58beef7f634f6e
2017-03-30 08:30:23 +08:00
Chun-Min Chang
ddc78aa48d Bug 1349128 - Remove duplicated AndroidDecoderModule in mCurrentPDMs if both PDMAndroidMediaCodecEnabled and PDMAndroidMediaCodecPreferred are set to true; r=jya
The AndroidDecoderModule will be added into PDM queue twice if both PDMAndroidMediaCodecEnabled and PDMAndroidMediaCodecPreferred are set to true. It should be inserted into the head of the PDM queue in this case, and appended to the tail if only PDMAndroidMediaCodecEnabled is true.

MozReview-Commit-ID: Fj0z0meeb1V

--HG--
extra : rebase_source : 1d7f2b10fd4360d3f641ad6517e9f95afcb99768
2017-03-22 14:14:09 +08:00
Kaku Kuo
0b870b3650 Bug 1351526 - Label runnables in dom/media/platforms/wmf/WMFVideoMFTManager.cpp; r=jwwang
MozReview-Commit-ID: 9vtEKRgNnI6

--HG--
extra : rebase_source : 9bd7212c6a7f7606bcf7a5877d6e14a21e747114
2017-03-29 10:38:39 +08:00
Kaku Kuo
45bc331e6b Bug 1351525 - Label runnables in dom/media/platforms/wmf/WMFAudioMFTManager.cpp; r=jwwang
MozReview-Commit-ID: AdVCmnyGTNS

--HG--
extra : rebase_source : 70150afefa2b1c38a8f51a217752257c22442978
2017-03-29 10:32:35 +08:00
Jean-Yves Avenard
56a92b73cb Bug 1350932: P2. Ensure the updated H264 extadata is used. r=gerald
For AVC3 content, the initial init segment doesn't contain the SPS/PPS NALs required to create the decoder.
However, we created the decoder using such init segment, causing decoding failures.

MozReview-Commit-ID: BZO1gkasf8q

--HG--
extra : rebase_source : 8891cfe4a9a067e657870d840bd446388d90b926
2017-03-28 23:48:07 +02:00
Carsten "Tomcat" Book
361ed3a53c Merge mozilla-central to autoland 2017-03-24 14:30:43 +01:00
Jean-Yves Avenard
925cb2babd Bug 1350148: [AAC] Don't set channel count on output decoder. r=gerald
Windows AAC decoder decode a mono AAC stream into a stereo PCM. Bug 1347101 set the output to be mono, which caused a failure to find the appropriate IMFMediaType.

This partially revert bug 1347101 audio changes.

MozReview-Commit-ID: 2M4X4rKKvXl

--HG--
extra : rebase_source : 6b7330a7edfc2c0504171828526221dcccb6f8c5
2017-03-24 09:48:07 +01:00
Chris Pearce
4c421503a8 Bug 1315850 - Shutdown CDMVideoDecoder. r=jya
This severs the ChromiumCDMVideoDecoder's connection with the CDM. The CDM process
will shutdown when the MediaKeys also severs its connection.

MozReview-Commit-ID: Aqc4y5Nxjvc

--HG--
extra : rebase_source : 5a2f77ffe84f9b99b4668520c838b29a428578d3
2017-03-08 10:20:33 +13:00
Chris Pearce
dbc1c7bcdf Bug 1315850 - Implement CDM video decoder drain. r=jya
MozReview-Commit-ID: 5RbrWyLglRf

--HG--
extra : rebase_source : 3f9636503523f0c6effab15fa89cce25a961a0b4
2017-03-07 16:37:21 +13:00
Chris Pearce
abcd1aee62 Bug 1315850 - Implement CDM video decoder flush. r=jya
MozReview-Commit-ID: 3CzwfOCXGP

--HG--
extra : rebase_source : 8ee1ae28a36779484717c6b105ef7730dd1896b3
2017-02-14 22:42:26 +13:00
Chris Pearce
6f73601a0b Bug 1315850 - Implement video decoding through CDM. r=jya
At this stage, I store video frames in memory in nsTArrays rather than in
shmems just so we can get this working. Once this is working, I'll follow up
with patches to switch to storing all large buffer traffic between the CDM and
other processes in shmems.

I'm not planning on preffing this new CDM path on until that's in place.

MozReview-Commit-ID: LSTb42msWQS

--HG--
extra : rebase_source : b7f162515a1a32b2c344c11d0fa5c7004cec2e15
2017-03-09 11:32:15 +13:00
Chris Pearce
a181e5dc64 Bug 1315850 - Initialize video decoder. r=jya
MozReview-Commit-ID: 559SP0ECldq

--HG--
extra : rebase_source : b6d499cafef2d6a6558b0db703b60320dea67803
2017-03-09 18:17:50 +13:00
Chris Pearce
42faf7c8fa Bug 1315850 - Create CDM video decoder in EMEDecoderModule. r=jya
MozReview-Commit-ID: 3xgFxg1WfmY

--HG--
extra : rebase_source : 018abf2b8e1b351a29ba62275a2681fe9ea4fc24
2017-03-08 16:20:09 +13:00
Chris Pearce
ffe9c27064 Bug 1315850 - Stub out ChromiumCDMVideoDecoder. r=jya
MozReview-Commit-ID: 6I9N1c1nNMF

--HG--
extra : rebase_source : 6c5a3706b37e122a67e5ec1670587f37e25a1bc6
2017-03-09 18:17:14 +13:00
Jean-Yves Avenard
c48398abd9 eBug 1347101: P2. Don't rely on MF_E_TRANSFORM_STREAM_CHANGE result. r=mattwoodrow a=Tomcat
Under some circumstances, and seen on Windows 8, a decoded sample can be returned without the MFT returning MF_E_TRANSFORM_STREAM_CHANGE.

For historical reasons, we required that message to be returned at least once to set the output image size. This was required as the decoder used to be recycled with different video streams.

This is no longer the case, we can rely on the video info instead. It also greatly simplifies the code

MozReview-Commit-ID: H14KBiNWrjQ
2017-03-23 16:04:39 +01:00
Carsten "Tomcat" Book
78ce0c822e Backed out changeset ad882b32f2d0 (bug 1347101) for merge bustage on a CLOSED TREE 2017-03-23 14:28:25 +01:00
Carsten "Tomcat" Book
492970c342 merge mozilla-inbound to mozilla-central a=merge 2017-03-23 13:44:09 +01:00
sotaro
b98245c5fc Bug 1349476 - Remove LayersBackend::LAYERS_D3D9 type r=mattwoodrow 2017-03-23 11:00:41 +09:00
John Lin
cbc29c3730 Bug 1347480 - flush decoder after draining to make it accept more input. r=jya
MediaCodec doesn't take any input after EOS unless it is flushed.

MozReview-Commit-ID: LoHlN753e8J

--HG--
extra : rebase_source : 5a051cef2f4afb3357e2756d1f0f2f3ae741295c
2017-03-15 18:38:51 +08:00
Jean-Yves Avenard
10f304bd58 Bug 1347101: P2. Don't rely on MF_E_TRANSFORM_STREAM_CHANGE result. r=mattwoodrow
Under some circumstances, and seen on Windows 8, a decoded sample can be returned without the MFT returning MF_E_TRANSFORM_STREAM_CHANGE.

For historical reasons, we required that message to be returned at least once to set the output image size. This was required as the decoder used to be recycled with different video streams.

This is no longer the case, we can rely on the video info instead. It also greatly simplifies the code

MozReview-Commit-ID: H14KBiNWrjQ

--HG--
extra : rebase_source : d098f884127bc95e3ca4363bf3d0cdda6d3bd771
2017-03-17 01:21:23 +01:00
Kaku Kuo
b09416d50a Bug 1348237 part 2 - move declaration of BlankDecoderModule into a header file; r=jwwang
So that we can write gtests easily at next patch.

MozReview-Commit-ID: 8ZWVYO1hDOW

--HG--
extra : rebase_source : 8c3523b06fe284376d59914ecfa3791a91930fc2
2017-03-17 16:53:21 +08:00
Kaku Kuo
c819daf588 Bug 1348237 part 1 - prevent overflow in BlankVideoDataCreater; r=jwwang
MozReview-Commit-ID: D5BZIfpZjD3

--HG--
extra : rebase_source : 263394e6057415551e9eb36bc3c74daa33a93c30
2017-03-17 16:20:08 +08:00
Kevin Chen
9347006c20 Bug 1160157 - Make AcquireSync RAII. r=bas
--HG--
extra : rebase_source : ac0843be287410b4fed48d7ab06cbba599735d0a
2017-03-17 00:18:00 -04:00
Jean-Yves Avenard
ccf0582e09 Bug 1349345: Use 32 bits float with WMF decoder. r=cpearce
MozReview-Commit-ID: 2cF3D1zQFf4

--HG--
extra : rebase_source : 9c29059d46b5041fc14f442817f76b4beca28452
2017-03-21 22:17:01 +01:00
Kaku Kuo
642536ba3b Bug 1345179 - use MakeUniqueFallible() in BlankVideoDataCreator; r=jwwang
If OOM happends, just return null and the DummyMediaDataDecoder will reject the DecodePromise with NS_ERROR_OUT_OF_MEMORY.

MozReview-Commit-ID: H6sTyoQWZk5

--HG--
extra : rebase_source : 5046a68978b817db8f1191e1f56e80ec5848899c
2017-03-16 12:09:23 +08:00
John Lin
66e158e1c6 Bug 1345599 - part 3: for recyclable decoder, don't drain/flush when stream ID/SPS change. r=jya
MozReview-Commit-ID: 4qtlbMWgfPo

--HG--
extra : rebase_source : f5b71b6803e2f725639e675081bc30cd0b1bde2a
2017-03-14 15:04:52 +08:00
John Lin
6150d45675 Bug 1344649 - part 5: deprecate ConfigurationChanged() once again. r=jya
MozReview-Commit-ID: D9b8rljlNzP

--HG--
extra : rebase_source : 7cd586f506c4c01f21da0b7b44ec0e2798af5e0a
2017-03-14 12:58:27 +08:00
John Lin
50ebd38776 Bug 1344649 - part 4: store frame sizes in queue rather than relying on ConfigurationChanged(). r=jya
MozReview-Commit-ID: 49ICIBs4wzF

--HG--
extra : rebase_source : 81a145a30a2b96b53e4d3092d2baaa54109cf347
2017-03-07 20:03:41 +08:00
John Lin
2f58c785e9 Bug 1344649 - part 3: rename DurationMap and turn it into a generic class. r=jya
MozReview-Commit-ID: AMMxMPkuYXk

--HG--
extra : rebase_source : 438100efafb883c8cd67895657877da9fb6f54ce
2017-03-07 19:49:08 +08:00
John Lin
a5d3bc8a18 Bug 1344649 - part 2: let VideoData::CreateFromImage() accept only neccessary parameters. r=jya
VideoData doesn't care what's in aInfo but display size and aPicture are unused.

MozReview-Commit-ID: IBqq8Rm8dM4

--HG--
extra : rebase_source : 10e2390f87925ef9179d28d86240f68a35c6c6d4
2017-03-09 12:06:24 +08:00
John Lin
9dd28c4c95 Bug 1344649 - part 1: use picture instead of display size to construct Image. r=jya
MozReview-Commit-ID: LkVq9iaj14k

--HG--
extra : rebase_source : e2468aeea1983dc96c42698d24de6f5cacb8deb9
2017-03-09 12:08:34 +08:00
Bas Schouten
f500c10597 Bug 1345814: Don't use mutices when the decoding device is the compositor device anyway. r=mattwoodrow
MozReview-Commit-ID: GOwyVKFSkRa
2017-03-13 12:29:22 +00:00
Kaku Kuo
09feb98f41 Bug 1346120 part 5 - Revert the blank decoder to create green frames; r=jwwang
The blank decoder used to create green frames.
Bug 1274626 patch 2 modifies its behavior to return black frames.
The original implementation is better in memory usage, so we revert it.

MozReview-Commit-ID: Lue63Rsoy3G

--HG--
extra : rebase_source : ba6a1bb74a2b5d61b245c114e4dd5cf32dc29b89
extra : intermediate-source : fcb4f38cf4d4ee2709a3d0d4e2945eef9dc6cab0
extra : source : e920b71a11ebf410f4a1c99708911be98f68586c
2017-03-09 17:26:42 +08:00
Kaku Kuo
7c985e041c Bug 1346120 part 3 - Use NullDecoderModule while suspending a video element's decoder; r=jwwang
MozReview-Commit-ID: L1CsDV5TW5R

--HG--
extra : rebase_source : c7aa851ebdbda6abbf7acb09849b237023d653fe
extra : intermediate-source : 91c5986bef4c236e29deeeca6b14f33405da56a3
extra : source : 2d3146d70fb65da3379dd6a5f126c4caff65e139
2017-03-09 17:12:02 +08:00
Kaku Kuo
e797828ad9 Bug 1346120 part 2 - Implement NullDecoderModule; r=jwwang
The video decoder of NullDecoderModule returns a VideoData with dimension of zero size and no image data.
By this way, we reduce memory usage while a video element is suspended.

MozReview-Commit-ID: IMODFOGdpaj

--HG--
extra : rebase_source : e12dc91158939052b23d4ab9707485bb3565dc41
extra : intermediate-source : f8390b1c52e9ee859c33b7a9d2e34781534eb3ff
extra : source : 8a002d74db6c445dff17aa24d2e92f9c27019b07
2017-03-09 16:07:22 +08:00
Kaku Kuo
be902c66f8 Bug 1346120 part 1 - Extract BlankMediaDataDecoder so it can be shared; r=jwwang
Change name to 'Dummy' to signify it's base for decoders that don't decode.
And we will implement a new NullDecoderModule in the next patch which will utilize the DummyMediaDataDecoder.
MozReview-Commit-ID: LPsczoztgx3

--HG--
extra : rebase_source : 413345139ba060065217cfd7718665091f8f6166
extra : intermediate-source : 12d022e15b7a3a91867293fd2e71510fa084ff02
extra : source : dec60f61cc8809ebe6dd65cb16a325f2272b3ce2
2017-03-09 15:33:53 +08:00
Sebastian Hengst
004811fcc7 Backed out changeset 46090632bad3 (bug 1345814) for failing reftests on Windows 8 x64 with e10s enabled, e.g. webgl-capturestream-test.html?preserve. r=backout n a CLOSED TREE 2017-03-13 19:22:32 +01:00
Bas Schouten
c4b9f352af Bug 1345814: Don't use mutices when the decoding device is the compositor device anyway. r=mattwoodrow
MozReview-Commit-ID: GOwyVKFSkRa
2017-03-13 12:29:22 +00:00
Bas Schouten
f581bd6faa Bug 1346258: Fix disabling of sync texture usage. r=mattwoodrow
MozReview-Commit-ID: 4hIyoM7o6OQ
2017-03-13 12:29:22 +00:00
Kaku Kuo
8eb76e20d9 Bug 1345768 - Fix build error in H264Converter.h/cpp; r=jwwang
MozReview-Commit-ID: IOH5jZyQwZi

--HG--
extra : rebase_source : 32904acadc5187e3aa129a0cf5180e33aecf8b53
2017-03-09 16:06:55 +08:00
Jean-Yves Avenard
9f6d8cd021 Bug 1345545: Prepend SPS/PPS on first frame. r=jolin
MozReview-Commit-ID: 3UxVGjQcYtk

--HG--
extra : rebase_source : 0e16a03e2444dc7206a9bda0e718f2bfdd73b9bd
2017-03-08 18:31:03 +01:00
JW Wang
c2baa5a443 Bug 1345314. P2 - Label runnables in dom/media/platforms/wmf/WMFVideoMFTManager.cpp. r=jya
MozReview-Commit-ID: 25NmRaTp1wy

--HG--
extra : rebase_source : d7db27a86120f0de670d1ba369ebdcaa0f330097
extra : source : 84a47276e3848653ee3956dde373b4596b35ecec
2017-03-08 10:48:28 +08:00
JW Wang
eac0286baf Bug 1345314. P1 - move DeleteOnMainThread() to WMFVideoMFTManager.cpp to discourage the use of nsAutoPtr. r=jya
MozReview-Commit-ID: LxIQcdZtVx7

--HG--
extra : rebase_source : bb413ff39c8a6f0767a3085c6329aee0f7ebe4e2
extra : intermediate-source : 37015a40e525c1192c64dbb5d4bc5cf5fa95ba28
extra : source : e69d2868bfe38092bcc8f6c431439098a4a2afe3
2017-03-07 15:19:29 +08:00
Carsten "Tomcat" Book
96fe421b34 Merge mozilla-central to autoland 2017-03-08 17:04:17 +01:00
Kaku Kuo
24b9d982ba Bug 1345034 - Label runnables in dom/media/WMFMediaDataDecoder.cpp; r=jwwang
MozReview-Commit-ID: G5ioUsJdvQd

--HG--
extra : rebase_source : db5f8d082fa6fff57ab4eb3fc85492dbc6939d9c
2017-03-07 15:26:08 +08:00
Bas Schouten
b2cb2752c9 Bug 1340398 - Part 3: Use NV12 format by default. r=mattwoodrow
MozReview-Commit-ID: DcP40U81FBQ
2017-03-07 20:55:20 +00:00
Bas Schouten
3a86acb691 Bug 1340398 - Part 2: Support NV12 texture hosts in CompositorD3D11. r=mattwoodrow
MozReview-Commit-ID: IdwY1Cs4P9c
2017-03-07 20:55:20 +00:00