Looks good for this purpose, only suggest that one rename. From a design perspective i'm ...
12 years, 7 months ago
(2011-10-03 13:10:58 UTC)
#2
Looks good for this purpose, only suggest that one rename.
From a design perspective i'm not sure how this should work ideally. Making the
user select the alpha mode of the image sounds like a cheap way out of the whole
alpha premul mess. At least this could be stored per image, so the user has to
define that only once when loading an image (reasonable default is another
question then).
http://codereview.appspot.com/5176042/diff/1/source/blender/makesrna/intern/r...
File source/blender/makesrna/intern/rna_space.c (right):
http://codereview.appspot.com/5176042/diff/1/source/blender/makesrna/intern/r...
source/blender/makesrna/intern/rna_space.c:1643: prop= RNA_def_property(srna,
"draw_alpha", PROP_BOOLEAN, PROP_NONE);
The RNA property name should be more precise, i.e. draw_alpha_premul, to avoid
confusion with overall draw mode flags
> From a design perspective i'm not sure how this should work ideally. Making the ...
12 years, 7 months ago
(2011-10-03 13:24:46 UTC)
#3
> From a design perspective i'm not sure how this should work ideally. Making
the
> user select the alpha mode of the image sounds like a cheap way out of the
whole
> alpha premul mess. At least this could be stored per image, so the user has to
> define that only once when loading an image (reasonable default is another
> question then).
I thought this originally and then turned around on it.
The reason is artist control.
If we assume artists are manually decomposing and generating alphas and
multiplying / dividing as required via math or other nodes, we would then put
the onus on the artist to correctly flag every instance of their alpha. Common
cases would be rotoscope and matte painting decomposes and knockouts.
I strongly suspect that, despite initial reactions, this may very well be the
most elegant solution relative to artist simplicity.
Issue 5176042: VIEWER: Add toggle to determine correct glBlendFunc with regards to associated or unassociated alpha
Created 12 years, 7 months ago by troy_s
Modified 9 years, 7 months ago
Reviewers: bf-codereview_blender.org, lukas.toenne
Base URL: https://svn.blender.org/svnroot/bf-blender/trunk/blender/
Comments: 1