[Bf-blender-cvs] [83e2b73ddee] temp-lineart-contained: Merge remote-tracking branch 'origin/master' into temp-lineart-contained

YimingWu noreply at git.blender.org
Wed Jun 16 17:17:35 CEST 2021


Commit: 83e2b73ddeee9c03084cc08a865a70b53eb5a863
Author: YimingWu
Date:   Wed Jun 16 22:47:10 2021 +0800
Branches: temp-lineart-contained
https://developer.blender.org/rB83e2b73ddeee9c03084cc08a865a70b53eb5a863

Merge remote-tracking branch 'origin/master' into temp-lineart-contained

===================================================================



===================================================================

diff --cc source/blender/gpencil_modifiers/intern/lineart/MOD_lineart.h
index b242a82a593,b6175762bbe..271d16e04c0
--- a/source/blender/gpencil_modifiers/intern/lineart/MOD_lineart.h
+++ b/source/blender/gpencil_modifiers/intern/lineart/MOD_lineart.h
@@@ -339,13 -318,11 +339,11 @@@ typedef struct LineartCache 
     * chains will still be available. */
    LineartStaticMemPool chain_data_pool;
  
 -  /** A copy of rb->chains so we have that data available after rb has been destroyed. */
 +  /** A copy of rb->Chains after calculation is done, then we can destroy rb. */
    ListBase chains;
  
-   /** Cache only contains edge types specified in this variable.
-    * TODO: it's a fixed value (LRT_EDGE_FLAG_ALL_TYPE) right now, allow further selections in the
-    * future. */
+   /** Cache only contains edge types specified in this variable. */
 -  char rb_edge_types;
 +  unsigned char rb_edge_types;
  } LineartCache;
  
  #define DBL_TRIANGLE_LIM 1e-8
diff --cc source/blender/makesdna/DNA_gpencil_modifier_types.h
index 785c6078bbe,3977ad326da..b3677d383b5
--- a/source/blender/makesdna/DNA_gpencil_modifier_types.h
+++ b/source/blender/makesdna/DNA_gpencil_modifier_types.h
@@@ -887,12 -885,10 +887,14 @@@ typedef enum eLineartGpencilMaskSwitche
    LRT_GPENCIL_TRANSPARENCY_ENABLE = (1 << 0),
    /** Set to true means using "and" instead of "or" logic on mask bits. */
    LRT_GPENCIL_TRANSPARENCY_MATCH = (1 << 1),
 -} eLineartGpencilTransparencyFlags;
 +  LRT_GPENCIL_INTERSECTION_FILTER = (1 << 2),
 +  LRT_GPENCIL_INTERSECTION_MATCH = (1 << 3),
 +} eLineartGpencilMaskSwitches;
 +
 +struct LineartCache;
  
+ struct LineartCache;
+ 
  typedef struct LineartGpencilModifierData {
    GpencilModifierData modifier;
  
@@@ -947,19 -928,17 +949,20 @@@
    /* CPU mode */
    float chaining_image_threshold;
  
 -  /* Ported from SceneLineArt flags. */
 +  /* eLineartMainFlags, for one time calculation. */
    int calculation_flags;
  
 -  /* Additional Switches. */
 +  /* eLineArtGPencilModifierFlags, modifier internal state. */
    int flags;
  
 +  /* Move strokes towards camera to avoid clipping while preserve depth for the viewport. */
 +  float stroke_offset;
 +
    /* Runtime data. */
  
-   /* Because we only do calculation once per modifier stack, so we need global override values for
-    * line art to compute as much data as possible. */
+   /* Because we can potentially only compute features lines once per modifier stack (Use Cache), we
+    * need to have these override values to ensure that we have the data we need is computed and
+    * stored in the cache. */
    char level_start_override;
    char level_end_override;
    short edge_types_override;



More information about the Bf-blender-cvs mailing list