diff options
author | Antonioya <blendergit@gmail.com> | 2019-07-06 00:11:53 +0300 |
---|---|---|
committer | Antonioya <blendergit@gmail.com> | 2019-07-06 00:52:26 +0300 |
commit | a0f3ea7da3f65333fbac9c2d528c4242c417860d (patch) | |
tree | d6004f828aba6d51eb1ace911f8d8be7c0fdea96 /source/blender/draw/engines/gpencil/gpencil_engine.h | |
parent | a7a9c0e50dc9b96d84e1e7cf18d26b3ef5679aa5 (diff) |
Fix T62101: GPencil: selection order is wrong
Following the advices of @Germano Cavalcante (mano-wii) , I have exposed as a workaround the free function to be called from draw manager for selection.
Now, the free function is not called for selection inside gpencil draw_scene, but it's called from draw_manager.c.
The real fix would be create a new Scene_finish callback in draw manager, but as the release of 2.80 is almost here, we fix this with a workaround that must be removed when new callback is in place.
Differential Revision: http://developer.blender.org/D5193
Diffstat (limited to 'source/blender/draw/engines/gpencil/gpencil_engine.h')
-rw-r--r-- | source/blender/draw/engines/gpencil/gpencil_engine.h | 16 |
1 files changed, 10 insertions, 6 deletions
diff --git a/source/blender/draw/engines/gpencil/gpencil_engine.h b/source/blender/draw/engines/gpencil/gpencil_engine.h index d84bdfd8f2c..bc83136fece 100644 --- a/source/blender/draw/engines/gpencil/gpencil_engine.h +++ b/source/blender/draw/engines/gpencil/gpencil_engine.h @@ -359,12 +359,12 @@ typedef struct GpencilBatchCacheElem { } GpencilBatchCacheElem; typedef struct GpencilBatchGroup { - bGPDlayer *gpl; /* reference to original layer */ - bGPDframe *gpf; /* reference to original frame */ - bGPDstroke *gps; /* reference to original stroke */ - short type; /* type of element */ - bool onion; /* the group is part of onion skin */ - int vertex_idx; /* index of vertex data */ + struct bGPDlayer *gpl; /* reference to original layer */ + struct bGPDframe *gpf; /* reference to original frame */ + struct bGPDstroke *gps; /* reference to original stroke */ + short type; /* type of element */ + bool onion; /* the group is part of onion skin */ + int vertex_idx; /* index of vertex data */ } GpencilBatchGroup; typedef enum GpencilBatchGroup_Type { @@ -507,6 +507,10 @@ void GPENCIL_render_to_image(void *vedata, struct RenderLayer *render_layer, const rcti *rect); +/* TODO: GPXX workaround function to call free memory from draw manager while draw manager support + * scene finish callback. */ +void DRW_gpencil_free_runtime_data(void *ved); + /* Use of multisample framebuffers. */ #define MULTISAMPLE_GP_SYNC_ENABLE(lvl, fbl) \ { \ |