Files
ladybird/Libraries/LibWeb/MediaSourceExtensions/SourceBuffer.idl
Zaggy1024 459578c280 LibWeb: Implement the buffered attribute on SourceBuffer
This is used to detect what data is still needed to maintain or resume
playback based on the current playback position. This is the last piece
that was preventing YouTube MSE from working.
2026-04-01 02:54:22 -05:00

37 lines
1.2 KiB
Plaintext

#import <DOM/EventHandler.idl>
#import <HTML/AudioTrackList.idl>
#import <HTML/TextTrackList.idl>
#import <HTML/VideoTrackList.idl>
#import <HTML/TimeRanges.idl>
// https://w3c.github.io/media-source/#dom-sourcebuffer
enum AppendMode {
"segments",
"sequence",
};
// https://w3c.github.io/media-source/#dom-sourcebuffer
[Exposed=(Window,DedicatedWorker)]
interface SourceBuffer : EventTarget {
attribute AppendMode mode;
readonly attribute boolean updating;
readonly attribute TimeRanges buffered;
[FIXME] attribute double timestampOffset;
[FIXME] readonly attribute AudioTrackList audioTracks;
[FIXME] readonly attribute VideoTrackList videoTracks;
[FIXME] readonly attribute TextTrackList textTracks;
[FIXME] attribute double appendWindowStart;
[FIXME] attribute unrestricted double appendWindowEnd;
attribute EventHandler onupdatestart;
attribute EventHandler onupdate;
attribute EventHandler onupdateend;
attribute EventHandler onerror;
attribute EventHandler onabort;
undefined appendBuffer(BufferSource data);
[FIXME] undefined abort();
undefined changeType(DOMString type);
[FIXME] undefined remove(double start, unrestricted double end);
};