diff --git a/contrib/src/ass/0001-configure-add-Core-Text-and-DirectWrite-to-Libs.priv.patch b/contrib/src/ass/0001-configure-add-Core-Text-and-DirectWrite-to-Libs.priv.patch
index bdda1174f8cf97e2ae8407ee567dfcd77a21e5b0..2ec444bc01904cdd163218c4014484066ed2a6b9 100644
--- a/contrib/src/ass/0001-configure-add-Core-Text-and-DirectWrite-to-Libs.priv.patch
+++ b/contrib/src/ass/0001-configure-add-Core-Text-and-DirectWrite-to-Libs.priv.patch
@@ -1,7 +1,7 @@
-From 643829edd8408ec37182a04040fe5a7bf54dccc3 Mon Sep 17 00:00:00 2001
+From c0eefb7633ed21ebf8c030f7a870ff5e5005e821 Mon Sep 17 00:00:00 2001
 From: Oleg Oshmyan <chortos@inbox.lv>
 Date: Sat, 18 Sep 2021 03:04:15 +0300
-Subject: [PATCH] configure: add Core Text and DirectWrite to Libs.private
+Subject: [PATCH 3/4] configure: add Core Text and DirectWrite to Libs.private
 
 Fixes https://github.com/libass/libass/issues/211.
 ---
@@ -9,10 +9,10 @@ Fixes https://github.com/libass/libass/issues/211.
  1 file changed, 4 insertions(+)
 
 diff --git a/configure.ac b/configure.ac
-index 89d5eb0..6ae78a1 100644
+index 345a445..97abea9 100644
 --- a/configure.ac
 +++ b/configure.ac
-@@ -126,6 +126,7 @@ AS_IF([test "x$enable_coretext" != xno], [
+@@ -118,6 +118,7 @@ AS_IF([test "x$enable_coretext" != xno], [
              [[CTFontDescriptorCopyAttribute(NULL, kCTFontURLAttribute);]]
          )
      ], [
@@ -20,7 +20,7 @@ index 89d5eb0..6ae78a1 100644
          LIBS="$LIBS -framework ApplicationServices -framework CoreFoundation"
          AC_DEFINE(CONFIG_CORETEXT, 1, [found CoreText in ApplicationServices framework])
          coretext=true
-@@ -137,6 +138,7 @@ AS_IF([test "x$enable_coretext" != xno], [
+@@ -129,6 +130,7 @@ AS_IF([test "x$enable_coretext" != xno], [
                  [[CTFontDescriptorCopyAttribute(NULL, kCTFontURLAttribute);]]
              )
          ], [
@@ -28,7 +28,7 @@ index 89d5eb0..6ae78a1 100644
              LIBS="$LIBS -framework CoreText -framework CoreFoundation"
              AC_DEFINE(CONFIG_CORETEXT, 1, [found CoreText framework])
              coretext=true
-@@ -171,12 +173,14 @@ AS_IF([test "x$enable_directwrite" != xno], [
+@@ -160,12 +162,14 @@ AS_IF([test "x$enable_directwrite" != xno], [
          ], [
              # WinRT/UWP/app build: GDI and LoadLibrary are
              # unavailable, but DirectWrite is always present
@@ -44,5 +44,5 @@ index 89d5eb0..6ae78a1 100644
              AC_DEFINE(CONFIG_DIRECTWRITE, 1, [found DirectWrite and GDI (Win32)])
              AC_MSG_RESULT([yes])
 -- 
-2.34.1
+2.27.0.windows.1
 
diff --git a/contrib/src/ass/ass-macosx.patch b/contrib/src/ass/ass-macosx.patch
index f9d06e49310b87e4fd0086b2bdcbe3ef7e5ea045..d0c09a3281686b2e894d850cbcff6a1877083552 100644
--- a/contrib/src/ass/ass-macosx.patch
+++ b/contrib/src/ass/ass-macosx.patch
@@ -1,6 +1,23 @@
---- libass-0.13.0/libass/ass_fontconfig.c.orig	2015-10-06 16:03:01.104710780 +0200
-+++ libass-0.13.0/libass/ass_fontconfig.c	2015-10-06 16:03:00.216719387 +0200
-@@ -282,6 +282,9 @@
+From f26a12597c0a3a907bd30547daa35153ed3aa11c Mon Sep 17 00:00:00 2001
+From: Naohiro Koriyama <nkoriyama@gmail.com>
+Date: Wed, 29 Aug 2012 16:44:16 +0200
+Subject: [PATCH 2/4] added fontconfig font search paths for OS X.
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+On OS X, fontconfig searches font only from /System/Library/Fonts, so this patch adds more search paths to its initialization.
+
+Signed-off-by: Felix Paul Kühne <fkuehne@videolan.org>
+---
+ libass/ass_fontconfig.c | 3 +++
+ 1 file changed, 3 insertions(+)
+
+diff --git a/libass/ass_fontconfig.c b/libass/ass_fontconfig.c
+index fd6ea33..10a17ed 100644
+--- a/libass/ass_fontconfig.c
++++ b/libass/ass_fontconfig.c
+@@ -336,6 +336,9 @@ ass_fontconfig_add_provider(ASS_Library *lib, ASS_FontSelector *selector,
                  "file found, using fallback.");
          FcConfigDestroy(fc->config);
          fc->config = FcInitLoadConfig();
@@ -10,3 +27,6 @@
      }
      if (fc->config)
          rc = FcConfigBuildFonts(fc->config);
+-- 
+2.27.0.windows.1
+
diff --git a/contrib/src/ass/libass-freetype-fix.patch b/contrib/src/ass/libass-freetype-fix.patch
index 69f00eaeb2c431790257ba7c77571ace94811e5d..16fab926ba93669937c5168f761ce9ae7c6c60f2 100644
--- a/contrib/src/ass/libass-freetype-fix.patch
+++ b/contrib/src/ass/libass-freetype-fix.patch
@@ -1,8 +1,8 @@
-From 0915955733bd236ecc44645ee968fb7a55ad5079 Mon Sep 17 00:00:00 2001
+From b7e8314560f03d252182c051df1f04175299118e Mon Sep 17 00:00:00 2001
 From: Oleg Oshmyan <chortos@inbox.lv>
 Date: Mon, 20 Sep 2021 23:37:23 +0300
-Subject: [PATCH] Add strikeout/underline to ASS_Outline, not FreeType-owned
- memory
+Subject: [PATCH 1/4] Add strikeout/underline to ASS_Outline, not
+ FreeType-owned memory
 
 ass_strike_outline_glyph was realloc()ing memory that was
 allocated by FreeType, not us. This isn't generally safe.
@@ -23,7 +23,7 @@ Fixes the crash in https://github.com/mpv-player/mpv/issues/9227.
  3 files changed, 32 insertions(+), 32 deletions(-)
 
 diff --git a/libass/ass_font.c b/libass/ass_font.c
-index 221a7b4a7..46b797598 100644
+index 221a7b4..46b7975 100644
 --- a/libass/ass_font.c
 +++ b/libass/ass_font.c
 @@ -357,29 +357,25 @@ void ass_font_get_asc_desc(ASS_Font *font, int face_index,
@@ -143,7 +143,7 @@ index 221a7b4a7..46b797598 100644
  }
  
 diff --git a/libass/ass_font.h b/libass/ass_font.h
-index 98ac1c85b..57f832d67 100644
+index 98ac1c8..57f832d 100644
 --- a/libass/ass_font.h
 +++ b/libass/ass_font.h
 @@ -30,6 +30,7 @@ typedef struct ass_font ASS_Font;
@@ -166,7 +166,7 @@ index 98ac1c85b..57f832d67 100644
                        const char *postscript_name, int index);
  FT_Face ass_face_stream(ASS_Library *lib, FT_Library ftlib, const char *name,
 diff --git a/libass/ass_render.c b/libass/ass_render.c
-index 59c54b923..5fcbe968b 100644
+index 0bf6676..0558066 100644
 --- a/libass/ass_render.c
 +++ b/libass/ass_render.c
 @@ -1173,6 +1173,10 @@ size_t ass_outline_construct(void *key, void *value, void *priv)
@@ -180,3 +180,6 @@ index 59c54b923..5fcbe968b 100644
                  FT_Done_Glyph(glyph);
                  ass_font_get_asc_desc(k->font, k->face_index,
                                        &v->asc, &v->desc);
+-- 
+2.27.0.windows.1
+
diff --git a/contrib/src/ass/use-topendir.patch b/contrib/src/ass/use-topendir.patch
index 3d2ef6be277b3146c3e7947d98dbc1985151bfe9..c39f4fe232d5cd99e438ab688b9ddf8cb0c55cd9 100644
--- a/contrib/src/ass/use-topendir.patch
+++ b/contrib/src/ass/use-topendir.patch
@@ -1,5 +1,16 @@
---- a/libass/ass_fontselect.c.orig	2021-09-11 23:27:04.000000000 +0200
-+++ b/libass/ass_fontselect.c	2021-12-29 17:18:47.535670604 +0100
+From 3024055a3a7da6ebbf5b843420aa5bf47ef66d13 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Hugo=20Beauz=C3=A9e-Luyssen?= <hugo@beauzee.fr>
+Date: Thu, 7 Apr 2016 14:59:34 +0200
+Subject: [PATCH 4/4] Use wopendir when possible
+
+---
+ libass/ass_fontselect.c | 50 ++++++++++++++++++++++++++++++++++++-----
+ 1 file changed, 44 insertions(+), 6 deletions(-)
+
+diff --git a/libass/ass_fontselect.c b/libass/ass_fontselect.c
+index b47c4bc..47a5d0b 100644
+--- a/libass/ass_fontselect.c
++++ b/libass/ass_fontselect.c
 @@ -47,6 +47,9 @@
  #include "ass_font.h"
  #include "ass_string.h"
@@ -10,7 +21,7 @@
  #define ABS(x) ((x) < 0 ? -(x) : (x))
  #define MAX_FULLNAME 100
  
-@@ -166,21 +169,55 @@
+@@ -166,21 +169,55 @@ static ASS_FontProviderFuncs ft_funcs = {
      .destroy_font      = destroy_font_ft,
  };
  
@@ -69,7 +80,7 @@
          if (namelen < 2 || namelen - 2 < dirlen)
              continue;
          if (namelen > namemax) {
-@@ -190,17 +227,18 @@
+@@ -190,17 +227,18 @@ static void load_fonts_from_dir(ASS_Library *library, const char *dir)
              else
                  continue;
          }
@@ -91,3 +102,6 @@
  }
  
  /**
+-- 
+2.27.0.windows.1
+