|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Objectcommon:Generic
common:Formula
common:DivergentFormula
mmf:MMF_SwitchDivergentFormula
mmf:MMF_SwitchStandard
class
Generic Switchable Mandelbrot set.
class MMF_SwitchStandard(MMF_SwitchDivergentFormula) {
;
; Generic Switchable Mandelbrot set.<br>
;
public:
import "common.ulb"
; @param pparent the parent, generally "this" for the parent, or zero
func MMF_SwitchStandard(Generic pparent)
MMF_SwitchDivergentFormula.MMF_SwitchDivergentFormula(pparent)
endfunc
complex func Iterate(complex pz)
if @p_advanced && @p_switch=="Power"
return pz^fConstant + @p_seed1
else
return pz^@p_power + fConstant
endif
endfunc
default:
title = "Switch Standard"
rating = recommended
bool param p_advanced
caption = "Enable Advanced Settings"
default = false
hint = "When enabled you can choose which variable is switchable."
endparam
int param p_switch
caption = "Switch Value"
enum = "Normal" "Power"
default = 1
hint = "In 'Normal' mode the constant c in z^p+c is the switchable \
variable, in 'Power' mode the power p in z^p+c is used \
instead."
visible = @p_advanced
endparam
complex param p_seed1
caption = "Seed"
default = (0.25,0)
hint = "The constant c in z^p+c."
visible = @p_advanced && @p_switch>0
endparam
complex param p_power
caption = "Power"
default = (2,0)
hint = "This parameter sets the exponent for the standard z^p+c \
formula. Increasing the real part to 3, 4, and so on, \
will add discs to the Mandelbrot figure. Non-integer \
real values and non-zero imaginary values will create \
distorted sets. Use (2, 0) for the standard Mandelbrot/Julia \
sets."
visible = !@p_advanced || @p_switch!=1
endparam
}
| Constructor Summary | |
|---|---|
MMF_SwitchStandard()
|
|
MMF_SwitchStandard(Generic pparent)
|
|
| Method Summary | |
|---|---|
complex |
Iterate(complex pz)
Produce the next value in the sequence |
| Methods inherited from class mmf:MMF_SwitchDivergentFormula |
|---|
Init, SetParams |
| Methods inherited from class common:DivergentFormula |
|---|
GetUpperBailout, IsBailedOut |
| Methods inherited from class common:Formula |
|---|
GetLowerBailout, GetPrimaryExponent |
| Methods inherited from class common:Generic |
|---|
GetParent |
| Methods inherited from class Object |
|---|
|
| Constructor Detail |
|---|
public MMF_SwitchStandard(Generic pparent)
pparent - the parent, generally "this" for the parent, or zeropublic MMF_SwitchStandard()
| Method Detail |
|---|
public complex Iterate(complex pz)
FormulaAs long as the sequence has not bailed out, this function will be continually called to produce sequence values.
Iterate in class Formulapz - previous value in the sequence; corresponds to #z in a fractal formula. Note that you should always use this value for computing the next iteration, rather than a saved value, as the calling code may modify the returned value before passing it back to the next Iterate() call.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||