Blender V5.3
grease_pencil_trim.cc File Reference
#include "BLI_array.hh"
#include "BLI_bounds.hh"
#include "BLI_lasso_2d.hh"
#include "BLI_rect.hh"
#include "BLI_task.hh"
#include "DNA_brush_types.h"
#include "BKE_brush.hh"
#include "BKE_context.hh"
#include "BKE_crazyspace.hh"
#include "BKE_curves.hh"
#include "BKE_paint.hh"
#include "DEG_depsgraph_query.hh"
#include "ED_grease_pencil.hh"
#include "ED_view3d.hh"
#include "RNA_access.hh"
#include "WM_api.hh"
#include "grease_pencil_segments_intern.hh"

Go to the source code of this file.

Namespaces

namespace  blender
 BMesh Iterators.
namespace  blender::ed
namespace  blender::ed::greasepencil
namespace  blender::ed::greasepencil::trim

Functions

static bool blender::ed::greasepencil::trim::check_line_segment_lasso_intersection (const int2 &pos_a, const int2 &pos_b, const Span< int2 > mcoords)
static void blender::ed::greasepencil::trim::check_segments_in_lasso (const Span< float2 > screen_space_positions, const Span< Bounds< float2 > > screen_space_bbox, const Span< int2 > mcoords, const Span< Segment > all_segments, const IndexMask &editable_curves, const OffsetIndices< int > segments_by_curve, MutableSpan< bool > segments_to_keep)
static bke::CurvesGeometry blender::ed::greasepencil::trim::create_curves_from_segments (const bke::CurvesGeometry &src, const Span< Segment > segments, const Span< bool > segment_reversed, const Span< bool > cyclic, const OffsetIndices< int > segment_offsets)
bke::CurvesGeometry blender::ed::greasepencil::trim::trim_curve_segments (const bke::CurvesGeometry &src, const Span< float2 > screen_space_positions, const Span< int2 > mcoords, const IndexMask &editable_curves, const IndexMask &visible_curves, const bool keep_caps)
bke::CurvesGeometry blender::ed::greasepencil::trim::trim_curve_segment_ends (const bke::CurvesGeometry &src, const Span< float2 > screen_space_positions, const IndexMask &editable_curves, const IndexMask &visible_curves, const bool keep_caps)
static bool blender::ed::greasepencil::execute_trim_on_drawing (const int layer_index, const Object &ob_eval, Object &obact, const ARegion &region, const float4x4 &projection, const Span< int2 > mcoords, const bool keep_caps, bke::greasepencil::Drawing &drawing)
static wmOperatorStatus blender::ed::greasepencil::stroke_trim_execute (const bContext *C, const Span< int2 > mcoords)
static wmOperatorStatus blender::ed::greasepencil::grease_pencil_stroke_trim_exec (bContext *C, wmOperator *op)
C Wrappers
void blender::GREASE_PENCIL_OT_stroke_trim (wmOperatorType *ot)