Commit Graph

31 Commits

Author SHA1 Message Date
trav90 1a2fea0658 Re-land "Dispatch AudioSink notifications asynchronously"
This is needed by some new code that I am working on.
2018-07-25 07:03:56 +08:00
trav90 df074df1ee Use state mirroring for NextFrameStatus 2018-07-25 07:03:42 +08:00
trav90 1e249c36f8 Use state watching machinery for mReadyState updates 2018-07-25 07:03:38 +08:00
trav90 04513e7957 Force state machine setting to go through a setter
This is needed so that we can hook up the state mirroring in a subsequent commit.
2018-07-25 07:03:32 +08:00
trav90 b6bb9afb37 Move the GetCurrent TLS logic into AbstractThread 2018-07-25 06:57:47 +08:00
trav90 533987a47d Implement the ability to get the currently running task queue
This will be useful for asserting things.
2018-07-25 06:55:30 +08:00
trav90 3090135f8e Do static initialization explicitly 2018-07-25 06:55:27 +08:00
trav90 e1caa768c4 Handle playback ended in a consistent way for both file and stream case 2018-07-25 06:53:09 +08:00
trav90 a068fb2b80 Rework and simplify stream clock calculation in MediaDecoderStateMachine 2018-07-25 06:53:05 +08:00
trav90 b6cdd50380 Remove wrapper-style AbstractThreads for MediaTaskQueue and have callers pass an AbstractThread directly to promise APIs 2018-07-25 06:52:28 +08:00
trav90 702d802110 Add a convenience/efficiently routine to get an AbstractThread for the main thread 2018-07-25 06:52:23 +08:00
trav90 7ae60742ff Nuke remaining GStreamer code 2018-07-25 06:45:07 +08:00
trav90 227622835c Rename MediaDecoder::OnDecodeThread to MediaDecoder::OnDecodeTaskQueue 2018-07-25 06:44:59 +08:00
trav90 2d35bde18f Rename MDSM::OnDecodeThread to MDSM::OnDecodeTaskQueue 2018-07-25 06:44:53 +08:00
trav90 19e0f7aa42 Rename OnStateMachineThread-like functions to reflect the fact that it's a task queue 2018-07-25 06:44:51 +08:00
trav90 17e6d71294 Revert "Dispatch AudioSink notifications asynchronously" 2018-07-25 06:36:53 +08:00
trav90 b20b8dadab Replace dom::TimeRanges with TimeIntervals object 2018-07-25 01:27:34 +08:00
trav90 7e5b4386f2 Combine MediaInfo and mp4_demuxer::TrackConfig 2018-07-25 01:18:31 +08:00
trav90 d5e2cf7abc Dispatch AudioSink notifications asynchronously 2018-07-25 01:05:51 +08:00
trav90 5155516c96 Make MDSM::StartBuffering happen on the state machine thread 2018-07-25 01:05:46 +08:00
trav90 90904cb897 Make MDSM::Shutdown happen on the state machine thread 2018-07-25 01:05:42 +08:00
trav90 5507f0cc15 Update AudioOffloadPlayer seek to use new promise-based interface 2018-07-25 01:03:47 +08:00
trav90 07ffc3fc1e Deliver NotifyWaitingForResourcesStatusChanged asynchronously on the state machine task queue
The previous setup is wacky, and can cause the notification to reach the state machine before the promise rejection, which causes us to stall intermittently. We also take the opportunity to be a bit less trigger happy when we fire it in MediaSourceReader.cpp.
2018-07-25 01:03:45 +08:00
trav90 74eb7093f6 Use promises for metadata decoding 2018-07-25 01:03:43 +08:00
trav90 b265ff9e74 Switch the MDSM to a task queue 2018-07-25 01:03:34 +08:00
trav90 2d0902db6e Make the MediaDecoder-to-MediaDecoderStateMachine interface Promise-based 2018-07-25 01:03:21 +08:00
trav90 8acc4e725d Move some work from MDSM::Seek to MDSM::InitiateSeek
This has two implications:
1. We no longer need to pipe mQueuedSeekTarget through MDSM::Seek to get the appropriate clamping.
2. MDSM::Seek doesn't _need_ to be called on the main thread anymore.
2018-07-25 01:03:08 +08:00
trav90 fde7400175 Stop updating playback position from Ogg seek and remove MediaDecoder::UpdatePlaybackPosition
The ogg reader makes two adjustments to the seek time - the first is to clamp it between start and end time, which MDSM already does. The second is to subtract SEEK_OPUS_PREROLL from the target. If we wanted to, we could return this as the resolve value in the seek promise and handle the update in the MDSM. But DropVideoUpToSeekTarget should actually handle this just fine.
2018-07-25 01:03:05 +08:00
trav90 62337b35dc Return samples on the state machine thread
This is necessary because we're going to want to start disconnecting sample and seek requests directly from the state machine thread, and the machinery asserts that disconnection happens on the same thread as resolution.
2018-07-25 01:02:38 +08:00
wolfbeast 02112270b5 Remove EME (Encrypted Media Extensions) DRM support.
This resolves #102.
2018-07-24 23:32:00 +08:00
Moonchild baf46a6bf1 Merge pull request #1 from mozilla/esr38: Esr38 upstream pull 2018-07-24 23:04:07 +08:00