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

39 Коммитов

Автор SHA1 Сообщение Дата
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
Nathan Froyd 583afa0965 Bug 1207245 - part 3 - switch all uses of mozilla::RefPtr<T> to nsRefPtr<T>; r=ehsan
This commit was generated using the following script, executed at the
top level of a typical source code checkout.

 # Don't modify select files in mfbt/ because it's not worth trying to
 # tease out the dependencies currently.
 #
 # Don't modify anything in media/gmp-clearkey/0.1/ because those files
 # use their own RefPtr, defined in their own RefCounted.h.
find . -name '*.cpp' -o -name '*.h' -o -name '*.mm' -o -name '*.idl'| \
    grep -v 'mfbt/RefPtr.h' | \
    grep -v 'mfbt/nsRefPtr.h' | \
    grep -v 'mfbt/RefCounted.h' | \
    grep -v 'media/gmp-clearkey/0.1/' | \
    xargs perl -p -i -e '
 s/mozilla::RefPtr/nsRefPtr/g; # handle declarations in headers
 s/\bRefPtr</nsRefPtr</g; # handle local variables in functions
 s#mozilla/RefPtr.h#mozilla/nsRefPtr.h#; # handle #includes
 s#mfbt/RefPtr.h#mfbt/nsRefPtr.h#;       # handle strange #includes
'

 # |using mozilla::RefPtr;| is OK; |using nsRefPtr;| is invalid syntax.
find . -name '*.cpp' -o -name '*.mm' | xargs sed -i -e '/using nsRefPtr/d'

 # RefPtr.h used |byRef| for dealing with COM-style outparams.
 # nsRefPtr.h uses |getter_AddRefs|.
 # Fixup that mismatch.
find . -name '*.cpp' -o -name '*.h'| \
    xargs perl -p -i -e 's/byRef/getter_AddRefs/g'
2015-10-18 00:40:10 -04:00
Eric Rahm 88d7e6c28e Bug 1190592 - Part 1: Add mediasource memory reporter. r=jya
This adds asyncrounous reporting of MSE resources.
2015-08-20 18:10:33 -04:00
Jean-Yves Avenard 5558525f6c Bug 1211328: [MSE] Fix timestampOffset attribute calculation in sequence mode. r=gerald 2015-10-05 15:45:56 +11:00
Jean-Yves Avenard 7ae057dc90 Bug 1207946: [MSE] P3. Reset cached demuxing index when new data overwrite the end. r=gerald
This will force an iterative search upon the next demux request.
2015-09-29 12:31:33 +10:00
Jean-Yves Avenard 488a0d19d9 Bug 1207946: [MSE] P2. Fix seek when target isn't found exactly in a buffered range. r=gerald 2015-09-29 12:31:32 +10:00
Jean-Yves Avenard 21d2f1de2a Bug 1188238: [MSE] P2. Don't assert when unable to find position in frames array. r=gerald
Instead return an error which will terminate the video element.
2015-09-12 20:53:23 +10:00
Jean-Yves Avenard 50c382495e Bug 1199879: [MSE] Use latest demux end time to detect discontinuities. r=gerald
The ContainerParser doesn't always return an accurate end time.
2015-08-30 20:48:07 +10:00
Jean-Yves Avenard 94c7c1cfc2 Bug 1199573: [MSE] Properly handle partial media header received prior a discontinuity. r=gerald 2015-08-29 12:01:23 +10:00
Jean-Yves Avenard e4dff83b7a Bug 1195073: [MSE] P5. Detect out of order appends and recreate demuxer. r=gerald
The webm demuxer will only handle data where frames's a monotonically increasing.
2015-08-24 23:13:49 +10:00
Jean-Yves Avenard 38f40fd819 Bug 1190019: [MSE] P2. Remove cycle between TrackBuffersManager and MediaSourceDemuxer. r=gerald 2015-08-04 16:19:15 +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
Jean-Yves Avenard 179ab5ffb6 Bug 1189602: [MSE] Always notify demuxer when data is added (or removed) to the resource. r=gerald 2015-07-31 16:10:42 +10:00
Jean-Yves Avenard bdf2f8bda7 Bug 1183196: [MSE] P1. Do not overwrite stored init data until known as valid. r=gerald 2015-07-30 15:20:49 +10:00
Ralph Giles f104891fe4 Bug 1186257 - Avoid 'using' namespace imports in headers. r=jya
This is poor style as it can have side-effects in the caller's
code. Instead, use full namespace prefixes.
2015-07-22 16:59:27 -07: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
Bobby Holley 04eaf4c167 Bug 1184634 - Move various includes into the mozilla namespace. r=gerald
I did my a quick best-effort pass to fix up the most egregious ordering
problems. I left some big pre-existing messes alone.
2015-07-16 22:23:18 -07:00
Bobby Holley 997543e6ba Bug 1184634 - Rename MediaTaskQueue to TaskQueue. r=gerald 2015-07-16 22:23:06 -07:00
Bobby Holley 407d2c5f90 Bug 1184634 - Rename MediaPromise to MozPromise. r=gerald 2015-07-16 22:21:56 -07:00
Jean-Yves Avenard 5c4906180c Bug 1184002: Add about:media plugin support with new MSE. r=cpearce 2015-07-16 14:31:56 +10:00
Jean-Yves Avenard fc29e89d03 Bug 1183573: P1. Properly shutdown demuxers. r=gerald 2015-07-15 16:21:58 +10:00
Birunthan Mohanathas a8939590de Bug 1182996 - Fix and add missing namespace comments. rs=ehsan
The bulk of this commit was generated by running:

  run-clang-tidy.py \
    -checks='-*,llvm-namespace-comment' \
    -header-filter=^/.../mozilla-central/.* \
    -fix
2015-07-13 08:25:42 -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
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 03db89712a Bug 1174981: P1. Ensure frames are returned in pts order. r=gerald
We move management of the data to the TrackBuffersManager as it contains
precise information on how the samples are being moved.
2015-06-19 16:45:21 +10:00
Jean-Yves Avenard 4c70b3dc19 Bug 1174588: P2. Properly handle removal of data within the current coded frame group. r=gerald
W3C bug pending.
2015-06-19 16:45:20 +10:00
Jean-Yves Avenard a506151ccb Bug 1174583: P2. Fix frame insertion. r=gerald
Strict tests were added to enforce that all frame groups start with a keyframe
Debug code was also added to ensure that dts increase monotonically within coded frame groups.
As always, speed and memory optimisations weren't considered and will be handled in bug 1171760
2015-06-19 16:45:18 +10:00
Jean-Yves Avenard 00c18993d6 Bug 1174577: P2. Properly handle multiple init segments. r=cpearce 2015-06-19 16:45:16 +10:00
Jean-Yves Avenard 91e1665b64 Bug 1171314: P2. Fill SharedTrackInfo data in MSE samples. r=cpearce 2015-06-19 16:45:14 +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 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 9968c8652f Bug 1171330: P19. Use state mirroring for reading mediasource duration. r=bholley
--HG--
extra : rebase_source : d9c944b21cbe42c5c125bd8bfdc9e631c9a7f125
2015-06-11 16:34:03 +10:00
Jean-Yves Avenard c2dc82d760 Bug 1171330: P17. Add diagnostic to ensure no pending append is going. r=cajbir
--HG--
extra : rebase_source : 00d90447c3f782255ca897984e99d47fba9af39f
2015-06-11 16:33:58 +10:00
Jean-Yves Avenard 8fd891ebe9 Bug 1171330: P16. Use ProxyMediaCall and remove need for monitor. r=cajbir
--HG--
extra : rebase_source : 29e5295ed699824b3d23d65b16229ff3dde8dffb
2015-06-11 16:33:10 +10:00
Jean-Yves Avenard d53de3367c Bug 1171330: P15. Better andle partial media segments. r=cajbir
--HG--
extra : rebase_source : c90ce1b087ef8b55b110da0dc2caec167586fed2
2015-06-11 16:33:05 +10:00
Jean-Yves Avenard 0a0c636147 Bug 1171330: P13. Relax frame discontinuity detection. r=cajbir
--HG--
extra : rebase_source : 0782c4a7d03db36acaf413c8ea27819c845edb29
2015-06-11 16:27:08 +10:00
Jean-Yves Avenard 5d7588e70d Bug 1171330: P11. Add eviction support. r=cajbir.
We evict data in two steps. Up to playback time, or tail data.

--HG--
extra : rebase_source : 052273e92d3b3704f513a55aac3e5d75c0d900fa
2015-06-11 16: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