vlc | branch: master | Steve Lhomme <[email protected]> | Fri Feb 12 14:21:13 2021 +0100| [a81ec25938ed38db9131946602f0133df78d1040] | committer: Steve Lhomme
d3d_dynamic_shader: simplify the NV12 plane moving setting > http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=a81ec25938ed38db9131946602f0133df78d1040 --- modules/video_output/win32/d3d_dynamic_shader.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/modules/video_output/win32/d3d_dynamic_shader.c b/modules/video_output/win32/d3d_dynamic_shader.c index c5b03532cd..18737da991 100644 --- a/modules/video_output/win32/d3d_dynamic_shader.c +++ b/modules/video_output/win32/d3d_dynamic_shader.c @@ -309,7 +309,7 @@ HRESULT (D3D_CompilePixelShader)(vlc_object_t *o, const d3d_shader_compiler_t *c const char *psz_primaries_transform = DEFAULT_NOOP; const char *psz_tone_mapping = "return rgb * LuminanceScale"; const char *psz_adjust_range = DEFAULT_NOOP; - const char *psz_move_planes[2] = {DEFAULT_NOOP, DEFAULT_NOOP}; + const char *psz_move_planes_1 = DEFAULT_NOOP; char *psz_range = NULL; if ( display->pixelFormat->formatTexture == DXGI_FORMAT_NV12 || @@ -340,11 +340,10 @@ HRESULT (D3D_CompilePixelShader)(vlc_object_t *o, const d3d_shader_compiler_t *c /* Y */ psz_sampler[0] = "sample = shaderTexture[0].Sample(samplerState, coords);\n"; - psz_move_planes[0] = "return rgb"; /* UV */ psz_sampler[1] = "sample = shaderTexture[0].Sample(samplerState, coords);\n"; - psz_move_planes[1] = + psz_move_planes_1 = "rgb.x = rgb.y;\n" "rgb.y = rgb.z;\n" "rgb.z = 0;\n" @@ -639,7 +638,7 @@ HRESULT (D3D_CompilePixelShader)(vlc_object_t *o, const d3d_shader_compiler_t *c psz_primaries_transform, psz_linear_to_display, psz_tone_mapping, - psz_adjust_range, psz_move_planes[0], &pPSBlob[0]); + psz_adjust_range, DEFAULT_NOOP, &pPSBlob[0]); if (SUCCEEDED(hr) && psz_sampler[1]) { hr = CompilePixelShaderBlob(o, compiler, feature_level, texture_array, @@ -648,7 +647,7 @@ HRESULT (D3D_CompilePixelShader)(vlc_object_t *o, const d3d_shader_compiler_t *c psz_primaries_transform, psz_linear_to_display, psz_tone_mapping, - psz_adjust_range, psz_move_planes[1], &pPSBlob[1]); + psz_adjust_range, psz_move_planes_1, &pPSBlob[1]); if (FAILED(hr)) D3D_ShaderBlobRelease(&pPSBlob[0]); } _______________________________________________ vlc-commits mailing list [email protected] https://mailman.videolan.org/listinfo/vlc-commits
