mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-04 11:58:10 +02:00
gallium/util: add a new helper function pipe_buffer_size()
Signed-off-by: Feng Jiang <jiangfeng@kylinos.cn> Reviewed-by: Liming Sun <sunliming@kylinos.cn> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/17157>
This commit is contained in:
parent
e2199651b8
commit
15c210649d
1 changed files with 7 additions and 0 deletions
|
|
@ -319,6 +319,13 @@ pipe_surface_equal(struct pipe_surface *s1, struct pipe_surface *s2)
|
|||
*/
|
||||
|
||||
|
||||
static inline unsigned
|
||||
pipe_buffer_size(const struct pipe_resource *buffer)
|
||||
{
|
||||
return buffer->width0;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Create a new resource.
|
||||
* \param bind bitmask of PIPE_BIND_x flags
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue