diff options
author | Antonioya <blendergit@gmail.com> | 2019-04-03 11:25:49 +0300 |
---|---|---|
committer | Antonioya <blendergit@gmail.com> | 2019-04-03 11:25:49 +0300 |
commit | 382b2a9c66a9f8b64581dc2a360dffbbbe706e21 (patch) | |
tree | 4c0bd232085a821f3fe132eb4bb002f95d7d2099 /source/blender/blenloader/intern | |
parent | a813e259d6309b25fbd0a6d506df810ad2b11395 (diff) |
GPencil: Implement custom channel color in Dopesheet
A new parameter in the layer adjustment panel allows to define the color of the channel in Dopesheet.
This is needed when there are a lot of layers.
See D4623 for more details.
Diffstat (limited to 'source/blender/blenloader/intern')
-rw-r--r-- | source/blender/blenloader/intern/versioning_280.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/versioning_280.c b/source/blender/blenloader/intern/versioning_280.c index 4173bb9d99a..a1087caf40c 100644 --- a/source/blender/blenloader/intern/versioning_280.c +++ b/source/blender/blenloader/intern/versioning_280.c @@ -2952,6 +2952,19 @@ void blo_do_versions_280(FileData *fd, Library *UNUSED(lib), Main *bmain) mat->blend_shadow = MA_BS_SOLID; } } + + /* grease pencil default animation channel color */ + { + for (bGPdata *gpd = bmain->gpencils.first; gpd; gpd = gpd->id.next) { + if (gpd->flag & GP_DATA_ANNOTATIONS) { + continue; + } + for (bGPDlayer *gpl = gpd->layers.first; gpl; gpl = gpl->next) { + /* default channel color */ + ARRAY_SET_ITEMS(gpl->color, 0.2f, 0.2f, 0.2f); + } + } + } } { |