95 # define GP_DRAWTHICKNESS_SPECIAL 3
99 #define F2UB(x) (uchar)(255.0f * x)
109 float alpha = ink[3] * pt->
strength;
110 if ((fix_strength) && (alpha >= 0.1f)) {
136 for (
int i = 0; i < totpoints && pt; i++, pt++) {
160 const float viewport[2] = {(
float)tgpw->
winx, (
float)tgpw->
winy};
161 const float min_thickness = 0.05f;
166 int cyclic_add = (cyclic) ? 1 : 0;
180 float obj_scale = tgpw->
ob ?
187 gpencil_stroke_data.
objscale = obj_scale;
205 for (
int i = 0; i < totpoints; i++, pt++) {
210 if ((cyclic) && (totpoints > 2)) {
212 max_ff((points + totpoints - 1)->pressure * thickness, min_thickness));
228 if (cyclic && totpoints > 2) {
300 const bool is_unique = (tgpw->
gps !=
NULL);
301 const bool use_mat = (tgpw->
gpd->
mat !=
NULL);
333 sthickness = gps->thickness + tgpw->
lthick;
336 sthickness = (short)
max_ii(1, sthickness / 2);
339 if (sthickness <= 0) {
387 if (gps->totpoints > 1) {
typedef float(TangentPoint)[2]
#define GPENCIL_ALPHA_OPACITY_THRESH
#define GPENCIL_STRENGTH_MIN
General operations, lookup, etc. for materials.
struct Material * BKE_material_default_gpencil(void)
MINLINE float max_ff(float a, float b)
MINLINE int max_ii(int a, int b)
void mul_v3_m4v3(float r[3], const float M[4][4], const float v[3])
MINLINE void copy_v4_v4(float r[4], const float a[4])
MINLINE void copy_v2_v2(float r[2], const float a[2])
void interp_v3_v3v3(float r[3], const float a[3], const float b[3], float t)
#define ARRAY_SET_ITEMS(...)
@ GP_DATA_STROKE_KEEPTHICKNESS
@ GP_MATERIAL_HIDE_ONIONSKIN
Object is a sort of wrapper for general info.
void GPU_polygon_offset(float viewdist, float dist)
@ GPU_PRIM_LINE_STRIP_ADJ
@ GPU_SHADER_GPENCIL_STROKE
@ GPU_SHADER_3D_POINT_VARYING_SIZE_VARYING_COLOR
void GPU_program_point_size(bool enable)
void GPU_depth_mask(bool depth)
bool GPU_depth_mask_get(void)
void GPU_depth_test(eGPUDepthTest test)
Contains defines and structs used throughout the imbuf module.
Read Guarded memory(de)allocation.
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Bright Control the brightness and contrast of the input color Vector Map an input vectors to used to fine tune the interpolation of the input Camera Retrieve information about the camera and how it relates to the current shading point s position CLAMP
Group Output data from inside of a node group A color picker Mix two input colors RGB to Convert a color s luminance to a grayscale value Generate a normal vector and a dot product Bright Control the brightness and contrast of the input color Vector Map an input vectors to used to fine tune the interpolation of the input Camera Retrieve information about the camera and how it relates to the current shading point s position Clamp a value between a minimum and a maximum Vector Perform vector math operation Invert a color
static DBVT_INLINE btScalar size(const btDbvtVolume &a)
static void gpencil_draw_stroke_3d(tGPDdraw *tgpw, short thickness, const float ink[4], bool cyclic)
static bool gpencil_can_draw_stroke(const bGPDstroke *gps, const int dflag)
static void gpencil_draw_stroke_volumetric_3d(const bGPDspoint *points, int totpoints, short thickness, const float ink[4])
static void gpencil_set_point_varying_color(const bGPDspoint *pt, const float ink[4], uint attr_id, bool fix_strength)
static void gpencil_draw_strokes(tGPDdraw *tgpw)
void ED_gpencil_draw_fill(tGPDdraw *tgpw)
struct @653::@656 attr_id
struct MaterialGPencilStyle * gp_style
struct RegionView3D * rv3d