mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-11 08:38:05 +02:00
[g3dvl] fix power_of_two buffer with/height handling
This commit is contained in:
parent
e9b305c100
commit
1a238efe42
1 changed files with 8 additions and 2 deletions
|
|
@ -232,8 +232,14 @@ Status XvMCCreateSurface(Display *dpy, XvMCContext *context, XvMCSurface *surfac
|
|||
return BadAlloc;
|
||||
}
|
||||
template.last_level = 0;
|
||||
template.width0 = util_next_power_of_two(context->width);
|
||||
template.height0 = util_next_power_of_two(context->height);
|
||||
if (vpipe->get_param(vpipe, PIPE_CAP_NPOT_TEXTURES)) {
|
||||
template.width0 = context->width;
|
||||
template.height0 = context->height;
|
||||
}
|
||||
else {
|
||||
template.width0 = util_next_power_of_two(context->width);
|
||||
template.height0 = util_next_power_of_two(context->height);
|
||||
}
|
||||
template.depth0 = 1;
|
||||
template.array_size = 1;
|
||||
template.usage = PIPE_USAGE_DEFAULT;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue