Changeset View
Changeset View
Standalone View
Standalone View
source/blender/gpencil_modifiers/intern/lineart/MOD_lineart.h
| /* SPDX-License-Identifier: GPL-2.0-or-later | /* SPDX-License-Identifier: GPL-2.0-or-later | ||||
| * Copyright 2008 Blender Foundation. All rights reserved. */ | * Copyright 2008 Blender Foundation. All rights reserved. */ | ||||
| /** \file | /** \file | ||||
| * \ingroup editors | * \ingroup editors | ||||
| */ | */ | ||||
| #pragma once | #pragma once | ||||
| #include "BLI_linklist.h" | #include "BLI_linklist.h" | ||||
| #include "BLI_listbase.h" | #include "BLI_listbase.h" | ||||
| #include "BLI_math.h" /* Needed here for inline functions. */ | #include "BLI_math.h" /* Needed here for inline functions. */ | ||||
| #include "BLI_threads.h" | #include "BLI_threads.h" | ||||
| #include <math.h> | #include <math.h> | ||||
| #ifdef __cplusplus | |||||
| extern "C" { | |||||
| #endif | |||||
| typedef struct LineartStaticMemPoolNode { | typedef struct LineartStaticMemPoolNode { | ||||
| Link item; | Link item; | ||||
| size_t size; | size_t size; | ||||
| size_t used_byte; | size_t used_byte; | ||||
| /* User memory starts here */ | /* User memory starts here */ | ||||
| } LineartStaticMemPoolNode; | } LineartStaticMemPoolNode; | ||||
| typedef struct LineartStaticMemPool { | typedef struct LineartStaticMemPool { | ||||
| ▲ Show 20 Lines • Show All 44 Lines • ▼ Show 20 Lines | |||||
| } LineartTriangleThread; | } LineartTriangleThread; | ||||
| typedef enum eLineArtElementNodeFlag { | typedef enum eLineArtElementNodeFlag { | ||||
| LRT_ELEMENT_IS_ADDITIONAL = (1 << 0), | LRT_ELEMENT_IS_ADDITIONAL = (1 << 0), | ||||
| LRT_ELEMENT_BORDER_ONLY = (1 << 1), | LRT_ELEMENT_BORDER_ONLY = (1 << 1), | ||||
| LRT_ELEMENT_NO_INTERSECTION = (1 << 2), | LRT_ELEMENT_NO_INTERSECTION = (1 << 2), | ||||
| LRT_ELEMENT_INTERSECTION_DATA = (1 << 3), | LRT_ELEMENT_INTERSECTION_DATA = (1 << 3), | ||||
| } eLineArtElementNodeFlag; | } eLineArtElementNodeFlag; | ||||
| ENUM_OPERATORS(eLineArtElementNodeFlag, LRT_ELEMENT_INTERSECTION_DATA); | |||||
| typedef struct LineartElementLinkNode { | typedef struct LineartElementLinkNode { | ||||
| struct LineartElementLinkNode *next, *prev; | struct LineartElementLinkNode *next, *prev; | ||||
| void *pointer; | void *pointer; | ||||
| int element_count; | int element_count; | ||||
| void *object_ref; | void *object_ref; | ||||
| eLineArtElementNodeFlag flags; | eLineArtElementNodeFlag flags; | ||||
| ▲ Show 20 Lines • Show All 839 Lines • ▼ Show 20 Lines | void MOD_lineart_gpencil_generate(LineartCache *cache, | ||||
| int modifier_flags); | int modifier_flags); | ||||
| /** | /** | ||||
| * Length is in image space. | * Length is in image space. | ||||
| */ | */ | ||||
| float MOD_lineart_chain_compute_length(LineartEdgeChain *ec); | float MOD_lineart_chain_compute_length(LineartEdgeChain *ec); | ||||
| void ED_operatortypes_lineart(void); | void ED_operatortypes_lineart(void); | ||||
| #ifdef __cplusplus | |||||
| } | |||||
| #endif | |||||