Blender V4.3
blender::ed::greasepencil::DrawingPlacement Class Reference

#include <ED_grease_pencil.hh>

Public Member Functions

 DrawingPlacement ()=default
 
 DrawingPlacement (const Scene &scene, const ARegion &region, const View3D &view3d, const Object &eval_object, const bke::greasepencil::Layer *layer)
 
 DrawingPlacement (const Scene &scene, const ARegion &region, const View3D &view3d, const Object &eval_object, const bke::greasepencil::Layer *layer, ReprojectMode reproject_mode, float surface_offset=0.0f, ViewDepths *view_depths=nullptr)
 
 DrawingPlacement (const DrawingPlacement &other)
 
 DrawingPlacement (DrawingPlacement &&other)
 
DrawingPlacementoperator= (const DrawingPlacement &other)
 
DrawingPlacementoperator= (DrawingPlacement &&other)
 
 ~DrawingPlacement ()
 
bool use_project_to_surface () const
 
bool use_project_to_nearest_stroke () const
 
void cache_viewport_depths (Depsgraph *depsgraph, ARegion *region, View3D *view3d)
 
void set_origin_to_nearest_stroke (float2 co)
 
float3 project (float2 co) const
 
void project (Span< float2 > src, MutableSpan< float3 > dst) const
 
float3 reproject (float3 pos) const
 
void reproject (Span< float3 > src, MutableSpan< float3 > dst) const
 
float4x4 to_world_space () const
 

Detailed Description

Definition at line 118 of file ED_grease_pencil.hh.

Constructor & Destructor Documentation

◆ DrawingPlacement() [1/5]

blender::ed::greasepencil::DrawingPlacement::DrawingPlacement ( )
default

Referenced by operator=(), and operator=().

◆ DrawingPlacement() [2/5]

◆ DrawingPlacement() [3/5]

blender::ed::greasepencil::DrawingPlacement::DrawingPlacement ( const Scene & scene,
const ARegion & region,
const View3D & view3d,
const Object & eval_object,
const bke::greasepencil::Layer * layer,
ReprojectMode reproject_mode,
float surface_offset = 0.0f,
ViewDepths * view_depths = nullptr )

◆ DrawingPlacement() [4/5]

blender::ed::greasepencil::DrawingPlacement::DrawingPlacement ( const DrawingPlacement & other)

Definition at line 196 of file grease_pencil_utils.cc.

References ViewDepths::depths, and MEM_dupallocN.

◆ DrawingPlacement() [5/5]

blender::ed::greasepencil::DrawingPlacement::DrawingPlacement ( DrawingPlacement && other)

Definition at line 220 of file grease_pencil_utils.cc.

◆ ~DrawingPlacement()

blender::ed::greasepencil::DrawingPlacement::~DrawingPlacement ( )

Definition at line 261 of file grease_pencil_utils.cc.

References ED_view3d_depths_free().

Member Function Documentation

◆ cache_viewport_depths()

void blender::ed::greasepencil::DrawingPlacement::cache_viewport_depths ( Depsgraph * depsgraph,
ARegion * region,
View3D * view3d )

◆ operator=() [1/2]

DrawingPlacement & blender::ed::greasepencil::DrawingPlacement::operator= ( const DrawingPlacement & other)

Definition at line 241 of file grease_pencil_utils.cc.

References DrawingPlacement().

◆ operator=() [2/2]

DrawingPlacement & blender::ed::greasepencil::DrawingPlacement::operator= ( DrawingPlacement && other)

Definition at line 251 of file grease_pencil_utils.cc.

References DrawingPlacement().

◆ project() [1/2]

◆ project() [2/2]

void blender::ed::greasepencil::DrawingPlacement::project ( Span< float2 > src,
MutableSpan< float3 > dst ) const

◆ reproject() [1/2]

float3 blender::ed::greasepencil::DrawingPlacement::reproject ( float3 pos) const

◆ reproject() [2/2]

void blender::ed::greasepencil::DrawingPlacement::reproject ( Span< float3 > src,
MutableSpan< float3 > dst ) const

◆ set_origin_to_nearest_stroke()

◆ to_world_space()

◆ use_project_to_nearest_stroke()

bool blender::ed::greasepencil::DrawingPlacement::use_project_to_nearest_stroke ( ) const

◆ use_project_to_surface()

bool blender::ed::greasepencil::DrawingPlacement::use_project_to_surface ( ) const

The documentation for this class was generated from the following files: