SynchronousModel Class Reference

#include <model.h>

Inheritance diagram for SynchronousModel:

Model

List of all members.

Public Member Functions

 SynchronousModel (Machine *parent, string model_definition)
int getCellSize ()
void loadSource ()
void run (CellSpace *pattern, int which, int iteration=1)
virtual void renderToTexture (CellSpace *pattern, int which, cl_mem tex)


Detailed Description

Trieda implemtujuca synchronne celularne automaty. Su mozne dva druhy susedstva Neumanovo teda styria susedia hraniciaci s hranou alebo osem susedov teda vsetky bunky ktore sa dotykaju strednej bunky. Vstupnym formatom modelu je prechodovy strom vo forme matice s rozmermy pocet stavov krat pocet uzlov. Kazdy riadok reprezentuje jeden uzol stromu a jednotlive stlpce nasledujuci uzol ktorym sa ma pokracovat.

Constructor & Destructor Documentation

SynchronousModel::SynchronousModel ( Machine parent,
string  model_definition 
)


Member Function Documentation

int SynchronousModel::getCellSize (  )  [inline, virtual]

Returns:
pocet bajtov ktore zabera reprezentacia zdvojenie jednej bunky.

Implements Model.

void SynchronousModel::loadSource (  )  [virtual]

v tejto metode by sa mal vytvorit zdrojovy kod kernel a nasledne zavolat this->build() pre jeho skompletovanie

Implements Model.

void SynchronousModel::renderToTexture ( CellSpace pattern,
int  which,
cl_mem  tex 
) [virtual]

Metoda by mala nastavit parametre kernel pre vykreslenie do buffera.

Parameters:
pattern potom z ktoreho sa ma kreslit
which ktory z dvojice sa ma vykreslit
tex buffer do ktoreho sa bude kreslit

Implements Model.

void SynchronousModel::run ( CellSpace pattern,
int  which,
int  iteration = 1 
) [virtual]

Tato metoda by mala nastavit parametre pre kernel a následne zavolat parent->run()

Parameters:
pattern ukazovatel na potomka obsahujuci stav modelu
which vypocet bude prebiehat iterativne kedy sa zo stareho stavu vyratava novy. tento parameter urcuje ktory je ktory
iteration kolko krat sa ma spustit kernel. pocas nich musi metoda preklapat which medzi 0 a 1

Implements Model.


The documentation for this class was generated from the following files:

Generated on Tue May 11 22:08:03 2010 for Cellula by  doxygen 1.5.8