Blender
V3.3
|
#include "BLI_linklist.h"
#include "BLI_listbase.h"
#include "BLI_math.h"
#include "BLI_threads.h"
#include <math.h>
Go to the source code of this file.
Classes | |
struct | LineartStaticMemPoolNode |
struct | LineartStaticMemPool |
struct | LineartTriangleAdjacent |
struct | LineartTriangle |
struct | LineartTriangleThread |
struct | LineartElementLinkNode |
struct | LineartEdgeSegment |
struct | LineartShadowEdge |
struct | LineartShadowSegment |
struct | LineartVert |
struct | LineartEdge |
struct | LineartEdgeChain |
struct | LineartEdgeChainItem |
struct | LineartChainRegisterEntry |
struct | LineartAdjacentEdge |
struct | LineartPendingEdges |
struct | LineartData |
struct | LineartData::_qtree |
struct | LineartData::_geom |
struct | LineartData::_conf |
struct | LineartCache |
struct | LineartRenderTaskInfo |
struct | LineartObjectInfo |
struct | LineartObjectLoadTaskInfo |
struct | LineartBoundingArea |
Enumerations | |
enum | eLineArtElementNodeFlag { LRT_ELEMENT_IS_ADDITIONAL = (1 << 0) , LRT_ELEMENT_BORDER_ONLY = (1 << 1) , LRT_ELEMENT_NO_INTERSECTION = (1 << 2) , LRT_ELEMENT_INTERSECTION_DATA = (1 << 3) } |
enum | eLineartShadowSegmentFlag { LRT_SHADOW_CASTED = 1 , LRT_SHADOW_FACING_LIGHT = 2 } |
enum | eLineArtTileRecursiveLimit { LRT_TILE_RECURSIVE_PERSPECTIVE = 16 , LRT_TILE_RECURSIVE_ORTHO = 10 } |
enum | eLineartShadowCameraType { LRT_SHADOW_CAMERA_DIRECTIONAL = 1 , LRT_SHADOW_CAMERA_POINT = 2 } |
enum | eLineartTriangleFlags { LRT_CULL_DONT_CARE = 0 , LRT_CULL_USED = (1 << 0) , LRT_CULL_DISCARD = (1 << 1) , LRT_CULL_GENERATED = (1 << 2) , LRT_TRIANGLE_INTERSECTION_ONLY = (1 << 3) , LRT_TRIANGLE_NO_INTERSECTION = (1 << 4) , LRT_TRIANGLE_MAT_BACK_FACE_CULLING = (1 << 5) , LRT_TRIANGLE_FORCE_INTERSECTION = (1 << 6) } |
Definition at line 432 of file MOD_lineart.h.
Definition at line 586 of file MOD_lineart.h.
Definition at line 431 of file MOD_lineart.h.
#define LRT_CLAMP | ( | a, | |
Min, | |||
Max | |||
) | a = a < Min ? Min : (a > Max ? Max : a) |
Definition at line 576 of file MOD_lineart.h.
#define LRT_CLOSE_LOOSER_v3 | ( | a, | |
b | |||
) |
Definition at line 592 of file MOD_lineart.h.
#define LRT_DOUBLE_CLOSE_ENOUGH | ( | a, | |
b | |||
) | (((a) + DBL_EDGE_LIM) >= (b) && ((a)-DBL_EDGE_LIM) <= (b)) |
Definition at line 588 of file MOD_lineart.h.
#define LRT_DOUBLE_CLOSE_ENOUGH_TRI | ( | a, | |
b | |||
) | (((a) + DBL_TRIANGLE_LIM) >= (b) && ((a)-DBL_TRIANGLE_LIM) <= (b)) |
Definition at line 589 of file MOD_lineart.h.
#define LRT_DOUBLE_CLOSE_LOOSER | ( | a, | |
b | |||
) | (((a) + DBL_LOOSER) >= (b) && ((a)-DBL_LOOSER) <= (b)) |
Definition at line 587 of file MOD_lineart.h.
Definition at line 483 of file MOD_lineart.h.
#define LRT_LIGHT_CONTOUR_TARGET 0xFFFFFFFF |
Definition at line 486 of file MOD_lineart.h.
#define LRT_MAX3_INDEX | ( | a, | |
b, | |||
c | |||
) | (a > b ? (a > c ? 0 : (b > c ? 1 : 2)) : (b > c ? 1 : 2)) |
Definition at line 578 of file MOD_lineart.h.
Definition at line 582 of file MOD_lineart.h.
#define LRT_MEMORY_POOL_1MB (1 << 20) |
Definition at line 434 of file MOD_lineart.h.
#define LRT_MIN3_INDEX | ( | a, | |
b, | |||
c | |||
) | (a < b ? (a < c ? 0 : (b < c ? 1 : 2)) : (b < c ? 1 : 2)) |
Definition at line 580 of file MOD_lineart.h.
Definition at line 584 of file MOD_lineart.h.
#define LRT_OBINDEX_HIGHER 0xFFF00000 /* Higher 12 bits. */ |
Definition at line 482 of file MOD_lineart.h.
#define LRT_OBINDEX_LOWER 0x0FFFFF /* Lower 20 bits. */ |
Definition at line 481 of file MOD_lineart.h.
#define LRT_OBINDEX_SHIFT 20 |
Definition at line 480 of file MOD_lineart.h.
#define LRT_SHADOW_MASK_ENCLOSED_SHAPE (1 << 2) |
Definition at line 450 of file MOD_lineart.h.
#define LRT_SHADOW_MASK_ILLUMINATED (1 << 0) |
Definition at line 448 of file MOD_lineart.h.
#define LRT_SHADOW_MASK_ILLUMINATED_SHAPE (1 << 6) |
Definition at line 454 of file MOD_lineart.h.
#define LRT_SHADOW_MASK_INHIBITED (1 << 3) |
Definition at line 451 of file MOD_lineart.h.
#define LRT_SHADOW_MASK_SHADED (1 << 1) |
Definition at line 449 of file MOD_lineart.h.
#define LRT_SHADOW_MASK_UNDEFINED 0 |
Definition at line 447 of file MOD_lineart.h.
#define LRT_SHADOW_SILHOUETTE_ERASED_GROUP (1 << 4) |
Definition at line 452 of file MOD_lineart.h.
#define LRT_SHADOW_SILHOUETTE_ERASED_OBJECT (1 << 5) |
Definition at line 453 of file MOD_lineart.h.
#define LRT_SHADOW_TEST_SHAPE_BITS |
Definition at line 456 of file MOD_lineart.h.
#define LRT_THREAD_EDGE_COUNT 1000 |
Controls how many edges a worker thread is processing at one request. There's no significant performance impact on choosing different values. Don't make it too small so that the worker thread won't request too many times.
Definition at line 465 of file MOD_lineart.h.
Definition at line 574 of file MOD_lineart.h.
#define LRT_TILE_EDGE_COUNT_INITIAL 32 |
Definition at line 258 of file MOD_lineart.h.
#define LRT_TILE_SPLITTING_TRIANGLE_LIMIT 100 |
Definition at line 257 of file MOD_lineart.h.
#define USE_VECTOR_LINE_INTERSECTION_IGN |
typedef enum eLineArtElementNodeFlag eLineArtElementNodeFlag |
typedef enum eLineartTriangleFlags eLineartTriangleFlags |
typedef struct LineartAdjacentEdge LineartAdjacentEdge |
typedef struct LineartBoundingArea LineartBoundingArea |
Bounding area diagram:
Example structure when subdividing 1 bounding areas: 1 area can be divided into 4 smaller children to accommodate image areas with denser triangle distribution.
lp/rp/up/bp is the list for storing pointers to adjacent bounding areas.
typedef struct LineartCache LineartCache |
typedef struct LineartChainRegisterEntry LineartChainRegisterEntry |
typedef struct LineartData LineartData |
typedef struct LineartEdge LineartEdge |
typedef struct LineartEdgeChain LineartEdgeChain |
typedef struct LineartEdgeChainItem LineartEdgeChainItem |
typedef struct LineartEdgeSegment LineartEdgeSegment |
typedef struct LineartElementLinkNode LineartElementLinkNode |
typedef struct LineartObjectInfo LineartObjectInfo |
typedef struct LineartObjectLoadTaskInfo LineartObjectLoadTaskInfo |
typedef struct LineartPendingEdges LineartPendingEdges |
typedef struct LineartRenderTaskInfo LineartRenderTaskInfo |
typedef struct LineartShadowEdge LineartShadowEdge |
typedef struct LineartShadowSegment LineartShadowSegment |
typedef struct LineartStaticMemPool LineartStaticMemPool |
typedef struct LineartStaticMemPoolNode LineartStaticMemPoolNode |
typedef struct LineartTriangle LineartTriangle |
typedef struct LineartTriangleAdjacent LineartTriangleAdjacent |
typedef struct LineartTriangleThread LineartTriangleThread |
typedef struct LineartVert LineartVert |
Enumerator | |
---|---|
LRT_ELEMENT_IS_ADDITIONAL | |
LRT_ELEMENT_BORDER_ONLY | |
LRT_ELEMENT_NO_INTERSECTION | |
LRT_ELEMENT_INTERSECTION_DATA |
Definition at line 71 of file MOD_lineart.h.
Enumerator | |
---|---|
LRT_SHADOW_CAMERA_DIRECTIONAL | |
LRT_SHADOW_CAMERA_POINT |
Definition at line 260 of file MOD_lineart.h.
Enumerator | |
---|---|
LRT_SHADOW_CASTED | |
LRT_SHADOW_FACING_LIGHT |
Definition at line 122 of file MOD_lineart.h.
Enumerator | |
---|---|
LRT_TILE_RECURSIVE_PERSPECTIVE | |
LRT_TILE_RECURSIVE_ORTHO |
Definition at line 249 of file MOD_lineart.h.
Definition at line 436 of file MOD_lineart.h.
BLI_INLINE int lineart_intersect_seg_seg | ( | const double | a1[2], |
const double | a2[2], | ||
const double | b1[2], | ||
const double | b2[2], | ||
double * | r_ratio, | ||
bool * | r_aligned | ||
) |
Definition at line 608 of file MOD_lineart.h.
References cross_v2v2_db(), fabs(), interpd(), LRT_DOUBLE_CLOSE_ENOUGH, LRT_DOUBLE_CLOSE_ENOUGH_TRI, MAX2, MIN2, ratiod(), sub_v2_v2v2_db(), v, x, and y.
Referenced by lineart_edge_first_bounding_area(), and lineart_triangle_edge_image_space_occlusion().
BLI_INLINE int lineart_line_isec_2d_ignore_line2pos | ( | const double | a1[2], |
const double | a2[2], | ||
const double | b1[2], | ||
const double | b2[2], | ||
double * | r_a_ratio | ||
) |
Definition at line 754 of file MOD_lineart.h.
References cross_v2v2_db(), DBL_EDGE_LIM, fabs(), interpd(), LRT_DOUBLE_CLOSE_ENOUGH, ratiod(), sub_v2_v2v2_db(), v, x, and y.
Referenced by lineart_shadow_cast_onto_triangle().
void MOD_lineart_chain_clear_picked_flag | ( | LineartCache * | lc | ) |
Definition at line 1044 of file lineart_chain.c.
References LineartCache::chains, LISTBASE_FOREACH, and NULL.
Referenced by bake_strokes(), generateStrokes(), and MOD_lineart_compute_feature_lines().
void MOD_lineart_chain_clip_at_border | ( | LineartData * | ld | ) |
Definition at line 1200 of file lineart_chain.c.
References BLI_addhead(), BLI_addtail(), BLI_pophead(), LineartEdgeChain::chain, LineartData::chain_data_pool, LineartData::chains, ListBase::first, is_inside(), ListBase::last, lineart_chain_create_crossing_point(), lineart_mem_acquire(), LRT_ECI_INSIDE, LineartEdgeChainItem::next, NULL, LineartEdgeChain::picked, LineartEdgeChainItem::prev, and swap().
Referenced by MOD_lineart_compute_feature_lines().
float MOD_lineart_chain_compute_length | ( | LineartEdgeChain * | ec | ) |
Length is in image space.
Definition at line 1002 of file lineart_chain.c.
References LineartEdgeChain::chain, copy_v2_v2(), ListBase::first, len_v2v2(), LineartEdgeChainItem::next, and LineartEdgeChainItem::pos.
Referenced by MOD_lineart_chain_discard_unused().
void MOD_lineart_chain_connect | ( | LineartData * | ld | ) |
This function only connects two different chains. It will not do any clean up or smart chaining. So no: removing overlapping chains, removal of short isolated segments, and no loop reduction is implemented yet.
Definition at line 897 of file lineart_chain.c.
References BLI_addtail(), BLI_pophead(), BLI_remlink(), LineartEdgeChain::chain, LineartData::_conf::chaining_image_threshold, LineartData::chains, LineartData::conf, LineartChainRegisterEntry::ec, ListBase::first, LineartEdgeChain::intersection_mask, LineartChainRegisterEntry::is_left, ListBase::last, LineartEdgeChain::level, lineart_bounding_area_get_end_point(), lineart_chain_connect(), lineart_chain_get_closest_cre(), LineartBoundingArea::linked_chains, LineartEdgeChain::loop_id, LRT_EDGE_FLAG_LOOSE, LineartEdgeChain::material_mask_bits, LineartEdgeChain::next, NULL, usdtokens::occlusion(), LineartEdgeChain::picked, LineartChainRegisterEntry::picked, LineartEdgeChain::prev, LineartEdgeChain::shadow_mask_bits, swap(), LineartEdgeChain::type, and LineartData::_conf::use_loose_edge_chain.
Referenced by MOD_lineart_compute_feature_lines().
int MOD_lineart_chain_count | ( | const LineartEdgeChain * | ec | ) |
Definition at line 1035 of file lineart_chain.c.
References LineartEdgeChain::chain, count, and LISTBASE_FOREACH.
Referenced by lineart_gpencil_generate().
void MOD_lineart_chain_discard_unused | ( | LineartData * | ld, |
float | threshold, | ||
uint8_t | max_occlusion | ||
) |
Definition at line 1022 of file lineart_chain.c.
References BLI_remlink(), LineartData::chains, ListBase::first, LineartEdgeChain::level, MOD_lineart_chain_compute_length(), LineartEdgeChain::next, and threshold.
Referenced by MOD_lineart_chain_split_for_fixed_occlusion().
void MOD_lineart_chain_feature_lines | ( | LineartData * | ld | ) |
Definition at line 166 of file lineart_chain.c.
References LineartEdgeChain::chain, LineartData::conf, e, LineartVert::fbcoord, ListBase::first, LineartEdge::flags, LineartData::_conf::fuzzy_everything, LineartVert::gloc, LineartTriangle::gn, LineartVert::index, interp_v3_v3v3_db(), interpf(), LineartEdgeChain::intersection_mask, ListBase::last, LineartEdgeChainItem::line_type, lineart_chain_append_point(), lineart_chain_create(), lineart_chain_prepend_point(), lineart_line_get_connected(), LRT_EDGE_FLAG_ALL_TYPE, LRT_EDGE_FLAG_CHAIN_PICKED, LRT_EDGE_FLAG_CONTOUR, LRT_ITER_ALL_LINES_BEGIN, LRT_ITER_ALL_LINES_END, LRT_ITER_ALL_LINES_NEXT, LineartEdgeSegment::material_mask_bits, LineartEdgeChainItem::material_mask_bits, MOD_lineart_get_bounding_area(), N, LineartEdgeSegment::next, normalize_v3(), LineartEdgeChain::object_ref, LineartEdgeSegment::occlusion, LineartEdgeChainItem::occlusion, POS_TO_FLOAT, LineartEdgeSegment::prev, LineartEdgeSegment::ratio, LineartEdge::segments, LineartEdgeSegment::shadow_mask_bits, LineartEdgeChainItem::shadow_mask_bits, LineartEdge::t1, LineartEdge::t2, LineartEdgeChain::type, LineartEdge::v1, LineartEdge::v2, VERT_COORD_TO_FLOAT, and zero_v3().
Referenced by MOD_lineart_compute_feature_lines().
void MOD_lineart_chain_find_silhouette_backdrop_objects | ( | LineartData * | ld | ) |
Definition at line 1362 of file lineart_chain.c.
References LineartData::chains, LineartData::geom, LineartData::_geom::line_buffer_pointers, lineart_find_matching_eln(), LISTBASE_FOREACH, LRT_EDGE_FLAG_CONTOUR, LRT_OBINDEX_HIGHER, LRT_SHADOW_SILHOUETTE_ERASED_GROUP, and LineartElementLinkNode::object_ref.
Referenced by MOD_lineart_compute_feature_lines().
void MOD_lineart_chain_offset_towards_camera | ( | LineartData * | ld, |
float | dist, | ||
bool | use_custom_camera | ||
) |
Definition at line 1323 of file lineart_chain.c.
References LineartData::_conf::active_camera_pos, add_v3_v3(), LineartData::_conf::cam_is_persp, LineartData::_conf::camera_pos, LineartData::chains, LineartData::conf, copy_v3fl_v3db(), dot_v3v3(), len_v3(), LISTBASE_FOREACH, MIN2, mul_v3_fl(), LineartData::_conf::near_clip, normalize_v3(), normalize_v3_v3(), sub_v3_v3v3(), view, and LineartData::_conf::view_vector.
Referenced by MOD_lineart_compute_feature_lines().
void MOD_lineart_chain_split_angle | ( | LineartData * | ld, |
float | angle_threshold_rad | ||
) |
This should always be the last stage!, see the end of MOD_lineart_chain_split_for_fixed_occlusion().
Definition at line 1266 of file lineart_chain.c.
References angle(), angle_v2v2v2(), BLI_addtail(), BLI_pophead(), LineartEdgeChain::chain, LineartData::chains, ListBase::first, LineartEdgeChainItem::gpos, LineartEdgeChainItem::index, LineartEdgeChain::intersection_mask, ListBase::last, LineartEdgeChain::level, LineartEdgeChainItem::line_type, lineart_chain_append_point(), lineart_chain_create(), LineartEdgeChain::loop_id, M_PI, LineartEdgeChain::material_mask_bits, LineartEdgeChainItem::material_mask_bits, LineartEdgeChain::next, LineartEdgeChainItem::next, LineartEdgeChainItem::normal, NULL, LineartEdgeChain::object_ref, LineartEdgeChainItem::pos, LineartEdgeChain::prev, LineartEdgeChainItem::prev, LineartEdgeChain::shadow_mask_bits, LineartEdgeChainItem::shadow_mask_bits, swap(), and LineartEdgeChain::type.
Referenced by MOD_lineart_compute_feature_lines().
void MOD_lineart_chain_split_for_fixed_occlusion | ( | LineartData * | ld | ) |
Definition at line 645 of file lineart_chain.c.
References BLI_addtail(), BLI_pophead(), LineartEdgeChain::chain, LineartData::_conf::chain_preserve_details, LineartData::_conf::chaining_image_threshold, LineartData::chains, LineartData::conf, DBL_EDGE_LIM, e, ListBase::first, LineartEdgeChainItem::gpos, LineartEdgeChainItem::index, LineartEdgeChain::intersection_mask, ListBase::last, LineartEdgeChain::level, LineartEdgeChainItem::line_type, lineart_bounding_area_link_chain(), lineart_chain_append_point(), lineart_chain_create(), lineart_chain_fix_ambiguous_segments(), lineart_point_overlapping(), LISTBASE_FOREACH, LineartEdgeChain::loop_id, LineartEdgeChain::material_mask_bits, LineartEdgeChainItem::material_mask_bits, LineartData::_conf::max_occlusion_level, MOD_lineart_chain_discard_unused(), LineartEdgeChain::next, LineartEdgeChainItem::next, LineartEdgeChainItem::normal, NULL, LineartEdgeChain::object_ref, LineartEdgeChainItem::occlusion, LineartEdgeChainItem::pos, LineartEdgeChain::prev, LineartEdgeChainItem::prev, LineartEdgeChain::shadow_mask_bits, LineartEdgeChainItem::shadow_mask_bits, swap(), and LineartEdgeChain::type.
Referenced by MOD_lineart_compute_feature_lines().
bool MOD_lineart_compute_feature_lines | ( | Depsgraph * | depsgraph, |
LineartGpencilModifierData * | lmd, | ||
LineartCache ** | cached_result, | ||
bool | enable_stroke_depth_offset | ||
) |
This is the entry point of all line art calculations.
Definition at line 4957 of file lineart_cpu.c.
References LineartData::_conf::angle_splitting_threshold, BKE_scene_camera_switch_update(), LineartGpencilModifierData::calculation_flags, Scene::camera, LineartData::_conf::chain_smooth_tolerance, LineartData::chains, LineartCache::chains, LineartData::conf, DEG_get_evaluated_object(), DEG_get_evaluated_scene(), depsgraph, ListBase::first, LineartGpencilModifierData::flags, G, LineartData::geom, lineart_count_and_print_render_buffer_memory(), lineart_create_render_buffer(), lineart_destroy_render_data_keep_init(), lineart_init_cache(), lineart_main_add_triangles(), lineart_main_bounding_area_make_initial(), lineart_main_bounding_areas_connect_post(), lineart_main_cull_triangles(), lineart_main_discard_out_of_frame_edges(), lineart_main_free_adjacent_data(), lineart_main_get_view_vector(), lineart_main_link_lines(), lineart_main_load_geometries(), lineart_main_make_enclosed_shapes(), lineart_main_occlusion_begin(), lineart_main_perspective_division(), lineart_main_remove_unused_lines_from_tiles(), lineart_main_transform_and_add_shadow(), lineart_main_try_generate_shadow(), lineart_mem_destroy(), lineart_register_intersection_shadow_cuts(), lineart_triangle_size_get(), LRT_ALLOW_DUPLI_OBJECTS, LRT_GPENCIL_OFFSET_TOWARDS_CUSTOM_CAMERA, LRT_USE_CUSTOM_CAMERA, MEM_freeN, MOD_lineart_chain_clear_picked_flag(), MOD_lineart_chain_clip_at_border(), MOD_lineart_chain_connect(), MOD_lineart_chain_feature_lines(), MOD_lineart_chain_find_silhouette_backdrop_objects(), MOD_lineart_chain_offset_towards_camera(), MOD_lineart_chain_split_angle(), MOD_lineart_chain_split_for_fixed_occlusion(), MOD_lineart_finalize_chains(), MOD_lineart_smooth_chains(), NULL, OB_CAMERA, PIL_check_seconds_timer(), scene, LineartCache::shadow_data_pool, LineartCache::shadow_elns, LineartData::_conf::shadow_enclose_shapes, LineartData::_conf::shadow_selection, LineartData::_conf::shadow_use_silhouette, LineartData::sizeof_triangle, LineartGpencilModifierData::source_camera, LineartGpencilModifierData::stroke_depth_offset, Object::type, LineartData::_conf::use_image_boundary_trimming, and LineartData::_geom::vertex_buffer_pointers.
Referenced by bake_strokes(), bakeModifier(), and generateStrokes().
void MOD_lineart_destroy_render_data | ( | struct LineartGpencilModifierData * | lmd | ) |
Definition at line 3517 of file lineart_cpu.c.
References G, LineartGpencilModifierData::la_data_ptr, lineart_destroy_render_data(), MEM_freeN, and NULL.
Referenced by bake_strokes(), bakeModifier(), and generateStrokes().
void MOD_lineart_finalize_chains | ( | LineartData * | ld | ) |
Definition at line 1064 of file lineart_chain.c.
References BLI_assert, LineartData::chains, ELEM, LineartData::geom, LineartElementLinkNode::global_index_offset, LIKELY, lineart_find_matching_eln_obj(), LISTBASE_FOREACH, LRT_EDGE_FLAG_INTERSECTION, LRT_EDGE_FLAG_LIGHT_CONTOUR, LRT_EDGE_FLAG_PROJECTED_SHADOW, NULL, and LineartData::_geom::vertex_buffer_pointers.
Referenced by MOD_lineart_compute_feature_lines().
LineartBoundingArea* MOD_lineart_get_bounding_area | ( | LineartData * | ld, |
double | x, | ||
double | y | ||
) |
Wrapper for more convenience.
Definition at line 4511 of file lineart_cpu.c.
References lineart_get_bounding_area(), MOD_lineart_get_parent_bounding_area(), NULL, x, and y.
Referenced by MOD_lineart_chain_feature_lines().
LineartBoundingArea* MOD_lineart_get_parent_bounding_area | ( | LineartData * | ld, |
double | x, | ||
double | y | ||
) |
This only gets initial "biggest" tile.
Definition at line 4442 of file lineart_cpu.c.
References col, LineartData::_qtree::count_x, LineartData::_qtree::count_y, LineartData::_qtree::initials, LineartData::qtree, LineartData::_qtree::tile_height, LineartData::_qtree::tile_width, x, and y.
Referenced by lineart_bounding_area_get_end_point(), lineart_bounding_area_link_chain(), and MOD_lineart_get_bounding_area().
void MOD_lineart_gpencil_generate | ( | LineartCache * | cache, |
struct Depsgraph * | depsgraph, | ||
struct Object * | ob, | ||
struct bGPDlayer * | gpl, | ||
struct bGPDframe * | gpf, | ||
int8_t | source_type, | ||
void * | source_reference, | ||
int | level_start, | ||
int | level_end, | ||
int | mat_nr, | ||
int16_t | edge_types, | ||
uint8_t | mask_switches, | ||
uint8_t | material_mask_bits, | ||
uint8_t | intersection_mask, | ||
int16_t | thickness, | ||
float | opacity, | ||
uint8_t | shadow_selection, | ||
uint8_t | silhouette_mode, | ||
const char * | source_vgname, | ||
const char * | vgname, | ||
int | modifier_flags, | ||
int | modifier_calculation_flags | ||
) |
Wrapper for external calls.
Definition at line 5368 of file lineart_cpu.c.
References depsgraph, invert_m4_m4(), lineart_gpencil_generate(), LRT_SOURCE_COLLECTION, LRT_SOURCE_OBJECT, NULL, Object::obmat, and usdtokens::opacity().
Referenced by bake_strokes(), and generate_strokes_actual().
void MOD_lineart_smooth_chains | ( | LineartData * | ld, |
float | tolerance | ||
) |
Definition at line 1086 of file lineart_chain.c.
References BLI_listbase_reverse(), BLI_remlink(), LineartData::chains, dist_to_line_segment_v2(), dist_to_line_v2(), dot_v2v2(), len_v2(), LISTBASE_FOREACH, LineartEdgeChainItem::next, normalize_v2_v2(), NULL, LineartEdgeChainItem::pos, and sub_v2_v2v2().
Referenced by MOD_lineart_compute_feature_lines().