Changeset View
Changeset View
Standalone View
Standalone View
source/blender/gpu/opengl/gl_backend.cc
| Show First 20 Lines • Show All 90 Lines • ▼ Show 20 Lines | #endif | ||||
| else if (strstr(vendor, "Mesa")) { | else if (strstr(vendor, "Mesa")) { | ||||
| GPG.device = GPU_DEVICE_SOFTWARE; | GPG.device = GPU_DEVICE_SOFTWARE; | ||||
| GPG.driver = GPU_DRIVER_SOFTWARE; | GPG.driver = GPU_DRIVER_SOFTWARE; | ||||
| } | } | ||||
| else if (strstr(vendor, "Microsoft")) { | else if (strstr(vendor, "Microsoft")) { | ||||
| GPG.device = GPU_DEVICE_SOFTWARE; | GPG.device = GPU_DEVICE_SOFTWARE; | ||||
| GPG.driver = GPU_DRIVER_SOFTWARE; | GPG.driver = GPU_DRIVER_SOFTWARE; | ||||
| } | } | ||||
| else if (strstr(vendor, "Apple")) { | |||||
| /* Apple Silicon. */ | |||||
| GPG.device = GPU_DEVICE_APPLE; | |||||
| GPG.driver = GPU_DRIVER_OFFICIAL; | |||||
| } | |||||
| else if (strstr(renderer, "Apple Software Renderer")) { | else if (strstr(renderer, "Apple Software Renderer")) { | ||||
| GPG.device = GPU_DEVICE_SOFTWARE; | GPG.device = GPU_DEVICE_SOFTWARE; | ||||
| GPG.driver = GPU_DRIVER_SOFTWARE; | GPG.driver = GPU_DRIVER_SOFTWARE; | ||||
| } | } | ||||
| else if (strstr(renderer, "llvmpipe") || strstr(renderer, "softpipe")) { | else if (strstr(renderer, "llvmpipe") || strstr(renderer, "softpipe")) { | ||||
| GPG.device = GPU_DEVICE_SOFTWARE; | GPG.device = GPU_DEVICE_SOFTWARE; | ||||
| GPG.driver = GPU_DRIVER_SOFTWARE; | GPG.driver = GPU_DRIVER_SOFTWARE; | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 132 Lines • ▼ Show 20 Lines | static void detect_workarounds() | ||||
| * GLEW_ARB_draw_indirect as it has an OpenGL3 context what also matches the minimum needed | * GLEW_ARB_draw_indirect as it has an OpenGL3 context what also matches the minimum needed | ||||
| * requirements. | * requirements. | ||||
| * | * | ||||
| * We use it as a target for glMapBuffer(Range) what is part of the OpenGL 4 API. So better | * We use it as a target for glMapBuffer(Range) what is part of the OpenGL 4 API. So better | ||||
| * disable it when we don't have an OpenGL4 context (See T77657) */ | * disable it when we don't have an OpenGL4 context (See T77657) */ | ||||
| if (!GLEW_VERSION_4_0) { | if (!GLEW_VERSION_4_0) { | ||||
| GLContext::base_instance_support = false; | GLContext::base_instance_support = false; | ||||
| } | } | ||||
| if (GPU_type_matches(GPU_DEVICE_ATI, GPU_OS_WIN, GPU_DRIVER_OFFICIAL) && | |||||
| (strstr(version, "4.5.13399") || strstr(version, "4.5.13417") || | |||||
| strstr(version, "4.5.13422") || strstr(version, "4.5.13467"))) { | |||||
| /* The renderers include: | /* The renderers include: | ||||
| * Mobility Radeon HD 5000; | * Radeon HD 5000; | ||||
| * Radeon HD 7500M; | * Radeon HD 7500M; | ||||
| * Radeon HD 7570M; | * Radeon HD 7570M; | ||||
| * Radeon HD 7600M; | * Radeon HD 7600M; | ||||
| * And many others... */ | * Radeon R5 Graphics; | ||||
| if (GPU_type_matches(GPU_DEVICE_ATI, GPU_OS_WIN, GPU_DRIVER_OFFICIAL) && | * And others... */ | ||||
| (strstr(version, "4.5.13399") || strstr(version, "4.5.13417") || | |||||
| strstr(version, "4.5.13422"))) { | |||||
| GLContext::unused_fb_slot_workaround = true; | GLContext::unused_fb_slot_workaround = true; | ||||
| GCaps.mip_render_workaround = true; | GCaps.mip_render_workaround = true; | ||||
| GCaps.shader_image_load_store_support = false; | GCaps.shader_image_load_store_support = false; | ||||
| GCaps.broken_amd_driver = true; | GCaps.broken_amd_driver = true; | ||||
| } | } | ||||
| /* We have issues with this specific renderer. (see T74024) */ | /* We have issues with this specific renderer. (see T74024) */ | ||||
| if (GPU_type_matches(GPU_DEVICE_ATI, GPU_OS_UNIX, GPU_DRIVER_OPENSOURCE) && | if (GPU_type_matches(GPU_DEVICE_ATI, GPU_OS_UNIX, GPU_DRIVER_OPENSOURCE) && | ||||
| strstr(renderer, "AMD VERDE")) { | strstr(renderer, "AMD VERDE")) { | ||||
| ▲ Show 20 Lines • Show All 184 Lines • Show Last 20 Lines | |||||