Skip to content

Fixing HLS playback. - #16

Closed
valbok wants to merge 1 commit into
WebPlatformForEmbedded:masterfrom
valbok:master
Closed

Fixing HLS playback.#16
valbok wants to merge 1 commit into
WebPlatformForEmbedded:masterfrom
valbok:master

Conversation

@valbok

Copy link
Copy Markdown

Fixed following:

  1. Fixed to set infinity duration to MediaSourceClientGStreamerMSE. See SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment. When no valid duration found in Initialization Segment Received it sets infinity as a duration and makes it as a live stream.
  2. In case if current duration is infinity in MediaPlayerPrivateGStreamerMSE::maxTimeSeekable() added a fix to fetch the highest end time value from buffered attribute to return proper filled TimeRange object in HTMLMediaElement.seekable().
  3. Fixed MediaSource::monitorSourceBuffers() to prevent assigning HAVE_ENOUGH_DATA to media player which led to send loadeddata event before initialization segment received, and no valid duration, seekable and other attributes returned.

@eocanha

Copy link
Copy Markdown
Member

The changes are fine. Just rebase them against the latest master and squash the three commits in one ("git rebase -i", change "push" for "s" in all the commits except the first one, write a meaningful message) and we're done.

@valbok

Copy link
Copy Markdown
Author

Hi Enrique, sorry about messup with commits, please say if there is an additional need to prepare the fix.

@valbok
valbokforce-pushed the master branch 2 times, most recently from 4fda158 to 2d52cc1CompareDecember 24, 2015 15:51
@valbok
valbokforce-pushed the master branch 3 times, most recently from ddb3e01 to 20b7e2aCompareJanuary 11, 2016 12:04
@valbok

Copy link
Copy Markdown
Author

Hi Enrique, please merge last changes, that was somehow missing from previous merge. Thanks

@philn

Copy link
Copy Markdown

What do you mean by HLS? Apple's HLS is usually handled with the standard player in WebKit (not MSE).

@valbok

Copy link
Copy Markdown
Author

philn, http live streaming.
We were experiencing problems to play http://chenz.org/flowplayer-hls-live-example.html and MSE was used there.

Last commit also contains serious fix in MediaSource::monitorSourceBuffers() to prevent assigning HAVE_ENOUGH_DATA to media player.
And an ability to assign positive infinite duration to define it as "live stream".

@philn

Copy link
Copy Markdown

Ah ok, so that player implements HLS with MSE, for the unlucky browsers not supporting it natively :)

@eocanha

Copy link
Copy Markdown
Member

Sorry, I can't merge the pull request because it causes YouTube 2016 tests 23 and 42 to fail.

Fixed following:
1. Fixed to set infinity duration to MediaSourceClientGStreamerMSE. See SourceBuffer::sourceBufferPrivateDidReceiveInitializationSegment. When no valid duration found in Initialization Segment Received it sets infinity as a duration and makes it as a live stream.
2. In case if current duration is infinity in MediaPlayerPrivateGStreamerMSE::maxTimeSeekable() added a fix to fetch the highest end time value from buffered attribute to return proper filled TimeRange object in HTMLMediaElement.seekable().
3. Fixed MediaSource::monitorSourceBuffers() to prevent assigning HAVE_ENOUGH_DATA to media player which led to send loadeddata event before initialization segment received, and no valid duration, seekable and other attributes returned.
@valbok

Copy link
Copy Markdown
Author

Hi Enrique, could you please check my latest fixes, that should fix 23 youtube test from http://yt-dash-mse-test.commondatastorage.googleapis.com/unit-tests/2016.html. Also potentially may fix 42 - MediaSourceDuration.

FYI: 23 test failed due to following change:
031465c#diff-1a0340714c802e905fa36d804906e36eR659

Because I allowed to pass inf value to MediaSourceClient and MediaPlayerPrivateGStreamerMSE.
Right now after this fix durationMediaTime() is responsible to return always correct value: means 0 is correct value, inf is not. Instead of inf buffered time will be returned.

Since previously player never had infinite duration, looks durationMediaTime() is not supposed to and should not return inf value as well.

@valbok

Copy link
Copy Markdown
Author

@albertd, could you please tip how to build and test MSE on the Pi? link? Thanks

@valbok

Copy link
Copy Markdown
Author

Thanks, but I meant build and run WebKitForWayland on the Pi.

@philn
philnforce-pushed the master branch 2 times, most recently from b4a4f67 to 3f4ede2CompareJune 17, 2016 13:48
@sarkanyi

Copy link
Copy Markdown

I think I might have a more elegant and non-breaking solution for your issue, please see here:
sarkanyi@389a2a9

@valbokvalbok closed this Nov 15, 2016
zdobersek pushed a commit that referenced this pull request Mar 7, 2017
…s and zero reg
https://bugs.webkit.org/show_bug.cgi?id=168527
Reviewed by Filip Pizlo.
Added support for data processing 1 source instructions like rbit, rev, clz and cls.
Added support for the FP conditional select instruction, fcsel. Consolidated the
two classes for handling dmb instructions into one class. Fixed the instruction
selection mask in the integer conditional select class, A64DOpcodeConditionalSelect.
Fixed the processing of extract instruction (extr) including the rotate right (ror)
pseudo instruction. Changed the printing of x31 and w31 to xzr and wzr as operands
according to the spec. Added support for common pseudo instructions. This includes:
- mvn x1, X2 in place of orn x1, xzr, x2
- lsl x3, x4, #count in place of ubfiz x3, x4, #count, #count
- smull x5, w6, w7 in place of smaddl x5, w6, w7, XZR
- More understandable mov x8, #-304 in place of movn x8, #0x12f
- Eliminated xzr from register index loads and stores, outputing
ldr x10, [x11] instead of ldr x10, [x11, xzr]
Changed the move wide instructions to use hex literals for movz and movk.
This makes it much easier to decifer sequences of wide moves for large literals.
Before After
movz x17, #26136 movz x17, #0x6618
movk x17, #672, lsl #16 movk x17, #0x2a0, lsl #16
movk x17, #1, lsl #32 movk x17, #0x1, lsl #32
Verified that all instructions currently generated by the JSC stress tests are
disassembled.
* disassembler/ARM64/A64DOpcode.cpp:
(JSC::ARM64Disassembler::A64DOpcodeBitfield::format):
(JSC::ARM64Disassembler::A64DOpcodeDataProcessing1Source::format):
(JSC::ARM64Disassembler::A64DOpcodeDataProcessing2Source::format):
(JSC::ARM64Disassembler::A64DOpcodeDataProcessing3Source::format):
(JSC::ARM64Disassembler::A64DOpcodeExtract::format):
(JSC::ARM64Disassembler::A64DOpcodeFloatingPointConditionalSelect::format):
(JSC::ARM64Disassembler::A64DOpcodeFloatingPointIntegerConversions::format):
(JSC::ARM64Disassembler::A64DOpcodeDmb::format):
(JSC::ARM64Disassembler::A64DOpcodeLoadStoreImmediate::format):
(JSC::ARM64Disassembler::A64DOpcodeLoadStoreRegisterOffset::format):
(JSC::ARM64Disassembler::A64DOpcodeLoadStoreRegisterPair::format):
(JSC::ARM64Disassembler::A64DOpcodeLoadStoreUnsignedImmediate::format):
(JSC::ARM64Disassembler::A64DOpcodeLogicalShiftedRegister::format):
(JSC::ARM64Disassembler::A64DOpcodeMoveWide::format):
(JSC::ARM64Disassembler::A64DOpcodeDmbIsh::format): Deleted.
(JSC::ARM64Disassembler::A64DOpcodeDmbIshSt::format): Deleted.
* disassembler/ARM64/A64DOpcode.h:
(JSC::ARM64Disassembler::A64DOpcode::appendSignedImmediate64):
(JSC::ARM64Disassembler::A64DOpcode::appendUnsignedHexImmediate):
(JSC::ARM64Disassembler::A64DOpcodeDataProcessing1Source::opName):
(JSC::ARM64Disassembler::A64DOpcodeDataProcessing1Source::sBit):
(JSC::ARM64Disassembler::A64DOpcodeDataProcessing1Source::opCode):
(JSC::ARM64Disassembler::A64DOpcodeDataProcessing1Source::opCode2):
(JSC::ARM64Disassembler::A64DOpcodeDataProcessing1Source::opNameIndex):
(JSC::ARM64Disassembler::A64DOpcodeDataProcessing3Source::opName):
(JSC::ARM64Disassembler::A64DOpcodeFloatingPointConditionalSelect::opName):
(JSC::ARM64Disassembler::A64DOpcodeFloatingPointConditionalSelect::condition):
(JSC::ARM64Disassembler::A64DOpcodeDmb::option):
(JSC::ARM64Disassembler::A64DOpcodeDmb::crM):
(JSC::ARM64Disassembler::A64DOpcodeLogicalShiftedRegister::isMov):
(JSC::ARM64Disassembler::A64DOpcodeDmbIsh::opName): Deleted.
(JSC::ARM64Disassembler::A64DOpcodeDmbIshSt::opName): Deleted.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@212592 268f45cc-cd09-0410-ab3c-d52691b4dbfc
@aazamansariaazamansari mentioned this pull request Jun 5, 2017
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@valbok@eocanha@philn@sarkanyi