Blender  V3.3
editlattice_tools.c File Reference
#include "MEM_guardedalloc.h"
#include "BLI_math.h"
#include "BLI_utildefines.h"
#include "DNA_curve_types.h"
#include "DNA_lattice_types.h"
#include "DNA_object_types.h"
#include "DNA_scene_types.h"
#include "RNA_access.h"
#include "RNA_define.h"
#include "BKE_context.h"
#include "BKE_lattice.h"
#include "BKE_layer.h"
#include "DEG_depsgraph.h"
#include "ED_screen.h"
#include "WM_api.h"
#include "WM_types.h"
#include "lattice_intern.h"

Go to the source code of this file.

Functions

Make Regular Operator
static bool make_regular_poll (bContext *C)
 
static int make_regular_exec (bContext *C, wmOperator *UNUSED(op))
 
void LATTICE_OT_make_regular (wmOperatorType *ot)
 

Flip Verts Operator

enum  eLattice_FlipAxes { LATTICE_FLIP_U = 0 , LATTICE_FLIP_V = 1 , LATTICE_FLIP_W = 2 }
 
typedef enum eLattice_FlipAxes eLattice_FlipAxes
 
static void lattice_flip_point_value (Lattice *lt, int u, int v, int w, float mid, eLattice_FlipAxes axis)
 
static void lattice_swap_point_pairs (Lattice *lt, int u, int v, int w, float mid, eLattice_FlipAxes axis)
 
static int lattice_flip_exec (bContext *C, wmOperator *op)
 
void LATTICE_OT_flip (wmOperatorType *ot)
 

Typedef Documentation

◆ eLattice_FlipAxes

Enumeration Type Documentation

◆ eLattice_FlipAxes

Enumerator
LATTICE_FLIP_U 
LATTICE_FLIP_V 
LATTICE_FLIP_W 

Definition at line 114 of file editlattice_tools.c.

Function Documentation

◆ lattice_flip_exec()

static int lattice_flip_exec ( bContext C,
wmOperator op 
)
static

◆ lattice_flip_point_value()

static void lattice_flip_point_value ( Lattice lt,
int  u,
int  v,
int  w,
float  mid,
eLattice_FlipAxes  axis 
)
static

Flip midpoint value so that relative distances between midpoint and neighbor-pair is maintained. Assumes that uvw <=> xyz (i.e. axis-aligned index-axes with coordinate-axes).

Definition at line 125 of file editlattice_tools.c.

References BKE_lattice_index_from_uvw(), Lattice::def, KDL::diff(), v, BPoint::vec, and w().

Referenced by lattice_flip_exec(), and lattice_swap_point_pairs().

◆ LATTICE_OT_flip()

void LATTICE_OT_flip ( wmOperatorType ot)

◆ LATTICE_OT_make_regular()

void LATTICE_OT_make_regular ( wmOperatorType ot)

◆ lattice_swap_point_pairs()

static void lattice_swap_point_pairs ( Lattice lt,
int  u,
int  v,
int  w,
float  mid,
eLattice_FlipAxes  axis 
)
static

◆ make_regular_exec()

static int make_regular_exec ( bContext C,
wmOperator UNUSEDop 
)
static

◆ make_regular_poll()

static bool make_regular_poll ( bContext C)
static