зеркало из https://github.com/mozilla/gecko-dev.git
8eff3a166e
Rust's std::sync::Mutex has some nice properties. Its philosphy is to lock data, rather than code. It wraps data you're trying to make thread safe with a mutex, and in order to get a reference to the wrapped data you need to lock the mutex and access it through an intermediate layer. This is good, as the mutex that's protecting access to the data is explicitly associated with the data, and it's impossible to forget to take the lock before accessing the data. This patch adds a similar mutex wrapper to Media Playback code. If it works well, we can look at moving it into xpcom. MozReview-Commit-ID: 4APAic6Fh8m --HG-- extra : rebase_source : 3dc2b4916d3fd31f622af2b0c26ac3c0707d3300 |
||
---|---|---|
.. | ||
mp4_demuxer | ||
Cargo.toml | ||
GMPTestMonitor.h | ||
MockMediaDecoderOwner.h | ||
MockMediaResource.cpp | ||
MockMediaResource.h | ||
TestAudioBuffers.cpp | ||
TestAudioCompactor.cpp | ||
TestAudioMixer.cpp | ||
TestAudioPacketizer.cpp | ||
TestAudioSegment.cpp | ||
TestAudioTrackEncoder.cpp | ||
TestBlankVideoDataCreator.cpp | ||
TestCDMStorage.cpp | ||
TestDataMutex.cpp | ||
TestGMPCrossOrigin.cpp | ||
TestGMPRemoveAndDelete.cpp | ||
TestGMPUtils.cpp | ||
TestIntervalSet.cpp | ||
TestMP3Demuxer.cpp | ||
TestMP4Demuxer.cpp | ||
TestMediaDataDecoder.cpp | ||
TestMediaEventSource.cpp | ||
TestMediaMIMETypes.cpp | ||
TestRust.cpp | ||
TestTimeUnit.cpp | ||
TestVPXDecoding.cpp | ||
TestVideoSegment.cpp | ||
TestVideoTrackEncoder.cpp | ||
TestVideoUtils.cpp | ||
TestWebMBuffered.cpp | ||
TestWebMWriter.cpp | ||
dash_dashinit.mp4 | ||
hello.rs | ||
id3v2header.mp3 | ||
moz.build | ||
negative_duration.mp4 | ||
noise.mp3 | ||
noise_vbr.mp3 | ||
short-zero-in-moov.mp4 | ||
short-zero-inband.mov | ||
small-shot-false-positive.mp3 | ||
small-shot-partial-xing.mp3 | ||
small-shot.mp3 | ||
test.webm | ||
test_case_1224361.vp8.ivf | ||
test_case_1224363.vp8.ivf | ||
test_case_1224369.vp8.ivf |