forked from bartvdbraak/blender
Fix #35586: add an option to the Z Combine compositing node to disable the Z
buffer antialiasing that was restored in 2.67 after it was missing in the new compositor implementation. This option tends to make results worse rather then better for Cycles renders, but is useful for Blender internal. Their Z-buffers look quite different for antialiasing, and I'd rather not change either.
This commit is contained in:
parent
50262b5ea9
commit
99e97afbe3
@ -34,7 +34,7 @@
|
||||
|
||||
void ZCombineNode::convertToOperations(ExecutionSystem *system, CompositorContext *context)
|
||||
{
|
||||
if (context->getRenderData()->scemode & R_FULL_SAMPLE) {
|
||||
if ((context->getRenderData()->scemode & R_FULL_SAMPLE) || this->getbNode()->custom2) {
|
||||
if (this->getOutputSocket(0)->isConnected()) {
|
||||
ZCombineOperation *operation = NULL;
|
||||
if (this->getbNode()->custom1) {
|
||||
|
@ -1379,6 +1379,7 @@ static void node_composit_buts_zcombine(uiLayout *layout, bContext *UNUSED(C), P
|
||||
|
||||
col = uiLayoutColumn(layout, TRUE);
|
||||
uiItemR(col, ptr, "use_alpha", 0, NULL, ICON_NONE);
|
||||
uiItemR(col, ptr, "use_antialias_z", 0, NULL, ICON_NONE);
|
||||
}
|
||||
|
||||
|
||||
|
@ -5148,6 +5148,11 @@ static void def_cmp_zcombine(StructRNA *srna)
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "custom1", 0);
|
||||
RNA_def_property_ui_text(prop, "Use Alpha", "Take Alpha channel into account when doing the Z operation");
|
||||
RNA_def_property_update(prop, NC_NODE | NA_EDITED, "rna_Node_update");
|
||||
|
||||
prop = RNA_def_property(srna, "use_antialias_z", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_negative_sdna(prop, NULL, "custom2", 0);
|
||||
RNA_def_property_ui_text(prop, "Anti-Alias Z", "Anti-alias the z-buffer to try to avoid artifacts, mostly useful for Blender renders");
|
||||
RNA_def_property_update(prop, NC_NODE | NA_EDITED, "rna_Node_update");
|
||||
}
|
||||
|
||||
static void def_cmp_ycc(StructRNA *srna)
|
||||
|
Loading…
Reference in New Issue
Block a user