Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/space_node/node_intern.h
| Show All 31 Lines | |||||
| struct ARegion; | struct ARegion; | ||||
| struct ARegionType; | struct ARegionType; | ||||
| struct Main; | struct Main; | ||||
| struct View2D; | struct View2D; | ||||
| struct bContext; | struct bContext; | ||||
| struct bNode; | struct bNode; | ||||
| struct bNodeLink; | struct bNodeLink; | ||||
| struct bNodeSocket; | struct bNodeSocket; | ||||
| struct NodeInsertOfsData; | |||||
| struct wmGizmoGroupType; | struct wmGizmoGroupType; | ||||
| struct wmKeyConfig; | struct wmKeyConfig; | ||||
| struct wmWindow; | struct wmWindow; | ||||
| /* temp data to pass on to modal */ | /* temp data to pass on to modal */ | ||||
| typedef struct bNodeLinkDrag { | typedef struct bNodeLinkDrag { | ||||
| struct bNodeLinkDrag *next, *prev; | struct bNodeLinkDrag *next, *prev; | ||||
| /* List of links dragged by the operator. | /* List of links dragged by the operator. | ||||
| * Note: This is a list of LinkData structs on top of the actual bNodeLinks. | * Note: This is a list of LinkData structs on top of the actual bNodeLinks. | ||||
| * This way the links can be added to the node tree while being stored in this list. | * This way the links can be added to the node tree while being stored in this list. | ||||
| */ | */ | ||||
| ListBase links; | ListBase links; | ||||
| bool from_multi_input_socket; | |||||
| int in_out; | int in_out; | ||||
| } bNodeLinkDrag; | } bNodeLinkDrag; | ||||
| typedef struct SpaceNode_Runtime { | |||||
| float aspect; | |||||
| /** Mouse position for drawing socket-less links and adding nodes. */ | |||||
| float cursor[2]; | |||||
| /** For auto compositing. */ | |||||
| bool recalc; | |||||
| /** Temporary data for modal linking operator. */ | |||||
| struct ListBase linkdrag; | |||||
| /* XXX hack for translate_attach op-macros to pass data from transform op to insert_offset op */ | |||||
| /** Temporary data for node insert offset (in UI called Auto-offset). */ | |||||
| struct NodeInsertOfsData *iofsd; | |||||
| } SpaceNode_Runtime; | |||||
| /* space_node.c */ | /* space_node.c */ | ||||
| /* transform between View2Ds in the tree path */ | /* transform between View2Ds in the tree path */ | ||||
| void space_node_group_offset(struct SpaceNode *snode, float *x, float *y); | void space_node_group_offset(struct SpaceNode *snode, float *x, float *y); | ||||
| /* node_draw.c */ | /* node_draw.c */ | ||||
| int node_get_colorid(struct bNode *node); | int node_get_colorid(struct bNode *node); | ||||
| int node_get_resize_cursor(int directions); | int node_get_resize_cursor(int directions); | ||||
| void node_draw_shadow(struct SpaceNode *snode, struct bNode *node, float radius, float alpha); | void node_draw_shadow(const struct SpaceNode *snode, | ||||
| const struct bNode *node, | |||||
| float radius, | |||||
| float alpha); | |||||
| void node_draw_default(const struct bContext *C, | void node_draw_default(const struct bContext *C, | ||||
| struct ARegion *region, | struct ARegion *region, | ||||
| struct SpaceNode *snode, | struct SpaceNode *snode, | ||||
| struct bNodeTree *ntree, | struct bNodeTree *ntree, | ||||
| struct bNode *node, | struct bNode *node, | ||||
| bNodeInstanceKey key); | bNodeInstanceKey key); | ||||
| void node_draw_sockets(struct View2D *v2d, | void node_draw_sockets(const struct View2D *v2d, | ||||
| const struct bContext *C, | const struct bContext *C, | ||||
| struct bNodeTree *ntree, | struct bNodeTree *ntree, | ||||
| struct bNode *node, | struct bNode *node, | ||||
| bool draw_outputs, | bool draw_outputs, | ||||
| bool select_all); | bool select_all); | ||||
| void node_update_default(const struct bContext *C, struct bNodeTree *ntree, struct bNode *node); | void node_update_default(const struct bContext *C, struct bNodeTree *ntree, struct bNode *node); | ||||
| int node_select_area_default(struct bNode *node, int x, int y); | int node_select_area_default(struct bNode *node, int x, int y); | ||||
| int node_tweak_area_default(struct bNode *node, int x, int y); | int node_tweak_area_default(struct bNode *node, int x, int y); | ||||
| void node_socket_color_get(struct bContext *C, | void node_socket_color_get(struct bContext *C, | ||||
| struct bNodeTree *ntree, | struct bNodeTree *ntree, | ||||
| struct PointerRNA *node_ptr, | struct PointerRNA *node_ptr, | ||||
| struct bNodeSocket *sock, | struct bNodeSocket *sock, | ||||
| float r_color[4]); | float r_color[4]); | ||||
| void node_update_nodetree(const struct bContext *C, struct bNodeTree *ntree); | void node_update_nodetree(const struct bContext *C, struct bNodeTree *ntree); | ||||
| void node_draw_nodetree(const struct bContext *C, | void node_draw_nodetree(const struct bContext *C, | ||||
| struct ARegion *region, | struct ARegion *region, | ||||
| struct SpaceNode *snode, | struct SpaceNode *snode, | ||||
| struct bNodeTree *ntree, | struct bNodeTree *ntree, | ||||
| bNodeInstanceKey parent_key); | bNodeInstanceKey parent_key); | ||||
| void node_draw_space(const bContext *C, ARegion *region); | void node_draw_space(const bContext *C, ARegion *region); | ||||
| void node_set_cursor(struct wmWindow *win, struct SpaceNode *snode, float cursor[2]); | void node_set_cursor(struct wmWindow *win, struct SpaceNode *snode, float cursor[2]); | ||||
| /* DPI scaled coords */ | /* DPI scaled coords */ | ||||
| void node_to_view(struct bNode *node, float x, float y, float *rx, float *ry); | void node_to_view(const struct bNode *node, float x, float y, float *rx, float *ry); | ||||
| void node_to_updated_rect(struct bNode *node, rctf *r_rect); | void node_to_updated_rect(const struct bNode *node, rctf *r_rect); | ||||
| void node_from_view(struct bNode *node, float x, float y, float *rx, float *ry); | void node_from_view(const struct bNode *node, float x, float y, float *rx, float *ry); | ||||
| /* node_buttons.c */ | /* node_buttons.c */ | ||||
| void node_buttons_register(struct ARegionType *art); | void node_buttons_register(struct ARegionType *art); | ||||
| /* node_toolbar.c */ | /* node_toolbar.c */ | ||||
| void node_toolbar_register(struct ARegionType *art); | void node_toolbar_register(struct ARegionType *art); | ||||
| /* node_ops.c */ | /* node_ops.c */ | ||||
| Show All 34 Lines | |||||
| void NODE_OT_backimage_fit(struct wmOperatorType *ot); | void NODE_OT_backimage_fit(struct wmOperatorType *ot); | ||||
| void NODE_OT_backimage_sample(struct wmOperatorType *ot); | void NODE_OT_backimage_sample(struct wmOperatorType *ot); | ||||
| /* drawnode.c */ | /* drawnode.c */ | ||||
| void nodelink_batch_start(struct SpaceNode *snode); | void nodelink_batch_start(struct SpaceNode *snode); | ||||
| void nodelink_batch_end(struct SpaceNode *snode); | void nodelink_batch_end(struct SpaceNode *snode); | ||||
| void node_draw_link(struct View2D *v2d, struct SpaceNode *snode, struct bNodeLink *link); | void node_draw_link(struct View2D *v2d, struct SpaceNode *snode, struct bNodeLink *link); | ||||
| void node_draw_link_bezier(struct View2D *v2d, | void node_draw_link_bezier(const struct View2D *v2d, | ||||
| struct SpaceNode *snode, | const struct SpaceNode *snode, | ||||
| struct bNodeLink *link, | const struct bNodeLink *link, | ||||
| int th_col1, | int th_col1, | ||||
| int th_col2, | int th_col2, | ||||
| int th_col3); | int th_col3); | ||||
| bool node_link_bezier_points(struct View2D *v2d, | bool node_link_bezier_points(const struct View2D *v2d, | ||||
| struct SpaceNode *snode, | const struct SpaceNode *snode, | ||||
| struct bNodeLink *link, | const struct bNodeLink *link, | ||||
| float coord_array[][2], | float coord_array[][2], | ||||
| int resol); | const int resol); | ||||
| void draw_nodespace_back_pix(const struct bContext *C, | void draw_nodespace_back_pix(const struct bContext *C, | ||||
| struct ARegion *region, | struct ARegion *region, | ||||
| struct SpaceNode *snode, | struct SpaceNode *snode, | ||||
| bNodeInstanceKey parent_key); | bNodeInstanceKey parent_key); | ||||
| /* node_add.c */ | /* node_add.c */ | ||||
| bNode *node_add_node( | bNode *node_add_node( | ||||
| const struct bContext *C, const char *idname, int type, float locx, float locy); | const struct bContext *C, const char *idname, int type, float locx, float locy); | ||||
| ▲ Show 20 Lines • Show All 126 Lines • Show Last 20 Lines | |||||