Blender V5.3
compositor_lens_distortion_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
11
12/* Radial Lens Distortion. */
13
14GPU_SHADER_CREATE_INFO(compositor_radial_lens_distortion_shared)
15LOCAL_GROUP_SIZE(16, 16)
16PUSH_CONSTANT(float3, chromatic_distortion)
17PUSH_CONSTANT(float, scale)
18SAMPLER(0, sampler2D, input_tx)
19IMAGE(0, SFLOAT_16_16_16_16, write, image2D, output_img)
20COMPUTE_SOURCE("compositor_radial_lens_distortion.glsl")
22
23GPU_SHADER_CREATE_INFO(compositor_radial_lens_distortion)
24ADDITIONAL_INFO(compositor_radial_lens_distortion_shared)
27
28GPU_SHADER_CREATE_INFO(compositor_radial_lens_distortion_jitter)
29ADDITIONAL_INFO(compositor_radial_lens_distortion_shared)
30DEFINE("JITTER")
33
34/* Horizontal Lens Distortion. */
35
36GPU_SHADER_CREATE_INFO(compositor_horizontal_lens_distortion)
37LOCAL_GROUP_SIZE(16, 16)
38PUSH_CONSTANT(float, dispersion)
39SAMPLER(0, sampler2D, input_tx)
40IMAGE(0, SFLOAT_16_16_16_16, write, image2D, output_img)
41COMPUTE_SOURCE("compositor_horizontal_lens_distortion.glsl")
@ SFLOAT_16_16_16_16
#define GPU_SHADER_CREATE_INFO(_info)
#define GPU_SHADER_CREATE_END()
#define SAMPLER(slot, type, 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()
ImageBase< float, 2 > image2D
SamplerBase< float, 2 > sampler2D
float3x3 scale(float3x3 mat, float2 scale)