Blender V4.3
COM_BokehImageOperation.h
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2011 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
5#pragma once
6
8
10
11namespace blender::compositor {
12
14 private:
15 const NodeBokehImage *data_;
16
17 int resolution_ = COM_BLUR_BOKEH_PIXELS;
18
19 float exterior_angle_;
20 float rotation_;
21 float roundness_;
22 float catadioptric_;
23 float lens_shift_;
24
25 /* See the delete_data_on_finish method. */
26 bool delete_data_;
27
34 float2 get_regular_polygon_vertex_position(int vertex_index);
39 float2 closest_point_on_line(float2 point, float2 line_start, float2 line_end);
56 float bokeh(float2 point, float circumradius);
57
58 public:
60
61 void init_execution() override;
62 void deinit_execution() override;
63
64 void determine_canvas(const rcti &preferred_area, rcti &r_area) override;
65
67 {
68 data_ = data;
69 }
70
71 void set_resolution(int resolution)
72 {
73 resolution_ = resolution;
74 }
75
84 {
85 delete_data_ = true;
86 }
87
89 const rcti &area,
91};
92
93} // namespace blender::compositor
in reality light always falls off quadratically Particle Retrieve the data of the particle that spawned the object for example to give variation to multiple instances of an object Point Retrieve information about points in a point cloud Retrieve the edges of an object as it appears to Cycles topology will always appear triangulated Convert a blackbody temperature to an RGB value Normal Generate a perturbed normal from an RGB normal map image Typically used for faking highly detailed surfaces Generate an OSL shader from a file or text data block Image Sample an image file as a texture Gabor Generate Gabor noise Gradient Generate interpolated color and intensity values based on the input vector Magic Generate a psychedelic color texture Voronoi Generate Worley noise based on the distance to random points Typically used to generate textures such as or biological cells Brick Generate a procedural texture producing bricks Texture Retrieve multiple types of texture coordinates nTypically used as inputs for texture nodes Vector Convert a point
#define output
void determine_canvas(const rcti &preferred_area, rcti &r_area) override
void set_data(const NodeBokehImage *data)
void update_memory_buffer_partial(MemoryBuffer *output, const rcti &area, Span< MemoryBuffer * > inputs) override
a MemoryBuffer contains access to the data
constexpr float COM_BLUR_BOKEH_PIXELS
Definition COM_defines.h:87
VecBase< float, 2 > float2
static blender::bke::bNodeSocketTemplate inputs[]