Commit Graph

89 Commits

Author SHA1 Message Date
sajitk
582e1a55fa Bug 1219480 - Replace PRLogModuleInfo with LazyLogModule in the media directory. r=rillian 2015-11-15 14:49:01 +01:00
JW Wang
8dedbfa33d Bug 1223599 - Remove the throttling argument from AbstractMediaDecoder::NotifyDataArrived(). r=jya. 2015-11-11 17:59:16 +08:00
Wes Kocher
f3a9eb2a26 Backed out changeset 1e5f3d1151d6 (bug 1219480) for cpp unittest bustage CLOSED TREE
--HG--
extra : commitid : BMVKq6cPeho
2015-11-11 09:36:56 -08:00
sajitk
3cbe348cdd Bug 1219480 - Replace PRLogModuleInfo with LazyLogModule in the media directory. r=rillian
--HG--
extra : rebase_source : c73098485fa005d914304fb6e7f8eba3c15e66dc
2015-11-11 06:52:00 +01:00
JW Wang
2344481e8c Bug 1220558. Part 2 - remove unused members. r=jya. 2015-11-11 07:43:41 +08:00
JW Wang
4f2d0e76bc Bug 1220558. Part 1 - remove unused arguments from MediaDecoderReader::DispatchNotifyDataArrived() and its callees/callers. r=jya. 2015-11-11 07:43:38 +08:00
Guang-De Lin
5fc8c948b4 Bug 1150305 - sourcebuffer.buffered returns the same object if not changed. r=roc, r=bz, r=jya
--HG--
extra : rebase_source : ffacfcb39b567a6cd034b081f4330d88aacb98f4
2015-10-19 14:10:47 +08:00
Nathan Froyd
01583602a9 Bug 1207245 - part 6 - rename nsRefPtr<T> to RefPtr<T>; r=ehsan; a=Tomcat
The bulk of this commit was generated with a script, executed at the top
level of a typical source code checkout.  The only non-machine-generated
part was modifying MFBT's moz.build to reflect the new naming.

CLOSED TREE makes big refactorings like this a piece of cake.

 # The main substitution.
find . -name '*.cpp' -o -name '*.cc' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    xargs perl -p -i -e '
 s/nsRefPtr\.h/RefPtr\.h/g; # handle includes
 s/nsRefPtr ?</RefPtr</g;   # handle declarations and variables
'

 # Handle a special friend declaration in gfx/layers/AtomicRefCountedWithFinalize.h.
perl -p -i -e 's/::nsRefPtr;/::RefPtr;/' gfx/layers/AtomicRefCountedWithFinalize.h

 # Handle nsRefPtr.h itself, a couple places that define constructors
 # from nsRefPtr, and code generators specially.  We do this here, rather
 # than indiscriminantly s/nsRefPtr/RefPtr/, because that would rename
 # things like nsRefPtrHashtable.
perl -p -i -e 's/nsRefPtr/RefPtr/g' \
     mfbt/nsRefPtr.h \
     xpcom/glue/nsCOMPtr.h \
     xpcom/base/OwningNonNull.h \
     ipc/ipdl/ipdl/lower.py \
     ipc/ipdl/ipdl/builtin.py \
     dom/bindings/Codegen.py \
     python/lldbutils/lldbutils/utils.py

 # In our indiscriminate substitution above, we renamed
 # nsRefPtrGetterAddRefs, the class behind getter_AddRefs.  Fix that up.
find . -name '*.cpp' -o -name '*.h' -o -name '*.idl' | \
    xargs perl -p -i -e 's/nsRefPtrGetterAddRefs/RefPtrGetterAddRefs/g'

if [ -d .git ]; then
    git mv mfbt/nsRefPtr.h mfbt/RefPtr.h
else
    hg mv mfbt/nsRefPtr.h mfbt/RefPtr.h
fi

--HG--
rename : mfbt/nsRefPtr.h => mfbt/RefPtr.h
2015-10-18 01:24:48 -04:00
Jean-Yves Avenard
43f2be19a3 Bug 1204757: [MSE] P2. Remove use of MediaDecoder::NotifyWaitingForResourcesStatusChanged(). r=cpearce 2015-09-16 18:14:18 +10:00
Jean-Yves Avenard
eb81f3580e Bug 1204419: P2. Remove old MediaSource implementation. r=cpearce 2015-09-16 18:14:11 +10:00
Jean-Yves Avenard
0e869054eb Bug 1194188: [MSE] Don't allow call to appendBuffer if media element is in error. r=cpearce 2015-08-14 15:33:45 +10:00
Jean-Yves Avenard
8905370e55 Bug 1190019: [MSE] P1. Remove cycle between SourceBuffer and TrackBuffersManager. r=cpearce
Instead we use a a ref-counted attribute holder to store those arguments.
2015-08-04 16:19:14 +10:00
Ralph Giles
31d84bc29e Bug 1186257 - Add missing mediasource includes. r=jya
Add missing includes, forward declarations, and fix up
namespace references so dom/media/mediasource compiles
in a non-unified build.

The header side at least is important for writing unit tests.
2015-07-22 16:59:25 -07:00
Jean-Yves Avenard
48ecf05758 Bug 1171760: P4. Process an entire media segment at a time rather than frame by frame. r=gerald
This provides significant speed improvement, halving the CPU usage.
Rationalise similar methods.
This assumes that frames within a media segment are continuous.
2015-07-01 11:42:51 +10:00
Jean-Yves Avenard
e3f0f0b86c Bug 1177147: Set mediasource duration to group end timestamp. r=karlt 2015-07-01 11:42:49 +10:00
Bobby Holley
3985c88eb7 Bug 1175768 - Throttle NotifyDataArrived. r=jya 2015-06-27 01:19:14 -07:00
Bobby Holley
a80e87862b Bug 1175768 - Use mirroring for buffered ranges. r=jya 2015-06-27 01:19:13 -07:00
Bobby Holley
f25ea07acc Bug 1175768 - Dispatch NotifyDataArrived and remove the aBuffer argument. r=jya
It would be nice to remove the argument in a separate patch, but we can't
perform MediaResource reads on the main thread, so the SilentReadAt stuff
needs to happen at the same time as the off-main-thread stuff.
2015-06-27 01:19:10 -07:00
Jean-Yves Avenard
2b840ef7d9 Bug 1176178: P3. Returns error as per spec if eviction failed. r=gerald 2015-06-23 17:25:22 -07:00
Jean-Yves Avenard
acaf5e8dc5 Bug 1176178: P2. Bump eviction threshold to 100MiB. r=kentuckyfriedtakahe
A 75MB eviction threshold often causes stalls when playing YouTube's 4K content.
2015-06-23 17:25:22 -07:00
Ryan VanderMeulen
d9ca5de3ed Backed out 8 changesets (bug 1175768) for frequent media test failures.
Backed out changeset a369cfb95b59 (bug 1175768)
Backed out changeset e02dd312d622 (bug 1175768)
Backed out changeset 6776ce74b9e5 (bug 1175768)
Backed out changeset 6aa5fa1d318e (bug 1175768)
Backed out changeset a8bd7a0d2aea (bug 1175768)
Backed out changeset 41ffc9a9ac48 (bug 1175768)
Backed out changeset 2d2cefa397dc (bug 1175768)
Backed out changeset 4e06368496d2 (bug 1175768)

CLOSED TREE
2015-06-23 16:20:15 -04:00
Bobby Holley
6925b1f100 Bug 1175768 - Throttle NotifyDataArrived. r=jya 2015-06-22 22:53:09 -07:00
Bobby Holley
5c20ea36aa Bug 1175768 - Use mirroring for buffered ranges. r=jya 2015-06-22 22:53:09 -07:00
Bobby Holley
23c16e6894 Bug 1175768 - Dispatch NotifyDataArrived and remove the aBuffer argument. r=jya
It would be nice to remove the argument in a separate patch, but we can't
perform MediaResource reads on the main thread, so the SilentReadAt stuff
needs to happen at the same time as the off-main-thread stuff.
2015-06-22 22:53:07 -07:00
Jean-Yves Avenard
422de510c1 Bug 1176494: P1. Ensure that progress event is fired upon successful appendBuffer. r=gerald 2015-06-21 01:26:57 +10:00
Jean-Yves Avenard
a863e675ee Bug 1175059: P3. Remove appendMode test assertion. r=kentuckyfriedtakahe
SourceBuffer segment mode is now supported.
2015-06-19 16:45:25 +10:00
Jean-Yves Avenard
df091bbb37 Bug 1175037: Ensure MediaFormatReader is notified when new data is received. r=alfredo 2015-06-19 16:45:22 +10:00
Jean-Yves Avenard
091307ab71 Bug 1174584: P3. Do not error in prepare append if we've reached our memory threshold. r=gerald
In the new MSE architecture. eviction is done asynchronously, also being super accurate, eviction will
always succeed.
Limit our eviction rate to be a minimum of 512kB.
2015-06-19 16:45:19 +10:00
Birunthan Mohanathas
2d96c72f58 Bug 1174220 - Part 2: Use MediaByteBuffer instead of MediaLargeByteBuffer. r=jya
All MediaLargeByteBuffer calls already include the `mozilla::fallible`
parameter so we can safely replace MediaLargeByteBuffer with MediaByteBuffer.
2015-06-14 21:37:13 -07:00
Jean-Yves Avenard
85886b1736 Bug 1171311: P5. Force update of buffered range after endOfStream. r=cajbir
--HG--
extra : rebase_source : 087eca5adee88230d7c8693df5d1b53008cfd891
2015-06-12 09:26:58 +10:00
Jean-Yves Avenard
b6bafeb601 Bug 1171311: P3. Add MediaSourceDemuxer object. r=cpearce
Code isn't active. Need to set media.mediasource.format-reader to true.

--HG--
extra : rebase_source : 4996284f3eac81338548376f055c4849025233f3
2015-06-12 09:26:57 +10:00
Jean-Yves Avenard
a998798778 Bug 1171330: P10. Add TrackBuffersManager object. r=cajbir
This implements MSE's SourceBuffer exactly per spec.
No memory or speed optimisations of any kind were added for the purpose of
being 100% W3C spec compliant.

--HG--
extra : rebase_source : fe010841210c66e20ce55a45d76fd6736f9d3a7f
2015-06-11 15:55:20 +10:00
Jean-Yves Avenard
ca280f4bf4 Bug 1171330: P6. Make RangeRemoval use promises. r=cajbir
--HG--
extra : rebase_source : f96e700000c86e2902cbcff86523faa0914dffd6
2015-06-11 15:55:12 +10:00
Jean-Yves Avenard
323f8c749d Bug 1171330: P5. Split AppendData task to be closer to spec. r=cajbir.
--HG--
extra : rebase_source : 43000d795f7633786cd8319213da795e97151a9e
2015-06-11 15:49:50 +10:00
Jean-Yves Avenard
97f3b3817f Bug 1165819: Part2. Use TimeUnits in SourceBuffer. r=mattwoodrow 2015-06-05 11:53:05 +10:00
Jean-Yves Avenard
69f4fc3572 Bug 1165819: Abstract TrackBuffer interface. r=kentuckyfriedtakahe 2015-06-05 11:52:57 +10:00
Eric Rahm
75c4bebb79 Bug 1165515 - Part 13-2: Replace usage of PRLogModuleLevel and PR_LOG_*. rs=froydnj
This is straightforward mapping of PR_LOG levels to their LogLevel
counterparts:
  PR_LOG_ERROR   -> LogLevel::Error
  PR_LOG_WARNING -> LogLevel::Warning
  PR_LOG_WARN    -> LogLevel::Warning
  PR_LOG_INFO    -> LogLevel::Info
  PR_LOG_DEBUG   -> LogLevel::Debug
  PR_LOG_NOTICE  -> LogLevel::Debug
  PR_LOG_VERBOSE -> LogLevel::Verbose

Instances of PRLogModuleLevel were mapped to a fully qualified
mozilla::LogLevel, instances of PR_LOG levels in #defines were mapped to a
fully qualified mozilla::LogLevel::* level, and all other instances were
mapped to us a shorter format of LogLevel::*.

Bustage for usage of the non-fully qualified LogLevel were fixed by adding
|using mozilla::LogLevel;| where appropriate.
2015-06-03 15:25:57 -07:00
Eric Rahm
60ccf43cb3 Bug 1165515 - Part 7: Convert PR_LOG_DEBUG + 1 to PR_LOG_VERBOSE. rs=froydnj
Used the command: |sed -E -i -e 's/PR_LOG_DEBUG\s*\+\s*1/PR_LOG_VERBOSE/g'|
2015-06-03 15:22:32 -07:00
Carsten "Tomcat" Book
5471309381 Backed out 14 changesets (bug 1165515) for linux x64 e10s m2 test failures
Backed out changeset d68dcf2ef372 (bug 1165515)
Backed out changeset 7c3b45a47811 (bug 1165515)
Backed out changeset b668b617bef2 (bug 1165515)
Backed out changeset d0916e1283a2 (bug 1165515)
Backed out changeset ac4dc7489942 (bug 1165515)
Backed out changeset e9632ce8bc65 (bug 1165515)
Backed out changeset c16d215cc7e4 (bug 1165515)
Backed out changeset e4d474f3c51a (bug 1165515)
Backed out changeset d87680bf9f7c (bug 1165515)
Backed out changeset b3c0a45ba99e (bug 1165515)
Backed out changeset 9370fa197674 (bug 1165515)
Backed out changeset 50970d668ca1 (bug 1165515)
Backed out changeset ffa4eb6d24b9 (bug 1165515)
Backed out changeset 5fcf1203cc1d (bug 1165515)

--HG--
extra : rebase_source : 6fb850d063cbabe738f97f0380302153e3eae97a
2015-06-02 13:05:56 +02:00
Eric Rahm
a9afd68cef Bug 1165515 - Part 13-2: Replace usage of PRLogModuleLevel and PR_LOG_*. rs=froydnj
This is straightforward mapping of PR_LOG levels to their LogLevel
counterparts:
  PR_LOG_ERROR   -> LogLevel::Error
  PR_LOG_WARNING -> LogLevel::Warning
  PR_LOG_WARN    -> LogLevel::Warning
  PR_LOG_INFO    -> LogLevel::Info
  PR_LOG_DEBUG   -> LogLevel::Debug
  PR_LOG_NOTICE  -> LogLevel::Debug
  PR_LOG_VERBOSE -> LogLevel::Verbose

Instances of PRLogModuleLevel were mapped to a fully qualified
mozilla::LogLevel, instances of PR_LOG levels in #defines were mapped to a
fully qualified mozilla::LogLevel::* level, and all other instances were
mapped to us a shorter format of LogLevel::*.

Bustage for usage of the non-fully qualified LogLevel were fixed by adding
|using mozilla::LogLevel;| where appropriate.
2015-06-01 22:17:33 -07:00
Eric Rahm
7ac2b84d0c Bug 1165515 - Part 7: Convert PR_LOG_DEBUG + 1 to PR_LOG_VERBOSE. rs=froydnj
Used the command: |sed -E -i -e 's/PR_LOG_DEBUG\s*\+\s*1/PR_LOG_VERBOSE/g'|
2015-06-01 22:17:24 -07:00
Wes Kocher
4e9f80ed2e Backed out 14 changesets (bug 1165515) for b2g mochitest-6 permafail CLOSED TREE
Backed out changeset 9b97e2aa2ed9 (bug 1165515)
Backed out changeset 150606c022a2 (bug 1165515)
Backed out changeset 4e875a488349 (bug 1165515)
Backed out changeset 467e7feeb546 (bug 1165515)
Backed out changeset d6b6cc373197 (bug 1165515)
Backed out changeset 0615265b593c (bug 1165515)
Backed out changeset fafd1dce9f08 (bug 1165515)
Backed out changeset d1df869245f9 (bug 1165515)
Backed out changeset 6876a7c63611 (bug 1165515)
Backed out changeset b7841c94a9a3 (bug 1165515)
Backed out changeset e5e3617f7c73 (bug 1165515)
Backed out changeset 39be3db95978 (bug 1165515)
Backed out changeset 0ec74176f8de (bug 1165515)
Backed out changeset 5b928dd10d71 (bug 1165515)
2015-06-01 17:57:58 -07:00
Eric Rahm
f82c0e7caf Bug 1165515 - Part 13-2: Replace usage of PRLogModuleLevel and PR_LOG_*. rs=froydnj
This is straightforward mapping of PR_LOG levels to their LogLevel
counterparts:
  PR_LOG_ERROR   -> LogLevel::Error
  PR_LOG_WARNING -> LogLevel::Warning
  PR_LOG_WARN    -> LogLevel::Warning
  PR_LOG_INFO    -> LogLevel::Info
  PR_LOG_DEBUG   -> LogLevel::Debug
  PR_LOG_NOTICE  -> LogLevel::Debug
  PR_LOG_VERBOSE -> LogLevel::Verbose

Instances of PRLogModuleLevel were mapped to a fully qualified
mozilla::LogLevel, instances of PR_LOG levels in #defines were mapped to a
fully qualified mozilla::LogLevel::* level, and all other instances were
mapped to us a shorter format of LogLevel::*.

Bustage for usage of the non-fully qualified LogLevel were fixed by adding
|using mozilla::LogLevel;| where appropriate.
2015-06-01 14:31:01 -07:00
Eric Rahm
82553a3fab Bug 1165515 - Part 7: Convert PR_LOG_DEBUG + 1 to PR_LOG_VERBOSE. rs=froydnj
Used the command: |sed -E -i -e 's/PR_LOG_DEBUG\s*\+\s*1/PR_LOG_VERBOSE/g'|
2015-06-01 14:31:00 -07:00
Bobby Holley
15e573e813 Bug 1168008 - Get rid of RefableThen and make Then return an nsRefPtr<Consumer>. r=jww
This incurs an extra addref here and there, but I think it makes the API simpler
to use and understand.
2015-05-28 16:03:06 -07:00
Birunthan Mohanathas
470bd9148f Bug 968520 - Add mozilla::fallible to FallibleTArray::AppendElements calls. r=froydnj 2015-05-28 11:07:43 -07:00
Eric Rahm
3925a960aa Bug 1165515 - Part 1: Convert PR_LOG to MOZ_LOG. r=froydnj 2015-05-21 13:22:04 -07:00
Eric Rahm
4879ae86f4 Bug 1165518 - Part 2: Replace prlog.h with Logging.h. rs=froydnj 2015-05-19 11:15:34 -07:00
Jean-Yves Avenard
54a681396b Bug 1163445: Part5. Replace dom::TimeRanges with TimeIntervals object. r=mattwoodrow 2015-05-18 16:15:47 +10:00
Jean-Yves Avenard
710c088af5 Bug 1165145: Part1. Don't add a negative time range to empty buffered ranges. r=karlt 2015-05-18 16:13:20 +10:00