radeonsi: Count planes for imported textures.
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Mon, 27 Apr 2020 22:40:12 +0000 (00:40 +0200)
committerMarge Bot <eric+marge@anholt.net>
Tue, 28 Apr 2020 11:16:03 +0000 (11:16 +0000)
commit8e03cf15f9516642ba7f7cd7b7a2d7aad835796a
tree94ba829356cb7c5e69e120e167825ff24f1a4eec
parent6747a984f59ea9a2dd74b98d59cb8fdb028969ae
radeonsi: Count planes for imported textures.

For the DRI2 lowered YUV import separate pipe_resources get created
but in the end the first resource just gets asked for NPLANES.

Since

1) (Almost) everything uses the first resource + a plane index in the
  Gallium interface.
2) This mirrors non-imported textures.

lets fix this in the driver.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/4779>
src/gallium/drivers/radeonsi/si_texture.c