1
0
Fork 0
forked from suyu/suyu

Merge pull request #2097 from ReinUsesLisp/fixup-texview

gl_rasterizer_cache: Fixup texture view parameters
This commit is contained in:
bunnei 2019-02-08 17:30:36 -05:00 committed by GitHub
commit 504aafedd2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -853,8 +853,8 @@ void CachedSurface::EnsureTextureView() {
constexpr GLuint min_level = 0; constexpr GLuint min_level = 0;
glGenTextures(1, &texture_view.handle); glGenTextures(1, &texture_view.handle);
glTextureView(texture_view.handle, target, texture.handle, gl_internal_format, 0, glTextureView(texture_view.handle, target, texture.handle, gl_internal_format, min_level,
params.max_mip_level, 0, 1); params.max_mip_level, min_layer, num_layers);
ApplyTextureDefaults(texture_view.handle, params.max_mip_level); ApplyTextureDefaults(texture_view.handle, params.max_mip_level);
glTextureParameteriv(texture_view.handle, GL_TEXTURE_SWIZZLE_RGBA, glTextureParameteriv(texture_view.handle, GL_TEXTURE_SWIZZLE_RGBA,
reinterpret_cast<const GLint*>(swizzle.data())); reinterpret_cast<const GLint*>(swizzle.data()));