stObj->lastLevel = stObj->base._MaxLevel;
}
- firstImage = st_texture_image_const(stObj->base.Image[cubeMapFace][stObj->base.BaseLevel]);
- assert(firstImage);
-
/* Skip the loop over images in the common case of no images having
* changed. But if the GL_BASE_LEVEL or GL_MAX_LEVEL change to something we
* haven't looked at, then we do need to look at those new images.
return GL_TRUE;
}
+ /* If this texture comes from a window system, there is nothing else to do. */
+ if (stObj->surface_based) {
+ return GL_TRUE;
+ }
+
+ firstImage = st_texture_image_const(stObj->base.Image[cubeMapFace][stObj->base.BaseLevel]);
+ assert(firstImage);
+
/* If both firstImage and stObj point to a texture which can contain
* all active images, favour firstImage. Note that because of the
* completeness requirement, we know that the image dimensions
st_texture_release_all_sampler_views(st, stObj);
}
- /* If this texture comes from a window system, there is nothing else to do. */
- if (stObj->surface_based) {
- return GL_TRUE;
- }
-
/* Find gallium format for the Mesa texture */
firstImageFormat =
st_mesa_format_to_pipe_format(st, firstImage->base.TexFormat);
#include "st_cb_fbo.h"
#include "st_cb_flush.h"
#include "st_manager.h"
+#include "st_sampler_view.h"
#include "state_tracker/st_gl_api.h"
width = height = depth = 0;
}
+ pipe_resource_reference(&stObj->pt, tex);
+ st_texture_release_all_sampler_views(st, stObj);
pipe_resource_reference(&stImage->pt, tex);
stObj->surface_format = pipe_format;