<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.webkit.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>269203</bug_id>
          
          <creation_ts>2024-02-12 09:42:24 -0800</creation_ts>
          <short_desc>[GStreamer] Buffer end equals video duration for progressive video</short_desc>
          <delta_ts>2024-02-14 11:40:16 -0800</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>Media</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>Unspecified</rep_platform>
          <op_sys>Unspecified</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Enrique Ocaña">eocanha</reporter>
          <assigned_to name="Enrique Ocaña">eocanha</assigned_to>
          <cc>webkit-bug-importer</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>2012753</commentid>
    <comment_count>0</comment_count>
    <who name="Enrique Ocaña">eocanha</who>
    <bug_when>2024-02-12 09:42:24 -0800</bug_when>
    <thetext>On some long regular videos, the current buffer management mechanism reports 100% of the video as loaded when that&apos;s not actually happening. This causes document.getElementsByTagName(&apos;video&apos;)[0].buffered.end(0) to be equal to document.getElementsByTagName(&apos;video&apos;)[0].duration when that should clearly not the case.

The current default way of computing m_maxTimeLoaded isn&apos;t working properly because oftern, when the buffering messages are received by MediaPlayerPrivateGStreamer, the duration is still unknown and the code in charge of computing the fill status bails out.

The WebKitWebSrc network downloading statistics provide a much more accurate source of information for the buffered data, and should be used in more cases when available. The download statistics tend to arrive later than the buffer fill messages and at that moment duration is already available, leading to a proper computation of m_maxTimeLoaded.

See: https://github.com/WebPlatformForEmbedded/WPEWebKit/pull/1238</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2012758</commentid>
    <comment_count>1</comment_count>
    <who name="Enrique Ocaña">eocanha</who>
    <bug_when>2024-02-12 09:56:49 -0800</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/24257</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2013584</commentid>
    <comment_count>2</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2024-02-14 11:39:56 -0800</bug_when>
    <thetext>Committed 274643@main (3e214abe9459): &lt;https://commits.webkit.org/274643@main&gt;

Reviewed commits have been landed. Closing PR #24257 and removing active labels.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2013585</commentid>
    <comment_count>3</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2024-02-14 11:40:16 -0800</bug_when>
    <thetext>&lt;rdar://problem/122961086&gt;</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>