Blender  V3.3
COM_VectorBlurOperation.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later
2  * Copyright 2011 Blender Foundation. */
3 
4 #pragma once
5 
6 #include "COM_NodeOperation.h"
8 #include "DNA_node_types.h"
9 
10 namespace blender::compositor {
11 
13  private:
14  static constexpr int IMAGE_INPUT_INDEX = 0;
15  static constexpr int Z_INPUT_INDEX = 1;
16  static constexpr int SPEED_INPUT_INDEX = 2;
17 
21  SocketReader *input_image_program_;
22  SocketReader *input_speed_program_;
23  SocketReader *input_zprogram_;
24 
28  NodeBlurData *settings_;
29 
30  float *cached_instance_;
31 
32  public:
34 
38  void execute_pixel(float output[4], int x, int y, void *data) override;
39 
43  void init_execution() override;
44 
48  void deinit_execution() override;
49 
50  void *initialize_tile_data(rcti *rect) override;
51 
53  {
54  settings_ = settings;
55  }
57  ReadBufferOperation *read_operation,
58  rcti *output) override;
59 
60  void get_area_of_interest(int input_idx, const rcti &output_area, rcti &r_input_area) override;
62  const rcti &area,
63  Span<MemoryBuffer *> inputs) override;
64 
65  protected:
66  void generate_vector_blur(float *data,
67  MemoryBuffer *input_image,
68  MemoryBuffer *input_speed,
69  MemoryBuffer *inputZ);
70 };
71 
72 } // namespace blender::compositor
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint y
a MemoryBuffer contains access to the data of a chunk
NodeOperation contains calculation logic.
void execute_pixel(float output[4], int x, int y, void *data) override
void set_vector_blur_settings(NodeBlurData *settings)
void update_memory_buffer(MemoryBuffer *output, const rcti &area, Span< MemoryBuffer * > inputs) override
void get_area_of_interest(int input_idx, const rcti &output_area, rcti &r_input_area) override
Get input operation area being read by this operation on rendering given output area.
bool determine_depending_area_of_interest(rcti *input, ReadBufferOperation *read_operation, rcti *output) override
void generate_vector_blur(float *data, MemoryBuffer *input_image, MemoryBuffer *input_speed, MemoryBuffer *inputZ)
ccl_global KernelShaderEvalInput ccl_global float * output
ccl_global KernelShaderEvalInput * input
static void area(int d1, int d2, int e1, int e2, float weights[2])
static bNodeSocketTemplate inputs[]