Blender  V3.3
gpu_shader_builtin_test.cc
Go to the documentation of this file.
1 /* SPDX-License-Identifier: Apache-2.0 */
2 
3 #include "gpu_testing.hh"
4 
5 #include "GPU_shader.h"
6 
7 namespace blender::gpu::tests {
8 
10 {
12  EXPECT_NE(sh, nullptr);
13 }
14 
16 {
19 }
20 
21 static void test_shader_builtin()
22 {
24 
31 
71 }
72 
73 GPU_TEST(shader_builtin)
74 
75 } // namespace blender::gpu::tests
struct GPUShader GPUShader
Definition: GPU_shader.h:20
eGPUShaderConfig
Definition: GPU_shader.h:364
@ GPU_SHADER_CFG_DEFAULT
Definition: GPU_shader.h:365
@ GPU_SHADER_CFG_CLIPPED
Definition: GPU_shader.h:366
GPUShader * GPU_shader_get_builtin_shader_with_config(eGPUBuiltinShader shader, eGPUShaderConfig sh_cfg)
void GPU_shader_free_builtin_shaders(void)
eGPUBuiltinShader
Definition: GPU_shader.h:189
@ GPU_SHADER_2D_DIAG_STRIPES
Definition: GPU_shader.h:222
@ GPU_SHADER_3D_SMOOTH_COLOR
Definition: GPU_shader.h:245
@ GPU_SHADER_GPENCIL_STROKE
Definition: GPU_shader.h:352
@ GPU_SHADER_2D_NODELINK_INST
Definition: GPU_shader.h:359
@ GPU_SHADER_3D_LINE_DASHED_UNIFORM_COLOR
Definition: GPU_shader.h:350
@ GPU_SHADER_3D_POLYLINE_SMOOTH_COLOR
Definition: GPU_shader.h:270
@ GPU_SHADER_3D_POINT_VARYING_SIZE_VARYING_COLOR
Definition: GPU_shader.h:347
@ GPU_SHADER_2D_LINE_DASHED_UNIFORM_COLOR
Definition: GPU_shader.h:349
@ GPU_SHADER_KEYFRAME_SHAPE
Definition: GPU_shader.h:192
@ GPU_SHADER_3D_POLYLINE_UNIFORM_COLOR
Definition: GPU_shader.h:253
@ GPU_SHADER_2D_POINT_UNIFORM_SIZE_UNIFORM_COLOR_AA
Definition: GPU_shader.h:310
@ GPU_SHADER_2D_IMAGE_DESATURATE_COLOR
Definition: GPU_shader.h:218
@ GPU_SHADER_3D_DEPTH_ONLY
Definition: GPU_shader.h:277
@ GPU_SHADER_TEXT
Definition: GPU_shader.h:191
@ GPU_SHADER_3D_CLIPPED_UNIFORM_COLOR
Definition: GPU_shader.h:231
@ GPU_SHADER_2D_CHECKER
Definition: GPU_shader.h:221
@ GPU_SHADER_3D_POINT_UNIFORM_SIZE_UNIFORM_COLOR_AA
Definition: GPU_shader.h:338
@ GPU_SHADER_2D_IMAGE_MULTI_RECT_COLOR
Definition: GPU_shader.h:220
@ GPU_SHADER_2D_SMOOTH_COLOR
Definition: GPU_shader.h:215
@ GPU_SHADER_2D_UNIFORM_COLOR
Definition: GPU_shader.h:201
@ GPU_SHADER_3D_POINT_FIXED_SIZE_VARYING_COLOR
Definition: GPU_shader.h:329
@ GPU_SHADER_3D_UNIFORM_COLOR
Definition: GPU_shader.h:230
@ GPU_SHADER_2D_IMAGE_RECT_COLOR
Definition: GPU_shader.h:219
@ GPU_SHADER_3D_FLAT_COLOR
Definition: GPU_shader.h:238
@ GPU_SHADER_2D_WIDGET_BASE_INST
Definition: GPU_shader.h:356
@ GPU_SHADER_2D_IMAGE_SHUFFLE_COLOR
Definition: GPU_shader.h:281
@ GPU_SHADER_3D_IMAGE
Definition: GPU_shader.h:291
@ GPU_SHADER_2D_IMAGE_OVERLAYS_STEREO_MERGE
Definition: GPU_shader.h:280
@ GPU_SHADER_2D_POINT_UNIFORM_SIZE_UNIFORM_COLOR_OUTLINE_AA
Definition: GPU_shader.h:321
@ GPU_SHADER_2D_IMAGE
Definition: GPU_shader.h:216
@ GPU_SHADER_3D_POLYLINE_FLAT_COLOR
Definition: GPU_shader.h:262
@ GPU_SHADER_SIMPLE_LIGHTING
Definition: GPU_shader.h:193
@ GPU_SHADER_2D_IMAGE_COLOR
Definition: GPU_shader.h:217
@ GPU_SHADER_2D_WIDGET_SHADOW
Definition: GPU_shader.h:357
@ GPU_SHADER_2D_FLAT_COLOR
Definition: GPU_shader.h:208
@ GPU_SHADER_2D_WIDGET_BASE
Definition: GPU_shader.h:355
@ GPU_SHADER_2D_AREA_BORDERS
Definition: GPU_shader.h:354
@ GPU_SHADER_3D_POLYLINE_CLIPPED_UNIFORM_COLOR
Definition: GPU_shader.h:254
@ GPU_SHADER_2D_IMAGE_OVERLAYS_MERGE
Definition: GPU_shader.h:279
@ GPU_SHADER_2D_NODELINK
Definition: GPU_shader.h:358
#define GPU_TEST(test_name)
Definition: gpu_testing.hh:41
ccl_gpu_kernel_postfix ccl_global float int int int int sh
static void test_compile_builtin_shader(eGPUBuiltinShader shader_type, eGPUShaderConfig sh_cfg)