* Bokeh Image angle now has rnge from -720 to +720 degrees

This commit is contained in:
Jeroen Bakker 2012-05-21 14:05:47 +00:00
parent c3e1fce775
commit c55bb6eae2
2 changed files with 6 additions and 3 deletions

@ -38,7 +38,10 @@ void BokehImageOperation::initExecution()
this->circularDistance = getWidth()/2;
this->flapRad = (M_PI*2)/this->data->flaps;
this->flapRadAdd = (this->data->angle/360.0)*M_PI*2;
if (this->flapRadAdd>M_PI) {
while (this->flapRadAdd<0.0f) {
this->flapRadAdd+=M_PI*2;
}
while (this->flapRadAdd>M_PI) {
this->flapRadAdd-=M_PI*2;
}
}

@ -3111,7 +3111,7 @@ static void def_cmp_bokehimage(StructRNA *srna)
prop = RNA_def_property(srna, "angle", PROP_FLOAT, PROP_NONE);
RNA_def_property_float_sdna(prop, NULL, "angle");
RNA_def_property_float_default(prop, 0.0f);
RNA_def_property_range(prop, -0.0f, 360.0f);
RNA_def_property_range(prop, -720.0f, 720.0f);
RNA_def_property_ui_text(prop, "Angle", "Angle of the bokeh");
RNA_def_property_update(prop, NC_NODE|NA_EDITED, "rna_Node_update");
@ -3140,7 +3140,7 @@ static void def_cmp_bokehimage(StructRNA *srna)
RNA_def_property_float_sdna(prop, NULL, "lensshift");
RNA_def_property_float_default(prop, 0.0f);
RNA_def_property_range(prop, -1.0f, 1.0f);
RNA_def_property_ui_text(prop, "Lens shift", "Shift of the lens");
RNA_def_property_ui_text(prop, "Lens shift", "Shift of the lens components");
RNA_def_property_update(prop, NC_NODE|NA_EDITED, "rna_Node_update");
}