mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 07:18:17 +02:00
i965: Fix context initialization after 2f89662717
You can't return stack-initialized values and expect anything good to happen. Reviewed-by: Chad Versace <chad.versace@linux.intel.com Reviewed-by: Matt Turner <mattst88@gmail.com>
This commit is contained in:
parent
5ae31d7e1d
commit
3f319eef76
1 changed files with 6 additions and 3 deletions
|
|
@ -275,12 +275,15 @@ brw_init_driver_functions(struct brw_context *brw,
|
|||
static const int*
|
||||
brw_supported_msaa_modes(const struct brw_context *brw)
|
||||
{
|
||||
static const int gen7_samples[] = {8, 4, 0};
|
||||
static const int gen6_samples[] = {4, 0};
|
||||
static const int gen4_samples[] = {0};
|
||||
if (brw->gen >= 7) {
|
||||
return (int[]){8, 4, 0};
|
||||
return gen7_samples;
|
||||
} else if (brw->gen == 6) {
|
||||
return (int[]){4, 0};
|
||||
return gen6_samples;
|
||||
} else {
|
||||
return (int[]){0};
|
||||
return gen4_samples;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue