diff options
author | Antonio Vazquez <blendergit@gmail.com> | 2019-09-18 18:56:23 +0300 |
---|---|---|
committer | Antonio Vazquez <blendergit@gmail.com> | 2019-09-18 21:55:38 +0300 |
commit | 6f7a64b57fcb235461146b6953ed7a30166c4a56 (patch) | |
tree | 96b78e59ac376488f5c3324a5d813b142c9a33f4 /source/blender/draw/engines/gpencil/gpencil_engine.h | |
parent | e7fde3a0f3b62f913a66c445bcdf4ee0b9a501f1 (diff) |
GPencil: Create blank texture only once by engine
This texture is used for missing textures as replace.
Differential Revision: https://developer.blender.org/D5845
Diffstat (limited to 'source/blender/draw/engines/gpencil/gpencil_engine.h')
-rw-r--r-- | source/blender/draw/engines/gpencil/gpencil_engine.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/source/blender/draw/engines/gpencil/gpencil_engine.h b/source/blender/draw/engines/gpencil/gpencil_engine.h index 27d537c9a20..b014717e6f5 100644 --- a/source/blender/draw/engines/gpencil/gpencil_engine.h +++ b/source/blender/draw/engines/gpencil/gpencil_engine.h @@ -265,9 +265,6 @@ typedef struct g_data { /* grid geometry */ GPUBatch *batch_grid; - /* textures */ - struct GPUTexture *gpencil_blank_texture; - /* runtime pointers texture */ struct GPUTexture *input_depth_tx; struct GPUTexture *input_color_tx; @@ -297,6 +294,9 @@ typedef enum eGPsession_Flag { } eGPsession_Flag; typedef struct GPENCIL_e_data { + /* textures */ + struct GPUTexture *gpencil_blank_texture; + /* general drawing shaders */ struct GPUShader *gpencil_fill_sh; struct GPUShader *gpencil_stroke_sh; @@ -386,7 +386,8 @@ typedef struct GpencilBatchCache { } GpencilBatchCache; /* general drawing functions */ -struct DRWShadingGroup *gpencil_shgroup_stroke_create(struct GPENCIL_Data *vedata, +struct DRWShadingGroup *gpencil_shgroup_stroke_create(struct GPENCIL_e_data *e_data, + struct GPENCIL_Data *vedata, struct DRWPass *pass, struct GPUShader *shader, struct Object *ob, |