diff options
Diffstat (limited to 'subprojects/packagefiles/libplacebo')
| -rw-r--r-- | subprojects/packagefiles/libplacebo/fix_rotate.diff | 29 | ||||
| -rw-r--r-- | subprojects/packagefiles/libplacebo/no_dlltool_no_shaderc_version.diff (renamed from subprojects/packagefiles/libplacebo/no_dlltool.diff) | 17 | ||||
| -rw-r--r-- | subprojects/packagefiles/libplacebo/stretch.diff | 15 |
3 files changed, 43 insertions, 18 deletions
diff --git a/subprojects/packagefiles/libplacebo/fix_rotate.diff b/subprojects/packagefiles/libplacebo/fix_rotate.diff new file mode 100644 index 0000000..793a456 --- /dev/null +++ b/subprojects/packagefiles/libplacebo/fix_rotate.diff @@ -0,0 +1,29 @@ +diff --git a/src/renderer.c b/src/renderer.c +index 802480d..08eff17 100644 +--- a/src/renderer.c ++++ b/src/renderer.c +@@ -2801,6 +2801,9 @@ static void fix_refs_and_rects(struct pass_state *pass) + pl_rect2df_normalize(src); + pl_rect2df_normalize(dst); + ++ if (flipped_y) PL_SWAP(dst->y1, dst->y0); ++ if (flipped_x) PL_SWAP(dst->x1, dst->x0); ++ + // Round the output rect and clip it to the framebuffer dimensions + float rx0 = roundf(PL_CLAMP(dst->x0, 0.0, dst_w)), + ry0 = roundf(PL_CLAMP(dst->y0, 0.0, dst_h)), +@@ -2822,10 +2825,10 @@ static void fix_refs_and_rects(struct pass_state *pass) + // always do this in the `dst` rather than the `src`` because this allows + // e.g. polar sampling compute shaders to work. + *dst = (pl_rect2df) { +- .x0 = flipped_x ? rx1 : rx0, +- .y0 = flipped_y ? ry1 : ry0, +- .x1 = flipped_x ? rx0 : rx1, +- .y1 = flipped_y ? ry0 : ry1, ++ .x0 = rx0, ++ .y0 = ry0, ++ .x1 = rx1, ++ .y1 = ry1, + }; + + // Copies of the above, for convenience diff --git a/subprojects/packagefiles/libplacebo/no_dlltool.diff b/subprojects/packagefiles/libplacebo/no_dlltool_no_shaderc_version.diff index e5c017c..a579431 100644 --- a/subprojects/packagefiles/libplacebo/no_dlltool.diff +++ b/subprojects/packagefiles/libplacebo/no_dlltool_no_shaderc_version.diff @@ -1,10 +1,21 @@ +diff --git a/src/glsl/meson.build b/src/glsl/meson.build +index 5a88196..d6bb430 100644 +--- a/src/glsl/meson.build ++++ b/src/glsl/meson.build +@@ -1,5 +1,5 @@ + # shaderc +-shaderc = dependency('shaderc', version: '>=2019.1', required: get_option('shaderc')) ++shaderc = dependency('shaderc', required: get_option('shaderc')) + components.set('shaderc', shaderc.found()) + if shaderc.found() + build_deps += shaderc diff --git a/src/meson.build b/src/meson.build -index 5958254..ee33055 100644 +index 6162f8f..f93eb4c 100644 --- a/src/meson.build +++ b/src/meson.build @@ -18,24 +18,24 @@ link_args = [] link_depends = [] - + # Looks like meson in certain configuration returns ' ' instead of empty string -mingw32 = cc.get_define('__MINGW32__').strip() -if host_machine.system() == 'windows' and mingw32 != '' and host_machine.cpu() in ['aarch64', 'arm', 'x86_64'] @@ -42,6 +53,6 @@ index 5958254..ee33055 100644 +# # the powf specialization from UCRT, so disable inlining. +# add_project_arguments(['-D__CRT__NO_INLINE'], language: ['c', 'cpp']) +#endif - + # Work around missing atomics on some (obscure) platforms atomic_test = ''' diff --git a/subprojects/packagefiles/libplacebo/stretch.diff b/subprojects/packagefiles/libplacebo/stretch.diff deleted file mode 100644 index 40544bc..0000000 --- a/subprojects/packagefiles/libplacebo/stretch.diff +++ /dev/null @@ -1,15 +0,0 @@ -diff --git a/src/renderer.c b/src/renderer.c -index a052bc5..639fbfd 100644 ---- a/src/renderer.c -+++ b/src/renderer.c -@@ -1845,8 +1845,8 @@ static bool pass_read_image(struct pass_state *pass) - .rect = { - off_x, - off_y, -- off_x + pl_rect_w(ref->img.rect), -- off_y + pl_rect_h(ref->img.rect), -+ off_x + pl_rect_w(ref->img.rect) / stretch_x, -+ off_y + pl_rect_h(ref->img.rect) / stretch_y, - }, - }; - |