Blender V5.3
compositor_plane_deform_infos.hh
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
5#ifdef GPU_SHADER
6# pragma once
7# include "gpu_shader_compat.hh"
8#endif
9
10#ifdef GLSL_CPP_STUBS
11# define SAMPLER_FUNCTION texture
12#endif
13
15
16GPU_SHADER_CREATE_INFO(compositor_plane_deform_mask)
17LOCAL_GROUP_SIZE(16, 16)
18PUSH_CONSTANT(float4x4, homography_matrix)
19PUSH_CONSTANT(bool, is_x_clipped)
20PUSH_CONSTANT(bool, is_y_clipped)
21IMAGE(0, SFLOAT_16, write, image2D, mask_img)
22COMPUTE_SOURCE("compositor_plane_deform_mask.glsl")
25
26GPU_SHADER_CREATE_INFO(compositor_plane_deform_shared)
27LOCAL_GROUP_SIZE(16, 16)
28PUSH_CONSTANT(float4x4, homography_matrix)
29SAMPLER(0, sampler2D, input_tx)
30IMAGE(0, SFLOAT_16_16_16_16, write, image2D, output_img)
32
33GPU_SHADER_CREATE_INFO(compositor_plane_deform_masked_shared)
34ADDITIONAL_INFO(compositor_plane_deform_shared)
35DEFINE("PREMULTIPLY_MASK")
36SAMPLER(1, sampler2D, mask_tx)
38
39GPU_SHADER_CREATE_INFO(compositor_plane_deform)
40ADDITIONAL_INFO(compositor_plane_deform_shared)
41DEFINE_VALUE("SAMPLER_FUNCTION", "texture")
42COMPUTE_SOURCE("compositor_plane_deform.glsl")
45
46GPU_SHADER_CREATE_INFO(compositor_plane_deform_masked)
47ADDITIONAL_INFO(compositor_plane_deform_masked_shared)
48DEFINE_VALUE("SAMPLER_FUNCTION", "texture")
49COMPUTE_SOURCE("compositor_plane_deform.glsl")
52
53GPU_SHADER_CREATE_INFO(compositor_plane_deform_bicubic)
54ADDITIONAL_INFO(compositor_plane_deform_shared)
55DEFINE_VALUE("SAMPLER_FUNCTION", "texture_bicubic")
56COMPUTE_SOURCE("compositor_plane_deform.glsl")
59
60GPU_SHADER_CREATE_INFO(compositor_plane_deform_bicubic_masked)
61ADDITIONAL_INFO(compositor_plane_deform_masked_shared)
62DEFINE_VALUE("SAMPLER_FUNCTION", "texture_bicubic")
63COMPUTE_SOURCE("compositor_plane_deform.glsl")
66
67GPU_SHADER_CREATE_INFO(compositor_plane_deform_anisotropic_masked)
68ADDITIONAL_INFO(compositor_plane_deform_masked_shared)
69COMPUTE_SOURCE("compositor_plane_deform_anisotropic.glsl")
72
73GPU_SHADER_CREATE_INFO(compositor_plane_deform_motion_blur_mask)
74LOCAL_GROUP_SIZE(16, 16)
75PUSH_CONSTANT(int, number_of_motion_blur_samples)
76UNIFORM_BUF(0, float4x4, homography_matrices[64])
77IMAGE(0, SFLOAT_16, write, image2D, mask_img)
78COMPUTE_SOURCE("compositor_plane_deform_motion_blur_mask.glsl")
81
82GPU_SHADER_CREATE_INFO(compositor_plane_deform_motion_blur)
83LOCAL_GROUP_SIZE(16, 16)
84PUSH_CONSTANT(int, number_of_motion_blur_samples)
85UNIFORM_BUF(0, float4x4, homography_matrices[64])
86SAMPLER(0, sampler2D, input_tx)
87SAMPLER(1, sampler2D, mask_tx)
88IMAGE(0, SFLOAT_16_16_16_16, write, image2D, output_img)
89COMPUTE_SOURCE("compositor_plane_deform_motion_blur.glsl")
@ SFLOAT_16_16_16_16
#define GPU_SHADER_CREATE_INFO(_info)
#define GPU_SHADER_CREATE_END()
#define SAMPLER(slot, type, name)
#define UNIFORM_BUF(slot, type_name, name)
#define ADDITIONAL_INFO(info_name)
#define PUSH_CONSTANT(type, name)
#define DEFINE(name)
#define LOCAL_GROUP_SIZE(...)
#define IMAGE(slot, format, qualifiers, type, name)
#define COMPUTE_SOURCE(filename)
#define DO_STATIC_COMPILATION()
#define DEFINE_VALUE(name, value)
ImageBase< float, 2 > image2D
MatBase< 4, 4 > float4x4
SamplerBase< float, 2 > sampler2D