nouveau: use pre-calculated stride for resource_get_handle
Fixes FDO#55294. NOTE: This is a candidate for the 9.0 branch.
This commit is contained in:
parent
45288cd2b6
commit
93eba26935
|
@ -56,8 +56,7 @@ nv30_miptree_get_handle(struct pipe_screen *pscreen,
|
||||||
if (!mt || !mt->base.bo)
|
if (!mt || !mt->base.bo)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
stride = util_format_get_stride(mt->base.base.format,
|
stride = mt->level[0].pitch;
|
||||||
mt->base.base.width0);
|
|
||||||
|
|
||||||
return nouveau_screen_bo_get_handle(pscreen, mt->base.bo, stride, handle);
|
return nouveau_screen_bo_get_handle(pscreen, mt->base.bo, stride, handle);
|
||||||
}
|
}
|
||||||
|
|
|
@ -133,8 +133,7 @@ nv50_miptree_get_handle(struct pipe_screen *pscreen,
|
||||||
if (!mt || !mt->base.bo)
|
if (!mt || !mt->base.bo)
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
||||||
stride = util_format_get_stride(mt->base.base.format,
|
stride = mt->level[0].pitch;
|
||||||
mt->base.base.width0);
|
|
||||||
|
|
||||||
return nouveau_screen_bo_get_handle(pscreen,
|
return nouveau_screen_bo_get_handle(pscreen,
|
||||||
mt->base.bo,
|
mt->base.bo,
|
||||||
|
|
Loading…
Reference in New Issue