<pre style='margin:0'>
Mihai Moldovan (Ionic) pushed a commit to branch master
in repository macports-ports.

</pre>
<p><a href="https://github.com/macports/macports-ports/commit/7f9cb6933b08cc4d0de0afafb04f4698a1fed17b">https://github.com/macports/macports-ports/commit/7f9cb6933b08cc4d0de0afafb04f4698a1fed17b</a></p>
<pre style="white-space: pre; background: #F8F8F8">The following commit(s) were added to refs/heads/master by this push:
<span style='display:block; white-space:pre;color:#404040;'>     new 7f9cb69  multimedia/mpv: update to 0.22.0. Fixes: https://trac.macports.org/ticket/52878 (#52878), fixes: https://trac.macports.org/ticket/52845 (#52845)
</span>7f9cb69 is described below

<span style='display:block; white-space:pre;color:#808000;'>commit 7f9cb6933b08cc4d0de0afafb04f4698a1fed17b
</span>Author: Mihai Moldovan <ionic@ionic.de>
AuthorDate: Sun Dec 18 10:14:02 2016 +0100

<span style='display:block; white-space:pre;color:#404040;'>    multimedia/mpv: update to 0.22.0. Fixes: https://trac.macports.org/ticket/52878 (#52878), fixes: https://trac.macports.org/ticket/52845 (#52845)
</span><span style='display:block; white-space:pre;color:#404040;'>    
</span><span style='display:block; white-space:pre;color:#404040;'>    Changes:
</span><span style='display:block; white-space:pre;color:#404040;'>      - Refresh 10.6 patchset.
</span><span style='display:block; white-space:pre;color:#404040;'>      - Drop legacy Id line.
</span><span style='display:block; white-space:pre;color:#404040;'>      - Move files from ${prefix}/share/examples/mpv to
</span><span style='display:block; white-space:pre;color:#404040;'>        ${prefix}/share/doc/mpv/examples/.
</span><span style='display:block; white-space:pre;color:#404040;'>      - Disable previous;y missed and new features.
</span><span style='display:block; white-space:pre;color:#404040;'>      - Add new "zsh" variant for installing zsh completions.
</span><span style='display:block; white-space:pre;color:#404040;'>      - Reformat notes a bit to remove redundant whitespaces.
</span><span style='display:block; white-space:pre;color:#404040;'>      - Add comment regarding configure.args and why I cannot use it (yet?)
</span><span style='display:block; white-space:pre;color:#404040;'>      - Fix @@NETWORK@@ reinplaces.
</span>---
 multimedia/mpv/Portfile                            | 45 ++++++++++++-------
 ...udio_utils.c-add-missing-header-for-getpid.diff | 10 ++---
 multimedia/mpv/files/patch-misc-add-strnlen.diff   |  2 +-
 ..._macosx_compat.h-fix-YES-NO-macro-warnings.diff |  2 +-
 ...x_compat.m-add-subscripting-implementation.diff |  2 +-
 ...-video_out_cocoa_common.m-port-lightsensor.diff |  4 +-
 ...cocoa_common.m-wrap-convertRectFromBacking.diff | 25 +++++++++++
 ...t_opengl_common.c-hide-GL3-timer-functions.diff |  4 +-
 ...deo_out_opengl_common.c-hide-GL320-section.diff |  4 +-
 ...-video_out_opengl_common.h-guard-GL3-stuff.diff |  4 +-
 ...t_opengl_context_cocoa.c-hardcode-OpenGL-2.diff | 16 +++----
 ...out_opengl_utils.c-hide-pbo-texture-upload.diff |  6 +--
 ...eo_out_opengl_video.c-fix-compile-warnings.diff |  8 ++--
 ..._opengl_video.c-remove-timer-functionality.diff | 50 +++++++++++-----------
 ...engl.c-guard-GL3-and-backport-old-behavior.diff | 20 +++------
 ...ftools_checks_custom.py-disable-libarclite.diff |  3 +-
 16 files changed, 119 insertions(+), 86 deletions(-)

<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/Portfile b/multimedia/mpv/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index e875dad..6601f01 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,13 +1,12 @@
</span> # -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4
<span style='display:block; white-space:pre;background:#ffe0e0;'>-# $Id$
</span> 
 PortSystem              1.0
 PortGroup               github 1.0
 PortGroup               waf 1.0
 
 # Please revbump mpv whenever ffmpeg{,-devel} is updated!
<span style='display:block; white-space:pre;background:#ffe0e0;'>-github.setup            mpv-player mpv 0.20.0 v
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-revision                2
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+github.setup            mpv-player mpv 0.22.0 v
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+revision                0
</span> categories              multimedia
 license                 GPL-2+
 maintainers             ionic
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -31,8 +30,8 @@ distfiles-append        ${waf_distfile}:waf
</span> extract.only-delete     ${waf_distfile}
 
 checksums               ${mpv_distfile} \
<span style='display:block; white-space:pre;background:#ffe0e0;'>-                        rmd160  41466df9f6aa69eb31dcd1651b14def189b782da \
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-                        sha256  1a8a98cf4785206fa27387f752af0bdc1e303fe2e0a5d5be306123c6151ced08 \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        rmd160  1bcf046072e25a6363fd9e2cebb8b5751d1e0f0f \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        sha256  7b52b765516a33cbfc4bcaad7e5b727b92029519cc7ac3b83efe35f4d6e5a70c \
</span>                         ${waf_distfile} \
                         rmd160  bb1dcd10a0c336a5497bb1247a301c27f997078c \
                         sha256  01bf2beab2106d1558800c8709bc2c8e496d3da4a2ca343fe091f22fca60c98b
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -53,6 +52,11 @@ default_variants        +bundle +network +osd +rubberband +opengl +dvd +audiocd
</span> # Current waf doesn't support --nocache anymore. Set by PortGroup.
 configure.args-delete   --nocache
 
<span style='display:block; white-space:pre;background:#e0ffe0;'>+# I'd *really* love to see what's going on in waf, but even the continue-on-failure option
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# makes waf bail out on the first optional component that was not found (which will always
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+# happen, especially since tests for Win32 are bound to fail on other platforms...)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+#configure.args-append   -vvv -kk
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> # Default configuration options. Mostly macOS specific.
 # We cannot use --enable-cplayer here. Only --disable-cplayer
 # is recognized. Boo!
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -64,7 +68,10 @@ configure.args-append   --enable-manpage-build \
</span>                         --disable-videotoolbox-hwaccel \
                         --disable-videotoolbox-gl \
                         --disable-opensles \
<span style='display:block; white-space:pre;background:#ffe0e0;'>-                        --disable-egl-drm
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        --disable-egl-drm \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        --disable-audiounit \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        --disable-ios-gl \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        --disable-mali-fbdev
</span> 
 # mpv autodetects many support libs. To prevent undeclared
 # dependencies, explicitly disable everything optional first.
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -101,7 +108,8 @@ configure.args-append   --disable-pdf-build \
</span>                         --disable-tv \
                         --disable-lua \
                         --disable-apple-remote \
<span style='display:block; white-space:pre;background:#ffe0e0;'>-                        --disable-gl
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        --disable-gl \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        --disable-zsh-comp
</span> 
 # Fix picking up the correct talloc version.
 # -isystem has the added benefit of moving the include
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -174,14 +182,14 @@ platform darwin {
</span> 
     if {${os.major} > 11} {
         notes-append {
<span style='display:block; white-space:pre;background:#ffe0e0;'>-                        This config file already defines the necessary video output settings to make \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        This config file already defines the necessary video output settings to make\
</span>                         use of the hardware acceleration features provided by your operating system.
         }
     } else {
         notes-append {
                         Sadly, your system is incapable of utilizing mpv's hardware decoding features.
 
<span style='display:block; white-space:pre;background:#ffe0e0;'>-                        Please make sure to edit the file after copying and replace the "vo=" line with \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        Please make sure to edit the file after copying and replace the "vo=" line with\
</span>                         options suited for your system or mpv won't work as expected. \
                         Consult ``man mpv'' for further information.
         }
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -206,6 +214,7 @@ platform darwin {
</span>                             patch-video_out_cocoa_window.m-fullscreen-fixes.diff \
                             patch-video_out_cocoa_common.m-define-constants.diff \
                             patch-video_out_cocoa_common.m-port-lightsensor.diff \
<span style='display:block; white-space:pre;background:#e0ffe0;'>+                            patch-video_out_cocoa_common.m-wrap-convertRectFromBacking.diff \
</span>                             patch-video_out_opengl_context_cocoa.c-hardcode-OpenGL-2.diff \
                             patch-video_out_opengl_video.c-fix-compile-warnings.diff \
                             patch-osdep_macosx_compat.h-fix-YES-NO-macro-warnings.diff \
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -219,7 +228,7 @@ platform darwin {
</span>                             patch-video_out_opengl_utils.c-hide-pbo-texture-upload.diff
 
         notes-append {
<span style='display:block; white-space:pre;background:#ffe0e0;'>-                        On systems older than Lion (10.7), Cocoa output support is currently \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                        On systems older than Lion (10.7), Cocoa output support is currently\
</span>                         being patched by the MacPorts maintainer to make it work.
 
                         It is known to be broken.
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -234,9 +243,9 @@ platform darwin {
</span> 
     pre-configure {
         if {[variant_isset network]} {
<span style='display:block; white-space:pre;background:#ffe0e0;'>-            reinplace -W "${worksrcpath}/TOOLS" "s|@@NETWORK@@||" config-maintainer
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+            reinplace -W "${worksrcpath}/TOOLS" "s/@@NETWORK@@//" config-maintainer
</span>         } else {
<span style='display:block; white-space:pre;background:#ffe0e0;'>-            reinplace -W "${worksrcpath}/TOOLS" "|@@NETWORK@@|d" config-maintainer
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+            reinplace -W "${worksrcpath}/TOOLS" "/@@NETWORK@@/d" config-maintainer
</span>         }
     }
 }
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -303,15 +312,15 @@ post-destroot {
</span>         xinstall -m 0644 ${worksrcpath}/etc/${etcfile} \
             ${destroot}${prefix}/etc/${name}/${etcfile}
     }
<span style='display:block; white-space:pre;background:#ffe0e0;'>-    xinstall -d -m 0755 ${destroot}${prefix}/share/examples/${name}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+    xinstall -d -m 0755 ${destroot}${prefix}/share/doc/${name}/examples
</span>     copy {*}[glob ${worksrcpath}/TOOLS/lua ${worksrcpath}/TOOLS/*.pl \
                   ${worksrcpath}/TOOLS/*.sh ${worksrcpath}/TOOLS/*.py \
                   ${worksrcpath}/TOOLS/umpv ${worksrcpath}/TOOLS/lib] \
<span style='display:block; white-space:pre;background:#ffe0e0;'>-         ${destroot}${prefix}/share/examples/${name}
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         ${destroot}${prefix}/share/doc/${name}/examples
</span> 
     if {${os.platform} eq "darwin"} {
         xinstall -m 0644 ${worksrcpath}/TOOLS/config-maintainer \
<span style='display:block; white-space:pre;background:#ffe0e0;'>-                         ${destroot}${prefix}/share/examples/${name}/
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                         ${destroot}${prefix}/share/doc/${name}/examples
</span>     }
 }
 
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -466,3 +475,9 @@ variant printable_doc description {Generate printable documents (PDF help)} {
</span>     configure.args-replace  --disable-pdf-build \
                             --enable-pdf-build
 }
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+variant zsh description {Enable/install zsh completion support} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+    depends_lib-append      path:${prefix}/bin/zsh:zsh
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+    configure.args-replace  --disable-zsh-comp \
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+                            --enable-zsh-comp
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+}
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-audio_out_ao_coreaudio_utils.c-add-missing-header-for-getpid.diff b/multimedia/mpv/files/patch-audio_out_ao_coreaudio_utils.c-add-missing-header-for-getpid.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 438a1d8..105a762 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-audio_out_ao_coreaudio_utils.c-add-missing-header-for-getpid.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-audio_out_ao_coreaudio_utils.c-add-missing-header-for-getpid.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,10 +1,10 @@
</span> --- audio/out/ao_coreaudio_utils.c.orig
 +++ audio/out/ao_coreaudio_utils.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -23,6 +23,7 @@
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-  */
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- 
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -31,6 +31,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #if HAVE_COREAUDIO
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include "audio/out/ao_coreaudio_properties.h"
</span>  #include <CoreAudio/HostTime.h>
 +#include <unistd.h>
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ #endif
</span>  
<span style='display:block; white-space:pre;background:#ffe0e0;'>- #include "audio/out/ao_coreaudio_utils.h"
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #include "audio/out/ao_coreaudio_properties.h"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ CFStringRef cfstr_from_cstr(char *str)
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-misc-add-strnlen.diff b/multimedia/mpv/files/patch-misc-add-strnlen.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index f884911..fee76d0 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-misc-add-strnlen.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-misc-add-strnlen.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,6 +1,6 @@
</span> --- common/common.h.orig
 +++ common/common.h
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -25,6 +25,7 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -26,6 +26,7 @@
</span>  
  #include "osdep/compiler.h"
  #include "mpv_talloc.h"
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-osdep_macosx_compat.h-fix-YES-NO-macro-warnings.diff b/multimedia/mpv/files/patch-osdep_macosx_compat.h-fix-YES-NO-macro-warnings.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 0ac3f82..ca6a247 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-osdep_macosx_compat.h-fix-YES-NO-macro-warnings.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-osdep_macosx_compat.h-fix-YES-NO-macro-warnings.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,6 +1,6 @@
</span> --- osdep/macosx_compat.h.orig
 +++ osdep/macosx_compat.h
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -41,6 +41,15 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -66,6 +66,15 @@ static const NSEventModifierFlags NSEven
</span>  - (void)setObject: (id)object forKeyedSubscript:(id)key;
  @end
  
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-osdep_macosx_compat.m-add-subscripting-implementation.diff b/multimedia/mpv/files/patch-osdep_macosx_compat.m-add-subscripting-implementation.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index d646256..0a0f8aa 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-osdep_macosx_compat.m-add-subscripting-implementation.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-osdep_macosx_compat.m-add-subscripting-implementation.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -57,7 +57,7 @@
</span> +#endif
 --- wscript_build.py.orig
 +++ wscript_build.py
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -391,6 +391,7 @@ def build(ctx):
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -404,6 +404,7 @@ def build(ctx):
</span>          ( "osdep/ar/HIDRemote.m",                "apple-remote" ),
          ( "osdep/macosx_application.m",          "cocoa" ),
          ( "osdep/macosx_events.m",               "cocoa" ),
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_cocoa_common.m-port-lightsensor.diff b/multimedia/mpv/files/patch-video_out_cocoa_common.m-port-lightsensor.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index d33731d..07f25fd 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-video_out_cocoa_common.m-port-lightsensor.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_cocoa_common.m-port-lightsensor.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -10,7 +10,7 @@
</span>  
      struct mp_log *log;
  
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -232,8 +235,18 @@ static void cocoa_init_light_sensor(stru
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -237,8 +240,18 @@ static void cocoa_init_light_sensor(stru
</span>  
          // subscribe to notifications from the light sensor driver
          s->light_sensor_io_port = IONotificationPortCreate(kIOMasterPortDefault);
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -29,7 +29,7 @@
</span>  
          io_object_t n;
          IOServiceAddInterestNotification(
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -255,6 +268,13 @@ static void cocoa_init_light_sensor(stru
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -260,6 +273,13 @@ static void cocoa_init_light_sensor(stru
</span>  static void cocoa_uninit_light_sensor(struct vo_cocoa_state *s)
  {
      if (s->light_sensor_io_port) {
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_cocoa_common.m-wrap-convertRectFromBacking.diff b/multimedia/mpv/files/patch-video_out_cocoa_common.m-wrap-convertRectFromBacking.diff
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..4065bfa
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_cocoa_common.m-wrap-convertRectFromBacking.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,25 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- video/out/cocoa_common.m.orig
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ video/out/cocoa_common.m
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -135,9 +135,11 @@ static void queue_new_video_size(struct 
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+     if ([s->window conformsToProtocol: @protocol(MpvSizing)]) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         id<MpvSizing> win = (id<MpvSizing>) s->window;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         NSRect r = NSMakeRect(0, 0, w, h);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#if MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         if(!opts->hidpi_window_scale) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             r = [s->current_screen convertRectFromBacking:r];
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         [win queueNewVideoSize:NSMakeSize(r.size.width, r.size.height)];
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+     }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -522,8 +524,10 @@ static void create_ui(struct vo *vo, str
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+     } else {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         NSRect wr =
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             NSMakeRect(win->x0, win->y0, win->x1 - win->x0, win->y1 - win->y0);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#if MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         if(!opts->hidpi_window_scale)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             wr = [s->current_screen convertRectFromBacking:wr];
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         s->window = create_window(wr, s->current_screen, opts->border, adapter);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         parent = [s->window contentView];
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+     }
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_opengl_common.c-hide-GL3-timer-functions.diff b/multimedia/mpv/files/patch-video_out_opengl_common.c-hide-GL3-timer-functions.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index e09bde3..2e6d39b 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-video_out_opengl_common.c-hide-GL3-timer-functions.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_opengl_common.c-hide-GL3-timer-functions.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,6 +1,6 @@
</span> --- video/out/opengl/common.c.orig
 +++ video/out/opengl/common.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -275,7 +275,6 @@ static const struct gl_functions gl_func
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -276,7 +276,6 @@ static const struct gl_functions gl_func
</span>              {0}
          },
      },
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -8,7 +8,7 @@
</span>      {
          .ver_core = 330,
          .extension = "GL_ARB_timer_query",
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -309,6 +308,7 @@ static const struct gl_functions gl_func
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -310,6 +309,7 @@ static const struct gl_functions gl_func
</span>              {0}
          },
      },
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_opengl_common.c-hide-GL320-section.diff b/multimedia/mpv/files/patch-video_out_opengl_common.c-hide-GL320-section.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 70c04a3..8a1ec9e 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-video_out_opengl_common.c-hide-GL320-section.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_opengl_common.c-hide-GL320-section.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,6 +1,6 @@
</span> --- video/out/opengl/common.c.orig
 +++ video/out/opengl/common.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -264,6 +264,7 @@ static const struct gl_functions gl_func
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -265,6 +265,7 @@ static const struct gl_functions gl_func
</span>          .ver_exclude = 1,
          .ver_es_exclude = 320,
      },
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -8,7 +8,7 @@
</span>      {
          .ver_core = 320,
          .extension = "GL_ARB_sync",
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -274,6 +275,7 @@ static const struct gl_functions gl_func
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -275,6 +276,7 @@ static const struct gl_functions gl_func
</span>              {0}
          },
      },
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_opengl_common.h-guard-GL3-stuff.diff b/multimedia/mpv/files/patch-video_out_opengl_common.h-guard-GL3-stuff.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 1173d4b..35cbf9e 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-video_out_opengl_common.h-guard-GL3-stuff.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_opengl_common.h-guard-GL3-stuff.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,6 +1,6 @@
</span> --- video/out/opengl/common.h.orig
 +++ video/out/opengl/common.h
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -190,6 +190,7 @@ struct GL {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -194,6 +194,7 @@ struct GL {
</span>  
      void (GLAPIENTRY *InvalidateFramebuffer)(GLenum, GLsizei, const GLenum *);
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -8,7 +8,7 @@
</span>      GLsync (GLAPIENTRY *FenceSync)(GLenum, GLbitfield);
      GLenum (GLAPIENTRY *ClientWaitSync)(GLsync, GLbitfield, GLuint64);
      void (GLAPIENTRY *DeleteSync)(GLsync sync);
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -204,6 +205,7 @@ struct GL {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -208,6 +209,7 @@ struct GL {
</span>      void (GLAPIENTRY *GetQueryObjecti64v)(GLuint, GLenum, GLint64 *);
      void (GLAPIENTRY *GetQueryObjectuiv)(GLuint, GLenum, GLuint *);
      void (GLAPIENTRY *GetQueryObjectui64v)(GLuint, GLenum, GLuint64 *);
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_opengl_context_cocoa.c-hardcode-OpenGL-2.diff b/multimedia/mpv/files/patch-video_out_opengl_context_cocoa.c-hardcode-OpenGL-2.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 8963527..67777f6 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-video_out_opengl_context_cocoa.c-hardcode-OpenGL-2.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_opengl_context_cocoa.c-hardcode-OpenGL-2.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,6 +1,6 @@
</span> --- video/out/opengl/common.c.orig
 +++ video/out/opengl/common.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -473,6 +473,7 @@ void mpgl_load_functions2(GL *gl, void *
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -474,6 +474,7 @@ void mpgl_load_functions2(GL *gl, void *
</span>      if (shader)
          mp_verbose(log, "GL_SHADING_LANGUAGE_VERSION='%s'\n", shader);
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -8,7 +8,7 @@
</span>      if (gl->version >= 300) {
          gl->GetStringi = get_fn(fn_ctx, "glGetStringi");
          gl->GetIntegerv = get_fn(fn_ctx, "glGetIntegerv");
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -487,7 +488,9 @@ void mpgl_load_functions2(GL *gl, void *
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -488,7 +489,9 @@ void mpgl_load_functions2(GL *gl, void *
</span>              gl->extensions = talloc_asprintf_append(gl->extensions, " %s", ext);
          }
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -40,11 +40,11 @@
</span>  #include <OpenGL/gl3.h>
 +#endif
  #include <OpenGL/glext.h>
<span style='display:block; white-space:pre;background:#ffe0e0;'>- #elif HAVE_ANDROID_GL
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- #include <GLES3/gl3.h>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #elif HAVE_IOS_GL
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #include <OpenGLES/ES2/glext.h>
</span> --- video/out/opengl/video.c.orig
 +++ video/out/opengl/video.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -407,12 +407,22 @@ const struct m_sub_options gl_video_conf
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -382,12 +382,22 @@ const struct m_sub_options gl_video_conf
</span>                      {"rgb10",  GL_RGB10},
                      {"rgb10_a2", GL_RGB10_A2},
                      {"rgb16",  GL_RGB16},
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -67,7 +67,7 @@
</span>                      {"auto",   0})),
          OPT_CHOICE_OR_INT("dither-depth", dither_depth, 0, -1, 16,
                            ({"no", -1}, {"auto", 0})),
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -3009,7 +3019,11 @@ static void check_gl_features(struct gl_
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3111,7 +3121,11 @@ static void check_gl_features(struct gl_
</span>      bool have_texrg = gl->mpgl_caps & MPGL_CAP_TEX_RG;
      bool have_tex16 = !gl->es || (gl->mpgl_caps & MPGL_CAP_EXT16);
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -98,10 +98,10 @@
</span>          kCGLPFAOpenGLProfile,
          (CGLPixelFormatAttribute) version,
 +#endif
<span style='display:block; white-space:pre;background:#ffe0e0;'>-         kCGLPFADoubleBuffer,
</span>          kCGLPFAAccelerated,
          #if MAC_OS_X_VERSION_MIN_REQUIRED >= MAC_OS_X_VERSION_10_8
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -91,16 +96,22 @@ static bool create_gl_context(struct MPG
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         // leave this as the last entry of the array to not break the fallback
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -90,16 +95,22 @@ static bool create_gl_context(struct MPG
</span>      struct cgl_context *p = ctx->priv;
      CGLError err;
  
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_opengl_utils.c-hide-pbo-texture-upload.diff b/multimedia/mpv/files/patch-video_out_opengl_utils.c-hide-pbo-texture-upload.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index e454179..8af8d9e 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-video_out_opengl_utils.c-hide-pbo-texture-upload.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_opengl_utils.c-hide-pbo-texture-upload.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,14 +1,14 @@
</span> --- video/out/opengl/utils.c.orig
 +++ video/out/opengl/utils.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -1168,6 +1168,7 @@ void gl_pbo_upload_tex(struct gl_pbo_upl
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-     pbo->index = (pbo->index + 1) % 2;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1226,6 +1226,7 @@ void gl_pbo_upload_tex(struct gl_pbo_upl
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+     pbo->index = (pbo->index + 1) % NUM_PBO_BUFFERS;
</span>  
      gl->BindBuffer(GL_PIXEL_UNPACK_BUFFER, pbo->buffers[pbo->index]);
 +#if !defined(__APPLE__) || MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
      void *data = gl->MapBufferRange(GL_PIXEL_UNPACK_BUFFER, 0, needed_size,
                                      GL_MAP_WRITE_BIT | GL_MAP_INVALIDATE_BUFFER_BIT);
      if (!data)
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -1185,6 +1186,7 @@ void gl_pbo_upload_tex(struct gl_pbo_upl
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1243,6 +1244,7 @@ void gl_pbo_upload_tex(struct gl_pbo_upl
</span>      gl->BindBuffer(GL_PIXEL_UNPACK_BUFFER, 0);
  
      return;
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_opengl_video.c-fix-compile-warnings.diff b/multimedia/mpv/files/patch-video_out_opengl_video.c-fix-compile-warnings.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 1822785..8797472 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-video_out_opengl_video.c-fix-compile-warnings.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_opengl_video.c-fix-compile-warnings.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,6 +1,6 @@
</span> --- video/out/opengl/video.c.orig
 +++ video/out/opengl/video.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -897,7 +897,7 @@ static void uninit_video(struct gl_video
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -998,7 +998,7 @@ static void uninit_video(struct gl_video
</span>          gl->DeleteTextures(1, &plane->gl_texture);
          gl_pbo_upload_uninit(&plane->pbo);
      }
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -9,7 +9,7 @@
</span>  
      // Invalidate image_params to ensure that gl_video_config() will call
      // init_video() on uninitialized gl_video.
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -949,7 +949,7 @@ static void pass_prepare_src_tex(struct 
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1045,7 +1045,7 @@ static void pass_prepare_src_tex(struct 
</span>  static void render_pass_quad(struct gl_video *p, int vp_w, int vp_h,
                               const struct mp_rect *dst)
  {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -18,7 +18,7 @@
</span>  
      struct gl_transform t;
      gl_transform_ortho(&t, 0, vp_w, 0, vp_h);
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2844,7 +2844,7 @@ struct voctrl_performance_data gl_video_
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2945,7 +2945,7 @@ struct voctrl_performance_data gl_video_
</span>  // This assumes nv12, with textures set to GL_NEAREST filtering.
  static void reinterleave_vdpau(struct gl_video *p, struct gl_hwdec_frame *frame)
  {
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -27,7 +27,7 @@
</span>      for (int n = 0; n < 2; n++) {
          struct fbotex *fbo = &p->vdpau_deinterleave_fbo[n];
          // This is an array of the 2 to-merge planes.
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2902,7 +2902,7 @@ static bool gl_video_upload_image(struct
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3008,7 +3008,7 @@ static bool gl_video_upload_image(struct
</span>  
      if (p->hwdec_active) {
          // Hardware decoding
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_opengl_video.c-remove-timer-functionality.diff b/multimedia/mpv/files/patch-video_out_opengl_video.c-remove-timer-functionality.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 429cc1c..a1fa817 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-video_out_opengl_video.c-remove-timer-functionality.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_opengl_video.c-remove-timer-functionality.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,14 +1,14 @@
</span> --- video/out/opengl/utils.c.orig
 +++ video/out/opengl/utils.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -999,6 +999,7 @@ void gl_sc_gen_shader_and_reset(struct g
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-     gl_sc_reset(sc);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1057,6 +1057,7 @@ void gl_sc_generate(struct gl_shader_cac
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+     sc->needs_reset = true;
</span>  }
  
 +#if !defined(__APPLE__) || MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
  // Maximum number of simultaneous query objects to keep around. Reducing this
  // number might cause rendering to block until the result of a previous query is
  // available
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -1124,6 +1125,7 @@ void gl_timer_stop(struct gl_timer *time
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -1182,6 +1183,7 @@ void gl_timer_stop(struct gl_timer *time
</span>      if (gl->EndQuery)
          gl->EndQuery(GL_TIME_ELAPSED);
  }
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -29,25 +29,25 @@
</span>  #include "common.h"
  #include "math.h"
  
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -170,6 +174,7 @@ void gl_sc_enable_extension(struct gl_sh
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>- void gl_sc_gen_shader_and_reset(struct gl_shader_cache *sc);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -173,6 +177,7 @@ void gl_sc_generate(struct gl_shader_cac
</span>  void gl_sc_reset(struct gl_shader_cache *sc);
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ void gl_sc_unbind(struct gl_shader_cache *sc);
</span>  
 +#if !defined(__APPLE__) || MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
  struct gl_timer;
  
  struct gl_timer *gl_timer_create(GL *gl);
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -181,6 +186,7 @@ int gl_timer_sample_count(struct gl_time
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -184,6 +189,7 @@ int gl_timer_sample_count(struct gl_time
</span>  uint64_t gl_timer_last_us(struct gl_timer *timer);
  uint64_t gl_timer_avg_us(struct gl_timer *timer);
  uint64_t gl_timer_peak_us(struct gl_timer *timer);
 +#endif
  
<span style='display:block; white-space:pre;background:#ffe0e0;'>- struct gl_pbo_upload {
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-     GL *gl;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #define NUM_PBO_BUFFERS 3
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 
</span> --- video/out/opengl/video.c.orig
 +++ video/out/opengl/video.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -192,9 +192,11 @@ struct gl_video {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -193,9 +193,11 @@ struct gl_video {
</span>      GLuint dither_texture;
      int dither_size;
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -59,7 +59,7 @@
</span>  
      struct mp_image_params real_image_params;   // configured format
      struct mp_image_params image_params;        // texture format (mind hwdec case)
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2407,7 +2409,9 @@ static void pass_render_frame(struct gl_
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2467,7 +2469,9 @@ static void pass_render_frame(struct gl_
</span>      // start the render timer here. it will continue to the end of this
      // function, to render the time needed to draw (excluding screen
      // presentation)
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -69,7 +69,7 @@
</span>  
      p->use_linear = p->opts.linear_scaling || p->opts.sigmoid_upscaling;
      pass_read_video(p);
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2466,12 +2470,16 @@ static void pass_render_frame(struct gl_
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2526,12 +2530,16 @@ static void pass_render_frame(struct gl_
</span>  
      pass_opt_hook_point(p, "SCALED", NULL);
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -86,7 +86,7 @@
</span>  
      if (p->dumb_mode)
          pass_render_frame_dumb(p, fbo);
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2498,7 +2506,9 @@ static void pass_draw_to_screen(struct g
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2566,7 +2574,9 @@ static void pass_draw_to_screen(struct g
</span>      pass_dither(p);
      finish_pass_direct(p, fbo, p->vp_w, p->vp_h, &p->dst_rect);
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -96,7 +96,7 @@
</span>  }
  
  // Draws an interpolate frame to fbo, based on the frame timing in t
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2677,6 +2687,7 @@ static void gl_video_interpolate_frame(s
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2745,6 +2755,7 @@ static void gl_video_interpolate_frame(s
</span>      p->frames_drawn += 1;
  }
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -104,7 +104,7 @@
</span>  static void timer_dbg(struct gl_video *p, const char *name, struct gl_timer *t)
  {
      if (gl_timer_sample_count(t) > 0) {
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2686,6 +2697,7 @@ static void timer_dbg(struct gl_video *p
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2754,6 +2765,7 @@ static void timer_dbg(struct gl_video *p
</span>                 (int)gl_timer_peak_us(t));
      }
  }
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -112,7 +112,7 @@
</span>  
  // (fbo==0 makes BindFramebuffer select the screen backbuffer)
  void gl_video_render_frame(struct gl_video *p, struct vo_frame *frame, int fbo)
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2798,10 +2810,12 @@ done:
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2896,10 +2908,12 @@ done:
</span>  
      p->frames_rendered++;
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -125,15 +125,15 @@
</span>  }
  
  // vp_w/vp_h is the implicit size of the target framebuffer.
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2823,6 +2837,7 @@ void gl_video_resize(struct gl_video *p,
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-         mpgl_osd_resize(p->osd, p->osd_rect, p->image_params.stereo_out);
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2924,6 +2938,7 @@ void gl_video_resize(struct gl_video *p,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+         p->hwdec->driver->overlay_adjust(p->hwdec, vp_w, abs(vp_h), src, dst);
</span>  }
  
 +#if !defined(__APPLE__) || MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
  static struct voctrl_performance_entry gl_video_perfentry(struct gl_timer *t)
  {
      return (struct voctrl_performance_entry) {
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2840,6 +2855,7 @@ struct voctrl_performance_data gl_video_
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -2941,6 +2956,7 @@ struct voctrl_performance_data gl_video_
</span>          .present = gl_video_perfentry(p->present_timer),
      };
  }
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -141,7 +141,7 @@
</span>  
  // This assumes nv12, with textures set to GL_NEAREST filtering.
  static void reinterleave_vdpau(struct gl_video *p, struct gl_hwdec_frame *frame)
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2903,9 +2919,13 @@ static bool gl_video_upload_image(struct
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3009,9 +3025,13 @@ static bool gl_video_upload_image(struct
</span>      if (p->hwdec_active) {
          // Hardware decoding
          struct gl_hwdec_frame gl_frame = {{0}};
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -155,7 +155,7 @@
</span>          vimg->hwdec_mapped = true;
          if (ok) {
              struct mp_image layout = {0};
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2935,7 +2955,9 @@ static bool gl_video_upload_image(struct
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3041,7 +3061,9 @@ static bool gl_video_upload_image(struct
</span>      // Software decoding
      assert(mpi->num_planes == p->plane_count);
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -165,7 +165,7 @@
</span>  
  
      for (int n = 0; n < p->plane_count; n++) {
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -2951,7 +2973,9 @@ static bool gl_video_upload_image(struct
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3057,7 +3079,9 @@ static bool gl_video_upload_image(struct
</span>          gl->BindTexture(plane->gl_target, 0);
      }
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -175,7 +175,7 @@
</span>  
      return true;
  
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -3188,9 +3212,11 @@ static void init_gl(struct gl_video *p)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3294,9 +3318,11 @@ static void init_gl(struct gl_video *p)
</span>          gl->BindFramebuffer(GL_FRAMEBUFFER, 0);
      }
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -187,7 +187,7 @@
</span>  
      debug_check_gl(p, "after init_gl");
  }
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -3210,9 +3236,11 @@ void gl_video_uninit(struct gl_video *p)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3316,9 +3342,11 @@ void gl_video_uninit(struct gl_video *p)
</span>  
      gl->DeleteTextures(1, &p->lut_3d_texture);
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -212,7 +212,7 @@
</span>  #include "options/m_option.h"
  #include "sub/osd.h"
  #include "common.h"
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -158,7 +162,9 @@ void gl_video_render_frame(struct gl_vid
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -153,7 +157,9 @@ void gl_video_render_frame(struct gl_vid
</span>  void gl_video_resize(struct gl_video *p, int vp_w, int vp_h,
                       struct mp_rect *src, struct mp_rect *dst,
                       struct mp_osd_res *osd);
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -224,7 +224,7 @@
</span>  void gl_video_eq_update(struct gl_video *p);
 --- video/out/vo_opengl.c.orig
 +++ video/out/vo_opengl.c
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -349,7 +349,9 @@ static int control(struct vo *vo, uint32
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -339,7 +339,9 @@ static int control(struct vo *vo, uint32
</span>          }
          return true;
      case VOCTRL_PERFORMANCE_DATA:
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-video_out_vo_opengl.c-guard-GL3-and-backport-old-behavior.diff b/multimedia/mpv/files/patch-video_out_vo_opengl.c-guard-GL3-and-backport-old-behavior.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 6544247..bc3d3b8 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-video_out_vo_opengl.c-guard-GL3-and-backport-old-behavior.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-video_out_vo_opengl.c-guard-GL3-and-backport-old-behavior.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -11,7 +11,7 @@
</span>  #include <libavutil/common.h>
  
  #include "config.h"
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -84,8 +88,10 @@ struct gl_priv {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -110,8 +114,10 @@ struct gl_priv {
</span>      int last_pattern;
      int matches, mismatches;
  
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -22,12 +22,12 @@
</span>  };
  
  static void resize(struct gl_priv *p)
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -125,13 +131,21 @@ static void draw_frame(struct vo *vo, st
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -151,11 +157,13 @@ static void draw_frame(struct vo *vo, st
</span>      struct gl_priv *p = vo->priv;
      GL *gl = p->gl;
  
 +#if !defined(__APPLE__) || MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
<span style='display:block; white-space:pre;background:#ffe0e0;'>-     if (gl->FenceSync && p->num_vsync_fences < p->opt_vsync_fences) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+     if (gl->FenceSync && p->num_vsync_fences < p->opts->vsync_fences) {
</span>          GLsync fence = gl->FenceSync(GL_SYNC_GPU_COMMANDS_COMPLETE, 0);;
          if (fence)
              p->vsync_fences[p->num_vsync_fences++] = fence;
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -35,21 +35,13 @@
</span> +#endif
  
      gl_video_render_frame(p->renderer, frame, gl->main_fb);
<span style='display:block; white-space:pre;background:#ffe0e0;'>-+#if defined(__APPLE__) && MAC_OS_X_VERSION_MAX_ALLOWED < 1070
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+    // The playloop calls this last before waiting some time until it decides
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+    // to call flip_page(). Tell OpenGL to start execution of the GPU commands
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+    // while we sleep (this happens asynchronously).
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+    gl->Flush();
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-+#endif
</span>  
<span style='display:block; white-space:pre;background:#ffe0e0;'>-     if (p->use_glFinish)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-         gl->Finish();
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -168,11 +182,13 @@ static void flip_page(struct vo *vo)
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>-             p->opt_pattern[0] = 0;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -194,11 +202,13 @@ static void flip_page(struct vo *vo)
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+             p->opts->pattern[0] = 0;
</span>          }
      }
 +#if !defined(__APPLE__) || MAC_OS_X_VERSION_MAX_ALLOWED >= 1070
<span style='display:block; white-space:pre;background:#ffe0e0;'>-     while (p->opt_vsync_fences > 0 && p->num_vsync_fences >= p->opt_vsync_fences) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+     while (p->opts->vsync_fences > 0 && p->num_vsync_fences >= p->opts->vsync_fences) {
</span>          gl->ClientWaitSync(p->vsync_fences[0], GL_SYNC_FLUSH_COMMANDS_BIT, 1e9);
          gl->DeleteSync(p->vsync_fences[0]);
          MP_TARRAY_REMOVE_AT(p->vsync_fences, p->num_vsync_fences, 0);
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/multimedia/mpv/files/patch-waftools_checks_custom.py-disable-libarclite.diff b/multimedia/mpv/files/patch-waftools_checks_custom.py-disable-libarclite.diff
</span><span style='display:block; white-space:pre;color:#808080;'>index 742d93d..1ce92be 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/multimedia/mpv/files/patch-waftools_checks_custom.py-disable-libarclite.diff
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/multimedia/mpv/files/patch-waftools_checks_custom.py-disable-libarclite.diff
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -1,6 +1,6 @@
</span> --- waftools/checks/custom.py.orig
 +++ waftools/checks/custom.py
<span style='display:block; white-space:pre;background:#ffe0e0;'>-@@ -112,7 +112,6 @@ def check_cocoa(ctx, dependency_identifi
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -112,8 +112,7 @@ def check_cocoa(ctx, dependency_identifi
</span>          fragment         = load_fragment('cocoa.m'),
          compile_filename = 'test.m',
          framework_name   = ['Cocoa', 'IOKit', 'OpenGL', 'QuartzCore'],
<span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -9,3 +9,4 @@
</span> +        includes         = ctx.srcnode.abspath())
  
      return fn(ctx, dependency_identifier)
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ 
</span></pre><pre style='margin:0'>

</pre>