63 output.allocate_invalid();
76 ResultPrecision::Half);
78 ResultPrecision::Half);
86 flooded_inner_boundary.
release();
87 flooded_outer_boundary.
release();
93 ResultPrecision::Half);
133 flooded_inner_boundary.
bind_as_texture(shader,
"flooded_inner_boundary_tx");
134 flooded_outer_boundary.
bind_as_texture(shader,
"flooded_outer_boundary_tx");
138 output.allocate_texture(domain);
139 output.bind_as_image(shader,
"output_img");
145 output.unbind_as_image();
153 return !bool(
bnode().custom1);
160 return bool(
bnode().custom2);
178 ntype.
declare = file_ns::cmp_node_double_edge_mask_declare;
179 ntype.
draw_buttons = file_ns::node_composit_buts_double_edge_mask;
void GPU_shader_bind(GPUShader *shader)
void GPU_shader_uniform_1b(GPUShader *sh, const char *name, bool value)
void uiItemL(uiLayout *layout, const char *name, int icon)
uiLayout * uiLayoutColumn(uiLayout *layout, bool align)
void uiItemR(uiLayout *layout, PointerRNA *ptr, const char *propname, eUI_Item_Flag flag, const char *name, int icon)
@ UI_ITEM_R_SPLIT_EMPTY_NAME
struct GPUShader GPUShader
int compositor_domain_priority() const
void compute_boundary(Result &inner_boundary, Result &outer_boundary)
bool include_all_inner_edges()
bool include_edges_of_image()
void compute_gradient(Result &flooded_inner_boundary, Result &flooded_outer_boundary)
GPUShader * get_shader(const char *info_name, ResultPrecision precision)
Result create_result(ResultType type, ResultPrecision precision)
NodeOperation(Context &context, DNode node)
const bNode & bnode() const
Result & get_input(StringRef identifier) const
Result & get_result(StringRef identifier)
Context & context() const
virtual Domain compute_domain()
void bind_as_image(GPUShader *shader, const char *image_name, bool read=false) const
void unbind_as_texture() const
void unbind_as_image() const
bool is_single_value() const
void allocate_texture(Domain domain, bool from_pool=true)
void bind_as_texture(GPUShader *shader, const char *texture_name) const
local_group_size(16, 16) .push_constant(Type b
void node_register_type(bNodeType *ntype)
static void cmp_node_double_edge_mask_declare(NodeDeclarationBuilder &b)
static void node_composit_buts_double_edge_mask(uiLayout *layout, bContext *, PointerRNA *ptr)
static NodeOperation * get_compositor_operation(Context &context, DNode node)
void jump_flooding(Context &context, Result &input, Result &output)
void compute_dispatch_threads_at_least(GPUShader *shader, int2 threads_range, int2 local_size=int2(16))
void register_node_type_cmp_doubleedgemask()
void cmp_node_type_base(blender::bke::bNodeType *ntype, int type, const char *name, short nclass)
NodeGetCompositorOperationFunction get_compositor_operation
void(* draw_buttons)(uiLayout *, bContext *C, PointerRNA *ptr)
NodeDeclareFunction declare