blitter: Add a FS shader for MSAA depth blits

This will be needed because on GLES blits to a MS surface need to
use the GL fallback path.

Signed-off-By: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
macos/master
Gert Wollny 6 years ago
parent 6b25eab1f4
commit 9cf537c47f
  1. 10
      src/vrend_blitter.h

@ -111,8 +111,16 @@
" gl_FragDepth = float(texelFetch(samp, %s(tc%s), int(tc.z)).x);\n" \ " gl_FragDepth = float(texelFetch(samp, %s(tc%s), int(tc.z)).x);\n" \
"}\n" "}\n"
#define FS_TEXFETCH_DS_MSAA_BODY_GLES \
"uniform mediump sampler%s samp;\n" \
"in vec4 tc;\n" \
"void main() {\n" \
" gl_FragDepth = float(texelFetch(samp, %s(tc%s), int(tc.z)).x);\n" \
"}\n"
#define FS_TEXFETCH_DS_MSAA_GL HEADER_GL FS_TEXFETCH_DS_MSAA_BODY #define FS_TEXFETCH_DS_MSAA_GL HEADER_GL FS_TEXFETCH_DS_MSAA_BODY
#define FS_TEXFETCH_DS_MSAA_GLES HEADER_GLES FS_TEXFETCH_DS_MSAA_BODY #define FS_TEXFETCH_DS_MSAA_GLES HEADER_GLES FS_TEXFETCH_DS_MSAA_BODY_GLES
#endif #endif

Loading…
Cancel
Save