aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPär Björklund <per.bjorklund@gmail.com>2017-07-17 17:07:15 +0200
committerGitHub <noreply@github.com>2017-07-17 17:07:15 +0200
commit907c7224f9e266a623f3a031c77362ef9f536d41 (patch)
tree4c8b297f09664b47fe14554a4a9f8cf62dbd4a08
parentcc1f21cc4ca2fccb5023c5f45110611b8024f523 (diff)
parent0e5e8bc3eca9e0359637739fd4ff6a2d30482e5c (diff)
Merge pull request #12515 from Paxxi/assfix3
[xbmc][win32] Fix a crash for subtitle rendering in 4k on amd cards
-rw-r--r--project/BuildDependencies/scripts/0_package.list2
-rw-r--r--xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererDX.cpp2
-rw-r--r--xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererGL.cpp2
-rw-r--r--xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.cpp6
-rw-r--r--xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.h2
5 files changed, 7 insertions, 7 deletions
diff --git a/project/BuildDependencies/scripts/0_package.list b/project/BuildDependencies/scripts/0_package.list
index f4f87dba37..2d15488f24 100644
--- a/project/BuildDependencies/scripts/0_package.list
+++ b/project/BuildDependencies/scripts/0_package.list
@@ -16,7 +16,7 @@ expat-2.2.0-win32-vc140.7z
freetype-db5a22-win32-vc140.7z
giflib-5.1.4-win32-vc140.7z
jsonschemabuilder-1.0.0-win32-3.7z
-libass-d18a5f1-win32-vc140.7z
+libass-317313-win32-vc140.7z
libbluray-0.9.3-win32-vc140.7z
libcdio-0.9.3-win32-vc140.7z
libcec-4.0.1-win32-vc140-2.7z
diff --git a/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererDX.cpp b/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererDX.cpp
index d9afae743a..6ed166b86f 100644
--- a/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererDX.cpp
+++ b/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererDX.cpp
@@ -81,7 +81,7 @@ COverlayQuadsDX::COverlayQuadsDX(ASS_Image* images, int width, int height)
m_count = 0;
SQuads quads;
- if(!convert_quad(images, quads))
+ if(!convert_quad(images, quads, width))
return;
float u, v;
diff --git a/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererGL.cpp b/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererGL.cpp
index 1c3671aaf7..e8ff344ad8 100644
--- a/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererGL.cpp
+++ b/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererGL.cpp
@@ -301,7 +301,7 @@ COverlayGlyphGL::COverlayGlyphGL(ASS_Image* images, int width, int height)
m_texture = 0;
SQuads quads;
- if(!convert_quad(images, quads))
+ if(!convert_quad(images, quads, width))
return;
glGenTextures(1, &m_texture);
diff --git a/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.cpp b/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.cpp
index f19451ac4b..9293d8ac76 100644
--- a/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.cpp
+++ b/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.cpp
@@ -182,7 +182,7 @@ uint32_t* convert_rgba(CDVDOverlaySpu* o, bool mergealpha
return rgba;
}
-bool convert_quad(ASS_Image* images, SQuads& quads)
+bool convert_quad(ASS_Image* images, SQuads& quads, int max_x)
{
ASS_Image* img;
@@ -204,8 +204,8 @@ bool convert_quad(ASS_Image* images, SQuads& quads)
if (quads.count == 0)
return false;
- if (quads.size_x > (int)g_Windowing.GetMaxTextureSize())
- quads.size_x = g_Windowing.GetMaxTextureSize();
+ if (quads.size_x > max_x)
+ quads.size_x = max_x;
int curr_x = 0;
int curr_y = 0;
diff --git a/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.h b/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.h
index a132149bee..6c5ddc4064 100644
--- a/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.h
+++ b/xbmc/cores/VideoPlayer/VideoRenderers/OverlayRendererUtil.h
@@ -63,7 +63,7 @@ namespace OVERLAY {
uint32_t* convert_rgba(CDVDOverlaySpu* o, bool mergealpha
, int& min_x, int& max_x
, int& min_y, int& max_y);
- bool convert_quad(ASS_Image* images, SQuads& quads);
+ bool convert_quad(ASS_Image* images, SQuads& quads, int max_x);
int GetStereoscopicDepth();
}