use of org.jwildfire.create.tina.variation.Spherical3DWFFunc in project JWildfire by thargor6.
the class FlameMorphService method prepareMorphXForm.
private static void prepareMorphXForm(XForm pXForm) {
int i = 0;
while (i < pXForm.getVariationCount()) {
Variation var = pXForm.getVariation(i);
if (var.getFunc() instanceof Spherical3DWFFunc) {
Object invert = var.getFunc().getParameter(Spherical3DWFFunc.PARAM_INVERT);
if (invert != null && ((Integer) invert) == 1) {
var.getFunc().setParameter(Spherical3DWFFunc.PARAM_INVERT, 0);
var.setAmount(-var.getAmount());
}
} else if (var.getFunc() instanceof PostMirrorWFFunc) {
pXForm.removeVariation(var);
i--;
}
i++;
}
}
Aggregations