diff options
author | Jeroen Bakker <j.bakker@atmind.nl> | 2012-05-21 18:05:47 +0400 |
---|---|---|
committer | Jeroen Bakker <j.bakker@atmind.nl> | 2012-05-21 18:05:47 +0400 |
commit | c55bb6eae27142a34446440ef3433d5bd7597598 (patch) | |
tree | 748dd558cf0b475517acf03e08d80516dae7395c | |
parent | c3e1fce77552b5626d2939710cb6d0020891d218 (diff) |
* Bokeh Image angle now has rnge from -720 to +720 degrees
-rw-r--r-- | source/blender/compositor/operations/COM_BokehImageOperation.cpp | 5 | ||||
-rw-r--r-- | source/blender/makesrna/intern/rna_nodetree.c | 4 |
2 files changed, 6 insertions, 3 deletions
diff --git a/source/blender/compositor/operations/COM_BokehImageOperation.cpp b/source/blender/compositor/operations/COM_BokehImageOperation.cpp index 4bc738052f6..0279b9a5bdf 100644 --- a/source/blender/compositor/operations/COM_BokehImageOperation.cpp +++ b/source/blender/compositor/operations/COM_BokehImageOperation.cpp @@ -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; } } diff --git a/source/blender/makesrna/intern/rna_nodetree.c b/source/blender/makesrna/intern/rna_nodetree.c index cc2ad912a11..4ec83888e9d 100644 --- a/source/blender/makesrna/intern/rna_nodetree.c +++ b/source/blender/makesrna/intern/rna_nodetree.c @@ -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"); } |