|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--java.awt.Panel | +--Panel3D
Panel3D uses a pseudo 3d projection (no perspective) to display 3d points on its 2D canvas
Field Summary | |
double |
phi
The value of phi for the spherical coordinates (declination from the positive Z axis) |
double |
ro
The value of ro for the spherical coordinates (radius) - Since perspective is unused this variable is unused |
static double[] |
sat
Array for the state vector of the satellite - will point to Cannibal class' array |
static double[][] |
stars
Array to hold all of the stars - will point to Cannibal class' array |
static double[][] |
starsC
Array to hold all of the stars centered about the satellite to avoid synchronization issues. |
double |
theta
The value of theta for the spherical coordinates (right-ascension) |
Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT,
CENTER_ALIGNMENT,
LEFT_ALIGNMENT,
RIGHT_ALIGNMENT,
TOP_ALIGNMENT |
Constructor Summary | |
Panel3D(boolean centered)
Get a new Panel3D - either centered or not |
Method Summary | |
static double[] |
coordXform(double x,
double y,
double z,
double u,
double v,
double w,
double theta,
double phi,
double psi)
Get the positions of x,y,z defined in an inertial in a new frame centered at u,v,w of the intertial frame with the following roations: angle psi about the z axis angle theta about the transformed x axis angle phi about the transformed y axis |
java.awt.Point |
data3DToScreen(double x,
double y,
double z)
Get a point in the screens coordinates from a 3D point in world coordinates |
java.awt.Point |
dataToScreen(double x,
double y)
Scale a 2D point to the plotting plane |
void |
itemStateChanged(java.awt.event.ItemEvent e)
Receive a change in item state - calls a repaint |
void |
mouseDragged(java.awt.event.MouseEvent e)
receive mouseDragged event |
void |
mouseMoved(java.awt.event.MouseEvent e)
receive mouseMoved event |
void |
paint(java.awt.Graphics g)
Repaint method, calls update |
void |
run()
The runnable method for this Panel3D, will simply update its graphics 10times per second until Cannibal's STOPFLAG is true |
void |
setDataBounds(double xmin,
double xmax,
double ymin,
double ymax)
Set the data bounds of this panel |
void |
update(java.awt.Graphics h)
Renders graphics in a buffered image and draws it to the screen |
Methods inherited from class java.awt.Panel |
addNotify |
Methods inherited from class java.awt.Container |
add,
add,
add,
add,
add,
addContainerListener,
addImpl,
countComponents,
deliverEvent,
doLayout,
findComponentAt,
findComponentAt,
getAlignmentX,
getAlignmentY,
getComponent,
getComponentAt,
getComponentAt,
getComponentCount,
getComponents,
getInsets,
getLayout,
getMaximumSize,
getMinimumSize,
getPreferredSize,
insets,
invalidate,
isAncestorOf,
layout,
list,
list,
locate,
minimumSize,
paintComponents,
paramString,
preferredSize,
print,
printComponents,
processContainerEvent,
processEvent,
remove,
remove,
removeAll,
removeContainerListener,
removeNotify,
setCursor,
setFont,
setLayout,
validate,
validateTree |
Methods inherited from class java.awt.Component |
action,
add,
addComponentListener,
addFocusListener,
addInputMethodListener,
addKeyListener,
addMouseListener,
addMouseMotionListener,
addPropertyChangeListener,
addPropertyChangeListener,
bounds,
checkImage,
checkImage,
coalesceEvents,
contains,
contains,
createImage,
createImage,
disable,
disableEvents,
dispatchEvent,
enable,
enable,
enableEvents,
enableInputMethods,
firePropertyChange,
getBackground,
getBounds,
getBounds,
getColorModel,
getComponentOrientation,
getCursor,
getDropTarget,
getFont,
getFontMetrics,
getForeground,
getGraphics,
getHeight,
getInputContext,
getInputMethodRequests,
getLocale,
getLocation,
getLocation,
getLocationOnScreen,
getName,
getParent,
getPeer,
getSize,
getSize,
getToolkit,
getTreeLock,
getWidth,
getX,
getY,
gotFocus,
handleEvent,
hasFocus,
hide,
imageUpdate,
inside,
isDisplayable,
isDoubleBuffered,
isEnabled,
isFocusTraversable,
isLightweight,
isOpaque,
isShowing,
isValid,
isVisible,
keyDown,
keyUp,
list,
list,
list,
location,
lostFocus,
mouseDown,
mouseDrag,
mouseEnter,
mouseExit,
mouseMove,
mouseUp,
move,
nextFocus,
paintAll,
postEvent,
prepareImage,
prepareImage,
printAll,
processComponentEvent,
processFocusEvent,
processInputMethodEvent,
processKeyEvent,
processMouseEvent,
processMouseMotionEvent,
remove,
removeComponentListener,
removeFocusListener,
removeInputMethodListener,
removeKeyListener,
removeMouseListener,
removeMouseMotionListener,
removePropertyChangeListener,
removePropertyChangeListener,
repaint,
repaint,
repaint,
repaint,
requestFocus,
reshape,
resize,
resize,
setBackground,
setBounds,
setBounds,
setComponentOrientation,
setDropTarget,
setEnabled,
setForeground,
setLocale,
setLocation,
setLocation,
setName,
setSize,
setSize,
setVisible,
show,
show,
size,
toString,
transferFocus |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
public double ro
public double phi
public double theta
public static double[][] stars
public static double[][] starsC
public static double[] sat
Constructor Detail |
public Panel3D(boolean centered)
Method Detail |
public void run()
public void paint(java.awt.Graphics g)
public void update(java.awt.Graphics h)
public java.awt.Point dataToScreen(double x, double y)
public java.awt.Point data3DToScreen(double x, double y, double z)
public static double[] coordXform(double x, double y, double z, double u, double v, double w, double theta, double phi, double psi)
public void setDataBounds(double xmin, double xmax, double ymin, double ymax)
public void mouseMoved(java.awt.event.MouseEvent e)
public void mouseDragged(java.awt.event.MouseEvent e)
public void itemStateChanged(java.awt.event.ItemEvent e)
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |