diff options
author | Brian Paul <[email protected]> | 2019-03-06 16:09:09 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2019-03-11 20:08:16 -0600 |
commit | 41adb3d6dff63d34e431972b37d304ff0a3070f1 (patch) | |
tree | 0e7b006d8fc6a2c4e73ae34205f86e1152b483c3 /src/mesa | |
parent | c7d25046254bbd1a96ce4ba7572c1afb8dc52afd (diff) |
st/mesa: add/improve sampler view comments
Reviewed-by: Neha Bhende <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/state_tracker/st_sampler_view.c | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_sampler_view.c b/src/mesa/state_tracker/st_sampler_view.c index 1669de5d769..b22aa20d0a1 100644 --- a/src/mesa/state_tracker/st_sampler_view.c +++ b/src/mesa/state_tracker/st_sampler_view.c @@ -181,7 +181,8 @@ st_texture_get_current_sampler_view(const struct st_context *st, /** * For the given texture object, release any sampler views which belong - * to the calling context. + * to the calling context. This is used to free any sampler views + * which belong to the context before the context is destroyed. */ void st_texture_release_sampler_view(struct st_context *st, @@ -205,7 +206,8 @@ st_texture_release_sampler_view(struct st_context *st, /** * Release all sampler views attached to the given texture object, regardless - * of the context. + * of the context. This is called fairly frequently. For example, whenever + * the texture's base level, max level or swizzle change. */ void st_texture_release_all_sampler_views(struct st_context *st, @@ -228,6 +230,10 @@ st_texture_release_all_sampler_views(struct st_context *st, } +/* + * Free the texture's st_sampler_views objects. This should be called + * after st_texture_release_all_sampler_views(). + */ void st_texture_free_sampler_views(struct st_texture_object *stObj) { |