|
Blender V4.3
|
Go to the source code of this file.
Classes | |
| struct | GP_SpaceConversion |
Macros | |
| #define | DEPTH_INVALID 1.0f |
| #define | GP_STROKE_BUFFER_CHUNK 2048 |
Enumerations | |
| enum | eGPencil_PaintModes { GP_PAINTMODE_DRAW = 0 , GP_PAINTMODE_ERASER , GP_PAINTMODE_DRAW_STRAIGHT , GP_PAINTMODE_DRAW_POLY , GP_PAINTMODE_SET_CP } |
Functions | |
| bool | gpencil_stroke_inside_circle (const float mval[2], int rad, int x0, int y0, int x1, int y1) |
| void | gpencil_point_to_xy (const GP_SpaceConversion *gsc, const bGPDstroke *gps, const bGPDspoint *pt, int *r_x, int *r_y) |
| void | GPENCIL_OT_annotate (wmOperatorType *ot) |
| void | GPENCIL_OT_annotation_add (wmOperatorType *ot) |
| void | GPENCIL_OT_data_unlink (wmOperatorType *ot) |
| void | GPENCIL_OT_layer_annotation_add (wmOperatorType *ot) |
| void | GPENCIL_OT_layer_annotation_remove (wmOperatorType *ot) |
| void | GPENCIL_OT_layer_annotation_move (wmOperatorType *ot) |
| void | GPENCIL_OT_annotation_active_frame_delete (wmOperatorType *ot) |
| void | gpencil_undo_init (bGPdata *gpd) |
| void | gpencil_undo_push (bGPdata *gpd) |
| void | gpencil_undo_finish () |
Variables | |
| ListBase | gpencil_strokes_copypastebuf |
| #define DEPTH_INVALID 1.0f |
Definition at line 15 of file gpencil_intern.hh.
| #define GP_STROKE_BUFFER_CHUNK 2048 |
Definition at line 123 of file gpencil_intern.hh.
Referenced by ED_gpencil_sbuffer_ensure().
| enum eGPencil_PaintModes |
| Enumerator | |
|---|---|
| GP_PAINTMODE_DRAW | |
| GP_PAINTMODE_ERASER | |
| GP_PAINTMODE_DRAW_STRAIGHT | |
| GP_PAINTMODE_DRAW_POLY | |
| GP_PAINTMODE_SET_CP | |
Definition at line 114 of file gpencil_intern.hh.
| void GPENCIL_OT_annotate | ( | wmOperatorType * | ot | ) |
Definition at line 2792 of file annotate_paint.cc.
References annotation_draw_cancel(), annotation_draw_exec(), annotation_draw_invoke(), annotation_draw_modal(), annotation_draw_poll(), arrow_types, wmOperatorType::cancel, wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, wmOperatorType::idname, wmOperatorType::invoke, wmOperatorType::modal, wmOperatorType::name, OPTYPE_BLOCKING, OPTYPE_UNDO, ot, wmOperatorType::poll, wmOperatorType::prop, prop_gpencil_drawmodes, PROP_HIDDEN, PROP_PIXEL, PROP_SKIP_SAVE, RNA_def_boolean(), RNA_def_collection_runtime(), RNA_def_enum(), RNA_def_float(), RNA_def_int(), RNA_def_property_flag(), RNA_def_property_subtype(), and wmOperatorType::srna.
Referenced by ED_operatortypes_gpencil_legacy().
| void GPENCIL_OT_annotation_active_frame_delete | ( | wmOperatorType * | ot | ) |
Definition at line 181 of file gpencil_edit.cc.
References annotation_actframe_delete_poll(), wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, gpencil_actframe_delete_exec(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, ot, and wmOperatorType::poll.
Referenced by ED_operatortypes_gpencil_legacy().
| void GPENCIL_OT_annotation_add | ( | wmOperatorType * | ot | ) |
Definition at line 121 of file gpencil_data.cc.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, gpencil_data_add_exec(), gpencil_data_add_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, ot, and wmOperatorType::poll.
Referenced by ED_operatortypes_gpencil_legacy().
| void GPENCIL_OT_data_unlink | ( | wmOperatorType * | ot | ) |
Definition at line 173 of file gpencil_data.cc.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, gpencil_data_unlink_exec(), gpencil_data_unlink_poll(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, ot, and wmOperatorType::poll.
Referenced by ED_operatortypes_gpencil_legacy().
| void GPENCIL_OT_layer_annotation_add | ( | wmOperatorType * | ot | ) |
Definition at line 256 of file gpencil_data.cc.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, gpencil_add_annotation_poll(), gpencil_layer_add_exec(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, ot, and wmOperatorType::poll.
Referenced by ED_operatortypes_gpencil_legacy().
| void GPENCIL_OT_layer_annotation_move | ( | wmOperatorType * | ot | ) |
Definition at line 380 of file gpencil_data.cc.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, GP_LAYER_MOVE_DOWN, GP_LAYER_MOVE_UP, gpencil_active_layer_annotation_poll(), gpencil_layer_move_exec(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, ot, wmOperatorType::poll, wmOperatorType::prop, RNA_def_enum(), and wmOperatorType::srna.
Referenced by ED_operatortypes_gpencil_legacy().
| void GPENCIL_OT_layer_annotation_remove | ( | wmOperatorType * | ot | ) |
Definition at line 333 of file gpencil_data.cc.
References wmOperatorType::description, wmOperatorType::exec, wmOperatorType::flag, gpencil_active_layer_annotation_poll(), gpencil_layer_remove_exec(), wmOperatorType::idname, wmOperatorType::name, OPTYPE_REGISTER, OPTYPE_UNDO, ot, and wmOperatorType::poll.
Referenced by ED_operatortypes_gpencil_legacy().
| void gpencil_point_to_xy | ( | const GP_SpaceConversion * | gsc, |
| const bGPDstroke * | gps, | ||
| const bGPDspoint * | pt, | ||
| int * | r_x, | ||
| int * | r_y ) |
Convert a Grease Pencil coordinate (i.e. can be 2D or 3D) to screen-space (2D)
| [out] | r_x | The screen-space x-coordinate of the point |
| [out] | r_y | The screen-space y-coordinate of the point |
Definition at line 332 of file gpencil_utils.cc.
References GP_SpaceConversion::area, BLI_assert, BLI_rctf_size_x(), BLI_rctf_size_y(), ED_view3d_project_int_global(), bGPDstroke::flag, GP_STROKE_2DSPACE, GP_STROKE_3DSPACE, int, GP_SpaceConversion::mat, mul_m4_v3(), GP_SpaceConversion::region, SPACE_VIEW3D, ScrArea::spacetype, GP_SpaceConversion::subrect, UI_view2d_view_to_region_clip(), GP_SpaceConversion::v2d, V2D_IS_CLIPPED, V3D_PROJ_RET_OK, V3D_PROJ_TEST_NOP, bGPDspoint::x, rctf::xmin, bGPDspoint::y, and rctf::ymin.
Referenced by annotation_stroke_eraser_dostroke().
Check whether a given stroke segment is inside a circular brush
| mval | The current screen-space coordinates (midpoint) of the brush |
| rad | The radius of the brush |
| x0,y0 | The screen-space x and y coordinates of the start of the stroke segment |
| x1,y1 | The screen-space x and y coordinates of the end of the stroke segment |
Definition at line 265 of file gpencil_utils.cc.
References edge_inside_circle(), and float.
Referenced by annotation_stroke_eraser_dostroke().
| void gpencil_undo_finish | ( | ) |
Definition at line 164 of file gpencil_undo.cc.
References BLI_freelistN(), cur_node, ListBase::first, gpencil_undo_free_node(), bGPundonode::next, and undo_nodes.
Referenced by annotation_draw_exit().
| void gpencil_undo_init | ( | bGPdata * | gpd | ) |
Definition at line 97 of file gpencil_undo.cc.
References gpencil_undo_push().
Referenced by annotation_session_initdata().
| void gpencil_undo_push | ( | bGPdata * | gpd | ) |
Definition at line 113 of file gpencil_undo.cc.
References BKE_gpencil_data_duplicate(), BLI_addtail(), BLI_freelinkN(), BLI_listbase_is_empty(), cur_node, bGPundonode::gpd, gpencil_undo_free_node(), ListBase::last, bGPundonode::next, bGPundonode::prev, steps, and undo_nodes.
Referenced by annotation_stroke_end(), and gpencil_undo_init().
|
extern |
list of bGPDstroke instances
Definition at line 92 of file gpencil_edit.cc.
Referenced by ED_gpencil_strokes_copybuf_free().