[Mesa-dev] [PATCH 12/12] i965/skl+: Enable support for 16x multisampling
Ben Widawsky
ben at bwidawsk.net
Tue Sep 22 16:54:22 PDT 2015
On Thu, Sep 17, 2015 at 05:00:14PM +0100, Neil Roberts wrote:
> ---
> src/mesa/drivers/dri/i965/brw_context.c | 6 ++++++
> src/mesa/drivers/dri/i965/intel_screen.c | 5 ++++-
> 2 files changed, 10 insertions(+), 1 deletion(-)
>
> diff --git a/src/mesa/drivers/dri/i965/brw_context.c b/src/mesa/drivers/dri/i965/brw_context.c
> index 7c1c133..c05fb74 100644
> --- a/src/mesa/drivers/dri/i965/brw_context.c
> +++ b/src/mesa/drivers/dri/i965/brw_context.c
> @@ -83,6 +83,12 @@ brw_query_samples_for_format(struct gl_context *ctx, GLenum target,
>
> switch (brw->gen) {
> case 9:
> + samples[0] = 16;
> + samples[1] = 8;
> + samples[2] = 4;
> + samples[3] = 2;
> + return 4;
> +
> case 8:
> samples[0] = 8;
> samples[1] = 4;
> diff --git a/src/mesa/drivers/dri/i965/intel_screen.c b/src/mesa/drivers/dri/i965/intel_screen.c
> index 1783835..f971797 100644
> --- a/src/mesa/drivers/dri/i965/intel_screen.c
> +++ b/src/mesa/drivers/dri/i965/intel_screen.c
> @@ -1178,12 +1178,15 @@ intel_detect_timestamp(struct intel_screen *screen)
> const int*
> intel_supported_msaa_modes(const struct intel_screen *screen)
> {
> + static const int gen9_modes[] = {16, 8, 4, 2, 0, -1};
> static const int gen8_modes[] = {8, 4, 2, 0, -1};
> static const int gen7_modes[] = {8, 4, 0, -1};
> static const int gen6_modes[] = {4, 0, -1};
> static const int gen4_modes[] = {0, -1};
>
> - if (screen->devinfo->gen >= 8) {
> + if (screen->devinfo->gen >= 9) {
> + return gen9_modes;
> + } else if (screen->devinfo->gen >= 8) {
> return gen8_modes;
> } else if (screen->devinfo->gen >= 7) {
> return gen7_modes;
I think you also should add a case in get_fast_clear_rect() (even though we
don't have fast clears turned on yet). It's in my fast clear branch I believe,
but it makes more sense in this series.
Reviewed-by: Ben Widawsky <ben at bwidawsk.net>
More information about the mesa-dev
mailing list