<?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>261266</bug_id>
          
          <creation_ts>2023-09-07 02:32:56 -0700</creation_ts>
          <short_desc>WebRTC maintain-framerate degradationPreference does not apply to resolution adaptation</short_desc>
          <delta_ts>2024-02-09 06:32:36 -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>WebRTC</component>
          <version>WebKit Nightly Build</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          <see_also>https://bugs.webkit.org/show_bug.cgi?id=267577</see_also>
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords>BrowserCompat, InRadar</keywords>
          <priority>P2</priority>
          <bug_severity>Normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>coin_st</reporter>
          <assigned_to name="youenn fablet">youennf</assigned_to>
          <cc>coin_st</cc>
    
    <cc>kagh</cc>
    
    <cc>karlcow</cc>
    
    <cc>maojie0924</cc>
    
    <cc>webkit-bug-importer</cc>
    
    <cc>youennf</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1976085</commentid>
    <comment_count>0</comment_count>
    <who name="">coin_st</who>
    <bug_when>2023-09-07 02:32:56 -0700</bug_when>
    <thetext>By configuring video sender&apos;s degradationPreference as maintain-framerate according to standard (https://www.w3.org/TR/mst-content-hint/#degradation-preference-when-encoding), resolution adaptation is expected to be adaptive when certain limitation reasons are satisfied such as lack of compute resources or bandwidth. But safari does not work with this setting under any circumstance even at the beginning, sending resolution usually starts with lower dimensions then ramps up to the target resolution, chromium and firefox both work and we can observe this behavior under maintain-framerate.

We set degradationPreference by following code snippet:

  s = pc.getSenders()[1];
  p = s.getParameters();
  p.degradationPreference = &quot;maintain-framerate&quot;;
  s.setParameters(p);

Chromium and firefox will have distinct resolution adaptation at beginning and you may check getStats() outbound qualityLimitationReason which should be &quot;bandwidth&quot; and slow resolution ramp up can be observed, but nothing would happen on safari, plus seems qualityLimitationReason is not supported by safari.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1977466</commentid>
    <comment_count>1</comment_count>
    <who name="Radar WebKit Bug Importer">webkit-bug-importer</who>
    <bug_when>2023-09-14 02:33:13 -0700</bug_when>
    <thetext>&lt;rdar://problem/115481961&gt;</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1979786</commentid>
    <comment_count>2</comment_count>
    <who name="youenn fablet">youennf</who>
    <bug_when>2023-09-25 06:57:15 -0700</bug_when>
    <thetext>Pull request: https://github.com/WebKit/WebKit/pull/18155</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1980114</commentid>
    <comment_count>3</comment_count>
    <who name="EWS">ews-feeder</who>
    <bug_when>2023-09-26 02:38:28 -0700</bug_when>
    <thetext>Committed 268443@main (8bfbdfcad876): &lt;https://commits.webkit.org/268443@main&gt;

Reviewed commits have been landed. Closing PR #18155 and removing active labels.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2000312</commentid>
    <comment_count>4</comment_count>
    <who name="">coin_st</who>
    <bug_when>2023-12-17 19:33:23 -0800</bug_when>
    <thetext>(In reply to youenn fablet from comment #2)
&gt; Pull request: https://github.com/WebKit/WebKit/pull/18155

Hi Youenn, do you know what target release that will have this fix?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2005239</commentid>
    <comment_count>5</comment_count>
    <who name="youenn fablet">youennf</who>
    <bug_when>2024-01-16 04:59:15 -0800</bug_when>
    <thetext>Follow-up fix needed at https://bugs.webkit.org/show_bug.cgi?id=267577.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2012174</commentid>
    <comment_count>6</comment_count>
    <who name="Kaustav">kagh</who>
    <bug_when>2024-02-09 06:32:36 -0800</bug_when>
    <thetext>@youenn we have tested from our end and it works now. Thanks</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>