|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objects373.cellularautomata.CAdata
public class CAdata
CAdata base cellular automaton class. holds rules and data mechanics up to 3d.
Field Summary | |
---|---|
int[] |
currentGrid
|
boolean |
debug
|
int |
dimx
|
int |
dimy
|
int |
dimz
|
int[] |
nextGrid
|
int |
numactive
|
int |
numbit
|
int |
numpixels
|
byte[] |
rules
|
int |
rulesInt
|
Constructor Summary | |
---|---|
CAdata()
|
Method Summary | |
---|---|
void |
clear()
clear data. |
byte[] |
getBinaryRule()
get rule in the automaton in binary notation. |
String |
getBinaryRuleString()
get rule in the automaton in binary string notation. |
int[] |
getData()
get data array |
int |
getRule()
get rule in the automaton in int notation. |
float |
random(float max)
|
void |
setBinaryRule(byte[] binrules)
set rule in the automaton in binary notation. |
void |
setCenter1()
set center cell 1. |
void |
setNumBits(int nbits)
set number of bits in this ruleset. |
void |
setRule(int rule)
set rule for automaton in int notation. |
void |
setRules()
set random rules for automaton |
void |
setRules(int rule)
set rule for automaton in int notation. |
void |
update()
update the automaton. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public int[] currentGrid
public int[] nextGrid
public byte[] rules
public int rulesInt
public int dimx
public int dimy
public int dimz
public int numpixels
public int numbit
public int numactive
public boolean debug
Constructor Detail |
---|
public CAdata()
Method Detail |
---|
public void setRules()
public void setRule(int rule)
rule
- public void setRules(int rule)
rule
- public int getRule()
public void setBinaryRule(byte[] binrules)
binaryrules
- public byte[] getBinaryRule()
public String getBinaryRuleString()
public void update()
public int[] getData()
public void setCenter1()
public void setNumBits(int nbits)
nbits
- public void clear()
public float random(float max)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |