|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.lang.Thread | +--CalcThread
Programm: WaveThread
Copyright: 2002 Andreas Gohr, Frank Schubert, Milan Altenburg
License: GPL2 or higher
Info: Class CalcThread, calculates Raster, holds array of Rasters
Field Summary |
Fields inherited from class java.lang.Thread |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
CalcThread(MonoWave[] mw,
java.awt.Color col)
CalcThread Constructor sets time, MonoWave and Color creates new RGB ColorModel |
Method Summary | |
void |
calc_java(int idx)
calculates the next Raster, according to time _time |
void |
calc_native(int idx)
calculates the next Raster, according to time _time but using a native function |
void |
calcArray(int[] returnvals,
float[] wavevals,
int x,
int y,
float t,
boolean sinus_method,
boolean use_pointers,
boolean use_copy)
declaration of native function for calculation of the raster |
void |
die()
control thread from outside, supposed but never used |
long |
fak(int x)
|
java.lang.String |
getOptions()
|
int |
getQueueSize()
|
java.awt.image.WritableRaster |
getRaster()
|
void |
run()
"main" of CalcThread calls synchronized calc to fill queue |
void |
setXY(int x,
int y)
sets new width and height starts Thread, creates suitable Raster resets queue values (length,first,last) |
float |
sinusApproximation(float akt)
|
void |
switchCalcMethod()
switches usage of either native c or java calculation |
void |
switchSinusCalcMethod()
switches usage of either sinus or taylor approximation |
void |
switchUsageOfCopy()
switches usage of line copy |
void |
switchUsageOfPointers()
switches usage of pointers in native c function |
Methods inherited from class java.lang.Thread |
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, toString, yield |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public CalcThread(MonoWave[] mw, java.awt.Color col)
Method Detail |
public void setXY(int x, int y)
public int getQueueSize()
public java.awt.image.WritableRaster getRaster()
public void die()
public void switchCalcMethod()
public void switchSinusCalcMethod()
public void switchUsageOfPointers()
public void switchUsageOfCopy()
public java.lang.String getOptions()
public long fak(int x)
public float sinusApproximation(float akt)
public void calc_java(int idx)
public void calcArray(int[] returnvals, float[] wavevals, int x, int y, float t, boolean sinus_method, boolean use_pointers, boolean use_copy)
public void calc_native(int idx)
public void run()
run
in interface java.lang.Runnable
run
in class java.lang.Thread
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |