diff options
author | Ton Roosendaal <ton@blender.org> | 2008-09-09 14:16:09 +0400 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2008-09-09 14:16:09 +0400 |
commit | 70be839859852f9fcf3ab234093c390d5b2c9c05 (patch) | |
tree | dd354ed8055780bdf6518c43eca4725fd431d045 /source/blender/nodes/intern/CMP_nodes | |
parent | 3f87319428ff6b7b6fc0eb6df8c6ecaad49b49cc (diff) |
Bugfix #13837
Tonemap didn't correctly accept any buffer type.
The coder who added this should check this fix! Any node coder maybe...
Diffstat (limited to 'source/blender/nodes/intern/CMP_nodes')
-rw-r--r-- | source/blender/nodes/intern/CMP_nodes/CMP_tonemap.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_tonemap.c b/source/blender/nodes/intern/CMP_nodes/CMP_tonemap.c index 5e1803a6774..950ad97a397 100644 --- a/source/blender/nodes/intern/CMP_nodes/CMP_tonemap.c +++ b/source/blender/nodes/intern/CMP_nodes/CMP_tonemap.c @@ -130,13 +130,16 @@ static void node_composit_exec_tonemap(void *data, bNode *node, bNodeStack **in, if ((img==NULL) || (out[0]->hasoutput==0)) return; if (img->type != CB_RGBA) - new = typecheck_compbuf(img, CB_RGBA); - else - new = dupalloc_compbuf(img); + img = typecheck_compbuf(img, CB_RGBA); + + new = dupalloc_compbuf(img); tonemap(node->storage, new, img); out[0]->data = new; + + if(img!=in[0]->data) + free_compbuf(img); } static void node_composit_init_tonemap(bNode* node) |