diff options
author | Marek Olšák <[email protected]> | 2017-06-12 01:27:26 +0200 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2017-06-22 01:51:02 +0200 |
commit | d14bb37a0a5c29793a41221be0cb8f8faa497ae0 (patch) | |
tree | 9aeed5517e28ea6d616b3917fe0dcb03901e914c /src/mesa/state_tracker | |
parent | bfe1e7737a76e3b046881976dd21c829ab5eccb0 (diff) |
st/mesa: don't call u_sampler_view_default_template for sampler views
Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/mesa/state_tracker')
-rw-r--r-- | src/mesa/state_tracker/st_sampler_view.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/mesa/state_tracker/st_sampler_view.c b/src/mesa/state_tracker/st_sampler_view.c index 8c814ed0a3c..7a8d05d710a 100644 --- a/src/mesa/state_tracker/st_sampler_view.c +++ b/src/mesa/state_tracker/st_sampler_view.c @@ -373,10 +373,11 @@ st_create_texture_sampler_view_from_stobj(struct st_context *st, enum pipe_format format, bool glsl130_or_later) { + /* There is no need to clear this structure (consider CPU overhead). */ struct pipe_sampler_view templ; unsigned swizzle = get_texture_format_swizzle(st, stObj, glsl130_or_later); - u_sampler_view_default_template(&templ, stObj->pt, format); + templ.format = format; templ.u.tex.first_level = stObj->base.MinLevel + stObj->base.BaseLevel; templ.u.tex.last_level = last_level(stObj); |