Граф коммитов

849 Коммитов

Автор SHA1 Сообщение Дата
Andi-Bogdan Postelnicu c08f1b99c2 Bug 1725137 - Fix gtest suite from dom to be buildable outside unified. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D122338
2021-08-22 10:21:54 +00:00
Cosmin Sabou 84969e5caa Backed out 12 changesets (bug 1665776) for causing mda failures. CLOSED TREE
Backed out changeset 1093b571cd9e (bug 1665776)
Backed out changeset 97401a43356f (bug 1665776)
Backed out changeset e4d1fab7ed91 (bug 1665776)
Backed out changeset eef564e4e8ce (bug 1665776)
Backed out changeset b436ced5a9c2 (bug 1665776)
Backed out changeset 231057bbccc6 (bug 1665776)
Backed out changeset 918d100709b3 (bug 1665776)
Backed out changeset 63a6fb712a7c (bug 1665776)
Backed out changeset 2f9e721a4adb (bug 1665776)
Backed out changeset f65349f581ac (bug 1665776)
Backed out changeset eb289c096758 (bug 1665776)
Backed out changeset 077b96856a67 (bug 1665776)
2021-08-20 01:55:26 +03:00
John Lin 9612231686 Bug 1665776 - p8: add VPx test cases. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D121025
2021-08-19 19:01:21 +00:00
John Lin 7998e7b941 Bug 1665776 - p7: make test suite codec-agnostic and group related tests into same test cases. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D121024
2021-08-19 19:01:20 +00:00
John Lin a99eaceed3 Bug 1665776 - p2: move keyframe interval from H264Specific to VideoConfig. r=alwu
Although libwebrtc put keyframe interval in codec specific data
structures, it is actually used by all supported codecs and can
be shared in the common config type. This makes adding VPx specific
data structures easier.

Differential Revision: https://phabricator.services.mozilla.com/D121019
2021-08-19 19:01:18 +00:00
Narcis Beleuzu 5956c10a41 Backed out 10 changesets (bug 1665776) for mda failures on test_peerConnection_basicH264Video.html. CLOSED TREE
Backed out changeset 495d29e49600 (bug 1665776)
Backed out changeset def1b1ef88a0 (bug 1665776)
Backed out changeset d6c3bea02005 (bug 1665776)
Backed out changeset b5aecfe25f9f (bug 1665776)
Backed out changeset 76ab66d90c6b (bug 1665776)
Backed out changeset d5bd2b250b28 (bug 1665776)
Backed out changeset e8dc6645692d (bug 1665776)
Backed out changeset a1e00e5bd88f (bug 1665776)
Backed out changeset 3f6ff34fda68 (bug 1665776)
Backed out changeset 8d2f96b977ea (bug 1665776)
2021-08-13 04:34:55 +03:00
John Lin f80fe7b06c Bug 1665776 - p8: add VPx test cases. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D121025
2021-08-12 22:12:16 +00:00
John Lin d1457890ac Bug 1665776 - p7: make test suite codec-agnostic and group related tests into same test cases. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D121024
2021-08-12 22:12:15 +00:00
John Lin c15af25135 Bug 1665776 - p2: move keyframe interval from H264Specific to VideoConfig. r=alwu
Although libwebrtc put keyframe interval in codec specific data
structures, it is actually used by all supported codecs and can
be shared in the common config type. This makes adding VPx specific
data structures easier.

Differential Revision: https://phabricator.services.mozilla.com/D121019
2021-08-12 22:12:13 +00:00
Bryce Seager van Dyk dbffb5566d Bug 1724751 - Instead of tags, accept a key system as an argument to GeckoMediaPluginService::GetCDM. r=alwu
Right now, GetCDM is only called with aTags containing a key system string. This
patch changes the function args to reflect that. This makes it easier to reason
about the function without having to look up call sites.

Differential Revision: https://phabricator.services.mozilla.com/D122136
2021-08-10 18:58:10 +00:00
Narcis Beleuzu 12bf02b2bc Backed out 2 changesets (bug 1724751) for GTest failure on ChromiumCDMAdapter.cpp . CLOSED TREE
Backed out changeset 8100f4674794 (bug 1724751)
Backed out changeset 1744680ee04d (bug 1724751)
2021-08-10 19:05:57 +03:00
Bryce Seager van Dyk 260bbe6069 Bug 1724751 - Instead of tags, accept a key system as an argument to GeckoMediaPluginService::GetCDM. r=alwu
Right now, GetCDM is only called with aTags containing a key system string. This
patch changes the function args to reflect that. This makes it easier to reason
about the function without having to look up call sites.

Differential Revision: https://phabricator.services.mozilla.com/D122136
2021-08-10 14:54:02 +00:00
Jon Bauman 2e5d433f82 Bug 1723247 - Update mp4parse-rust to 5326af6 r=kinetik
Differential Revision: https://phabricator.services.mozilla.com/D121449
2021-08-03 23:23:42 +00:00
Chris Peterson 0deaad36cf Bug 1720432 - Fix -Wunsed-but-set-variable warnings in dom/media. r=kinetik
dom/media/gmp/GMPSharedMemManager.cpp:54:10: warning: variable 'total' set but not used [-Wunused-but-set-variable]
dom/media/gtest/TestMP3Demuxer.cpp:423:13: warning: variable 'numSamples' set but not used [-Wunused-but-set-variable]

GMPSharedMemManager.cpp updates local variable `total`, but never reads it so we can remove it.

TestMP3Demuxer.cpp updates local variable `numSamples`, but the EXPECT test checks that use `numSamples` are commented out. I don't know how to address the commented-out checks' issues, but testing that numSamples is non-negative seems a safe assumption (and a way to fix the -Wunused-but-set-variable warning).

Differential Revision: https://phabricator.services.mozilla.com/D120799
2021-07-25 07:51:15 +00:00
Bryce Seager van Dyk 5af3985b1c Bug 1721867 - Remove the concept of decryptor id from the GMP. r=alwu,jolin
Decryptor id is no longer used anywhere functional, but we still have code
referencing and plumbing values around. This patch removes all the remaining
usage I can find in Gecko.

Differential Revision: https://phabricator.services.mozilla.com/D120647
2021-07-22 22:19:53 +00:00
Stefan Zabka 7bdc63c79c Bug 1705034 - Implemented ForgetThisBaseDomain in GMPServiceParent. r=pbz,bryce
Differential Revision: https://phabricator.services.mozilla.com/D116412
2021-07-07 10:51:59 +00:00
Butkovits Atila d38447f8c9 Backed out changeset 0bf78f953aac (bug 1705034) for causing Gtest failures. 2021-07-06 21:40:33 +03:00
Stefan Zabka caec487963 Bug 1705034 - Implemented ForgetThisBaseDomain in GMPServiceParent. r=pbz,bryce
Differential Revision: https://phabricator.services.mozilla.com/D116412
2021-07-06 16:38:44 +00:00
Chun-Min Chang 54e5af0ed9 Bug 1716248 - Change AppendAndConsumeChunk's input parameter type r=padenot
It's better to change the input parameter's type of
`AppendAndConsumeChunk` from `AudioChunk*` to `AudioChunk&&` since the
`AudioChunk` will be consumed once it's fed to this function.

One benefit for doing so is to prevent the consumed `AudioChunk` from
being used again after it's moved/consumed. Gecko has a clang-tidy
check, bugprone-use-after-move [1], to avoid this kind of error. We
should utilize this check instead of catching used-after-move error by
human eyes.

[1]: https://searchfox.org/mozilla-central/rev/f351e19360729b351bfc7c1386d6e4ca4ea676e2/tools/clang-tidy/config.yaml#70

Differential Revision: https://phabricator.services.mozilla.com/D117714
2021-06-23 00:24:16 +00:00
Butkovits Atila 7f57e645d9 Backed out changeset da97faf315ee (bug 1716248) for causing Gtest failures. CLOSED TREE 2021-06-22 01:46:58 +03:00
Chun-Min Chang 757215321c Bug 1716248 - Change AppendAndConsumeChunk's input parameter type r=padenot
It's better to change the input parameter's type of
`AppendAndConsumeChunk` from `AudioChunk*` to `AudioChunk&&` since the
`AudioChunk` will be consumed once it's fed to this function.

One benefit for doing so is to prevent the consumed `AudioChunk` from
being used again after it's moved/consumed. Gecko has a clang-tidy
check, bugprone-use-after-move [1], to avoid this kind of error. We
should utilize this check instead of catching used-after-move error by
human eyes.

Differential Revision: https://phabricator.services.mozilla.com/D117714
2021-06-21 21:50:45 +00:00
Bryce Seager van Dyk f4617e8f88 Bug 1715617 - Remove TestParser.cpp:TestFileData::mHeader. r=jbauman,kinetik
As far a I can tell, mValidMoof does the same job as mHeader and has a clearer
name. Let's just remove mHeader and make the tests a little simpler. Longer
discussion below about why we may want to separate the flags, but I'm fairly
confident that it does not apply to our current tests.

Hypothetically it may make sense to separate these flags. mValidMoof is checked
against RebuildFragmentedIndex, while mHeader is checking if the moof parser has
at least one moof. If we RebuildFragmentedIndex once and it returns true, that
implies we have a least one moof. That is the state of all our current tests
IIUC. So there is no need to have separate flags. However, if we call
RebuildFragmentedIndex multiple times, and it succeeds, then fails, and we don't
evict moofs, then we could have times where the parser still has moofs stored
internally, even if we have a failed Rebuild. But we're not doing that as far as
I can tell in these tests.

Differential Revision: https://phabricator.services.mozilla.com/D117351
2021-06-14 17:09:41 +00:00
Bryce Seager van Dyk 68e04f7648 Bug 1714125 - Add multiple sample descriptions with crypto testcase to mp4 parser gtests. r=jbauman
Add an init segment with 2 sample description entries, each with crypto data, to
the mp4 parser gtests.

3 test cases are updated:
- We ensure the init data parses with expected results as part of our general
  'does this header parse, and with what result' style test.
- We ensure expected telemetry data is gather as part of our specialized
  telemetry tests. Specifically, this adds coverage to the previously uncovered
  multiple sample description entries with crypto case.
- We relax the expectation that encrypted files we parse with the MoofParser
  will only have one encrypted sample description entry. We now expect these
  files to have at least one encrypted entry.

Note the test case has the same crypto info in both entires, so these tests do
not cover the case where we need to handle different crypto info per sample
description.

Differential Revision: https://phabricator.services.mozilla.com/D117052
2021-06-09 18:04:53 +00:00
Dorel Luca b453edf851 Backed out 3 changesets (bug 1714125) for Gtest failures in MoofParser.test_case_mp4. CLOSED TREE
Backed out changeset 33fe5ea6200d (bug 1714125)
Backed out changeset 07c910af0750 (bug 1714125)
Backed out changeset 0ed3355e9f7d (bug 1714125)
2021-06-09 00:15:54 +03:00
Bryce Seager van Dyk 8e01323510 Bug 1714125 - Add multiple sample descriptions with crypto testcase to mp4 parser gtests. r=jbauman
Add an init segment with 2 sample description entries, each with crypto data, to
the mp4 parser gtests.

2 test cases are updated:
- We ensure the init data parses with expected results as part of our general
  'does this header parse, and with what result' style test.
- We ensure expected telemetry data is gather as part of our specialized
  telemetry tests. Specifically, this adds coverage to the previously uncovered
  multiple sample description entries with crypto case.

Note the test case has the same crypto info in both entires, so these tests do
not cover the case where we need to handle different crypto info per sample
description.

Differential Revision: https://phabricator.services.mozilla.com/D117052
2021-06-08 20:05:15 +00:00
Chun-Min Chang d2f2ea20bb Bug 1702646 - Fix TestAudioInputProcessing tests r=padenot
The AudioInputProcessing now needs to call ProcessInput to process the
given input data instead of processing them in NotifyInputData

Differential Revision: https://phabricator.services.mozilla.com/D116673
2021-06-08 00:48:20 +00:00
Chun-Min Chang c95e8979b6 Bug 1702646 - Share AudioSegments among AudioInputTrack r=padenot
Each AudioInputTrack has its own AudioSegments storing the input audio
data. When the AudioInputTrack is in pass-through mode, the AudioSegment
is just the data de-interleaved from its raw data, without any audio
processing magic applied on it. If there are multiple AudioInputTracks
in pass-through mode exist in the same graph, then all of their
AudioSegments are same.

Before this patch, each of these AudioInputTracks allocates its own
space to store its own AudioSegments even those data are same. This
patch makes it possible for these AudioInputTracks to share the same
AudioSegment data they need. By creating the AudioSegment in the
NativeInputTrack, which is mapped to one specific device and is
connected to the AudioInputTrack, the AudioInputTrack can fetch the
AudioSegment data when they need and then append shared-references of
the AudioChunk, inside the fetched AudioSegment, into their own
AudioSegment. Therefore, we can have some AudioChunks created by the
NativeInputTrack and shared among the AudioInputTracks in pass-through
mode.

Differential Revision: https://phabricator.services.mozilla.com/D114801
2021-06-08 00:48:20 +00:00
alwu b9d1fb014e Bug 1517199 - part4 : add gtest. r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D114922
2021-06-02 16:39:02 +00:00
Noemi Erli 3fe08775d6 Backed out 3 changesets (bug 1702646) for causing gtest failures CLOSED TREE
Backed out changeset 2b5f35e21e84 (bug 1702646)
Backed out changeset 13dc1577b2a0 (bug 1702646)
Backed out changeset f87a905f445a (bug 1702646)
2021-06-02 12:11:51 +03:00
Chun-Min Chang 92125abae4 Bug 1702646 - Share AudioSegments among AudioInputTrack r=padenot
Each AudioInputTrack has its own AudioSegments storing the input audio
data. When the AudioInputTrack is in pass-through mode, the AudioSegment
is just the data de-interleaved from its raw data, without any audio
processing magic applied on it. If there are multiple AudioInputTracks
in pass-through mode exist in the same graph, then all of their
AudioSegments are same.

Before this patch, each of these AudioInputTracks allocates its own
space to store its own AudioSegments even those data are same. This
patch makes it possible for these AudioInputTracks to share the same
AudioSegment data they need. By creating the AudioSegment in the
NativeInputTrack, which is mapped to one specific device and is
connected to the AudioInputTrack, the AudioInputTrack can fetch the
AudioSegment data when they need and then append shared-references of
the AudioChunk, inside the fetched AudioSegment, into their own
AudioSegment. Therefore, we can have some AudioChunks created by the
NativeInputTrack and shared among the AudioInputTracks in pass-through
mode.

Differential Revision: https://phabricator.services.mozilla.com/D114801
2021-06-02 01:05:20 +00:00
Mike Hommey d4ae277433 Bug 1712031 - Adjust the type of fallbackIterations to match that of IterationCount(). r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D115564
2021-05-24 21:40:27 +00:00
Joel Maher 3ad9f06697 Bug 1710923 - migrate windows 7x32 debug tests to windows 10x32. r=ahal
Differential Revision: https://phabricator.services.mozilla.com/D115017
2021-05-24 20:06:43 +00:00
Bryce Seager van Dyk acbeaeeb24 Bug 1706164 - Plumb QueryOutputProtectionStatus requests from the CDM to MediaKeys. r=alwu
This patch plumbs the QueryOutputProtectionStatus call from the CDM up to the
MediaKeys. This is plumbing is done to get the request to an endpoint of Gecko
C++ code, and future patches will do further plumbing in order to complete the
query.

After the first query is complete, we cache the result in a CDM's
ChromiumCDMParent and update the value only when notified of changes from the
MediaKeys. This has the benefit of that checks after the first don't need to
touch the main thread. This avoids adding more main thread work, and means we
can still complete checks in a timely fashion even if the main thread is running
hot.

We cache in the parent rather than the child so that the parent can make
decisions on how to handle requests even if the CDM machinery is not yet fully
initialized. In future it may make sense to move the caching to the child, but
I'd prefer to do this only after other refactoring of the machinery which I
consider out of scope for this bug.

Future patches will ensure listeners are in place such that the cached data is
updated when updates are received further up the stack.

Differential Revision: https://phabricator.services.mozilla.com/D115415
2021-05-24 16:50:18 +00:00
Sandor Molnar 2ef849fd1c Backed out 4 changesets (bug 1706164) for causing build bustages in media/eme/MediaKeys. CLOSED TREE
Backed out changeset 5d3f67175482 (bug 1706164)
Backed out changeset 4630540c3717 (bug 1706164)
Backed out changeset 4a2463270858 (bug 1706164)
Backed out changeset a2b896ddc631 (bug 1706164)
2021-05-21 23:21:58 +03:00
Bryce Seager van Dyk 243f6d23d0 Bug 1706164 - Plumb QueryOutputProtectionStatus requests from the CDM to MediaKeys. r=alwu
This patch plumbs the QueryOutputProtectionStatus call from the CDM up to the
MediaKeys. This is plumbing is done to get the request to an endpoint of Gecko
C++ code, and future patches will do further plumbing in order to complete the
query.

After the first query is complete, we cache the result in a CDM's
ChromiumCDMParent and update the value only when notified of changes from the
MediaKeys. This has the benefit of that checks after the first don't need to
touch the main thread. This avoids adding more main thread work, and means we
can still complete checks in a timely fashion even if the main thread is running
hot.

We cache in the parent rather than the child so that the parent can make
decisions on how to handle requests even if the CDM machinery is not yet fully
initialized. In future it may make sense to move the caching to the child, but
I'd prefer to do this only after other refactoring of the machinery which I
consider out of scope for this bug.

Future patches will ensure listeners are in place such that the cached data is
updated when updates are received further up the stack.

Differential Revision: https://phabricator.services.mozilla.com/D115415
2021-05-21 19:59:53 +00:00
Csoregi Natalia 814d52a59c Backed out changeset 7ed8d739fe9a (bug 1710923) for causing cppunit failures. CLOSED TREE 2021-05-20 20:48:22 +03:00
Joel Maher 359e6f6227 Bug 1710923 - migrate windows 7x32 debug tests to windows 10x32. r=ahal
Differential Revision: https://phabricator.services.mozilla.com/D115017
2021-05-20 16:31:20 +00:00
Sandor Molnar 4e346690ad Backed out changeset 7fb52bd0c5b6 (bug 1710923) for causing win10 reftest failures. CLOSED TREE 2021-05-19 17:11:39 +03:00
Joel Maher ce8b9ba202 Bug 1710923 - migrate windows 7x32 debug tests to windows 10x32. r=ahal
Differential Revision: https://phabricator.services.mozilla.com/D115017
2021-05-19 12:47:29 +00:00
Iulian Moraru a2a59b7c80 Backed out changeset bdc93c5c667f (bug 1710923) for causing reftest failures on scrollbar-marks-overlay.html. CLOSED TREE 2021-05-14 01:51:04 +03:00
Joel Maher bd3999c92b Bug 1710923 - migrate windows 7x32 debug tests to windows 10x32. r=ahal
Differential Revision: https://phabricator.services.mozilla.com/D115017
2021-05-13 15:07:48 +00:00
alwu e9feafd386 Bug 1695265 - part3 : add gtest for 'AudioDecoderInputTrack'. r=pehrsons,padenot
Differential Revision: https://phabricator.services.mozilla.com/D110503
2021-04-29 01:37:21 +00:00
Chun-Min Chang 6ee4485293 Bug 1706524 - Track AudioDeviceID in AudioInputTrack r=padenot
This patch adds an `AudioDeviceID` member in `AudioInputTrack`. This
aims to simplify `AudioInputTrack::CloseAudioInput`.

Before this patch, the `AudioDeviceID` is tracked by
`MediaEngineWebRTCMicrophoneSource` only instead so `AudioInputTrack`
has no idea of what device it pairs with. One main drawback is that
`MediaTrackGraphImpl` needs to search all the `AudioDataListener`
inside it to infer what device is closed when
`AudioInputTrack::Destroy()` is called, since `AudioInputTrack`
doesn't know what is its paired device, which gives an O(N) time
complexity, where N is the number of `AudioDataListener` in
`MediaTrackGraphImpl`

A simple way to reduce the time complexity from O(N) to O(1) is to track
the paired device when `AudioInputTrack::OpenAudioInput` is called. This
also enables the possibility to remove `mInputDeviceUsers` in Bug
1702646.

Differential Revision: https://phabricator.services.mozilla.com/D113040
2021-04-28 18:33:58 +00:00
Brindusan Cristian 2c692937aa Backed out 3 changesets (bug 1695265) for causing crashtest assertion failures. CLOSED TREE
Backed out changeset 7d2f645a1dc4 (bug 1695265)
Backed out changeset 35cb5f5e17b7 (bug 1695265)
Backed out changeset 52861f76787f (bug 1695265)
2021-04-28 22:29:29 +03:00
alwu d056a883d6 Bug 1695265 - part3 : add gtest for 'AudioDecoderInputTrack'. r=pehrsons,padenot
Differential Revision: https://phabricator.services.mozilla.com/D110503
2021-04-28 16:50:50 +00:00
Brendan Early 92dd73d18c Bug 1120222 - Part 2 - Add tests r=padenot
Differential Revision: https://phabricator.services.mozilla.com/D102797
2021-04-19 15:17:27 +00:00
alwu bf43d3913e Bug 1702823 - Clear callback function after listener gets revoked. r=bryce
The callback function itself might contains a strong reference to other object, and that reference should be clear as well when the listener explicity gets revoked, which means we won't trigger the function anymore.

If the reference doen't be clear, then it's possible to cause a memory leak if the reference eventually becomes a cycle.

Differential Revision: https://phabricator.services.mozilla.com/D110706
2021-04-05 20:04:35 +00:00
alwu 72477d0384 Bug 1701992 - fix `MediaQueue::GetElementsAfter()`. r=bryce
Current `GetElementsAfter()` is wrong, the result array would still contain the element which end time is earlier or equal to the given time.

Differential Revision: https://phabricator.services.mozilla.com/D107170
2021-04-01 00:37:06 +00:00
Andreas Pehrson 545b469340 Bug 1696794 - Add gtest. r=bryce
Differential Revision: https://phabricator.services.mozilla.com/D109028
2021-03-19 19:16:57 +00:00
Bogdan Tara 12a064b827 Backed out 2 changesets (bug 1696794) for bustage complaining about gtest.h CLOSED TREE
Backed out changeset c66f0d85eed2 (bug 1696794)
Backed out changeset 428a79637282 (bug 1696794)
2021-03-19 18:48:24 +02:00