diff options
author | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2017-10-26 15:17:58 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@gmail.com> | 2017-11-08 00:35:12 +0300 |
commit | e0936e74abc5c9349fa55abe0f79f96f5add9f37 (patch) | |
tree | a58d0ade78eb8dbeff690aa312c2d2880776c34b /source/blender/render/intern | |
parent | 3dec1de2758a5301a44462a6655abcfe08c62db0 (diff) |
Fix image editor showing pass name when there is only a combined pass.
Diffstat (limited to 'source/blender/render/intern')
-rw-r--r-- | source/blender/render/intern/source/pipeline.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/source/blender/render/intern/source/pipeline.c b/source/blender/render/intern/source/pipeline.c index 837721e8943..2eac20214ba 100644 --- a/source/blender/render/intern/source/pipeline.c +++ b/source/blender/render/intern/source/pipeline.c @@ -4024,7 +4024,7 @@ bool RE_WriteEnvmapResult(struct ReportList *reports, Scene *scene, EnvMap *env, } } -/* used in the interface to decide whether to show layers */ +/* Used in the interface to decide whether to show layers or passes. */ bool RE_layers_have_name(struct RenderResult *rr) { switch (BLI_listbase_count_ex(&rr->layers, 2)) { @@ -4038,6 +4038,17 @@ bool RE_layers_have_name(struct RenderResult *rr) return false; } +bool RE_passes_have_name(struct RenderLayer *rl) +{ + for (RenderPass *rp = rl->passes.first; rp; rp = rp->next) { + if (!STREQ(rp->name, "Combined")) { + return true; + } + } + + return false; +} + RenderPass *RE_pass_find_by_name(volatile RenderLayer *rl, const char *name, const char *viewname) { RenderPass *rp = NULL; |