/* XXX if DrawPixels image is larger than max texture size, break
* it up into chunks.
*/
- maxSize = 1 << (pipe->screen->get_param(pipe->screen,
- PIPE_CAP_MAX_TEXTURE_2D_LEVELS) - 1);
+ maxSize = pipe->screen->get_param(pipe->screen,
+ PIPE_CAP_MAX_TEXTURE_2D_SIZE);
assert(width <= maxSize);
assert(height <= maxSize);
clamp_size(struct pipe_context *pipe, GLsizei *width, GLsizei *height,
struct gl_pixelstore_attrib *unpack)
{
- const int maxSize =
- 1 << (pipe->screen->get_param(pipe->screen,
- PIPE_CAP_MAX_TEXTURE_2D_LEVELS) - 1);
+ const int maxSize = pipe->screen->get_param(pipe->screen,
+ PIPE_CAP_MAX_TEXTURE_2D_SIZE);
if (*width > maxSize) {
if (unpack->RowLength == 0)