|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectoptics.Optics
optics.OpticalSurface
optics.OpticalPlane
public class OpticalPlane
Class to implement an flat OpticalPlane
being plane with specifed reference position and surface normal.
Also implements the Disagram2DComponet
interface
so can be rendered on a Diagram2D
panel.
Field Summary | |
---|---|
protected static Director |
blockedNormal
Static final Director for surface normal of blocked area of plane. |
protected double |
maxRadius
Maximum radius of the plane from its centre. |
protected Director |
planeNormal
Director for surface normal of transmissive area of plane. |
Fields inherited from class optics.OpticalSurface |
---|
CLEAR, group, REFLECTING, REFRACTING, refractiveIndex, surfacePoint, surfaceType |
Fields inherited from class optics.Optics |
---|
DEFAULT_WAVELENGTH, errorStream, fmt, MICRONS |
Constructor Summary | |
---|---|
OpticalPlane()
Form an OpticalPlane
at specified location along the z axis with surface point a (0,0,z)
and null refractive index. |
|
OpticalPlane(double z)
Form an OpticalPlane
at specified location along the z axis with surface point a (0,0,z)
and null refractive index. |
|
OpticalPlane(double z,
RefractiveIndex index)
Form an OpticalPlane with a specified
plane and refractive index where the reference poit in on-axis
being located at (0,0,z). |
|
OpticalPlane(OpticalPlane p)
Form an OpticalPlane with the parameters
given by a specified OpticalPlane. |
|
OpticalPlane(Position p)
Form an OpticalPlane with a specified
reference point and null
refractive index which represents a non-diffracting surface,
form example an aperture or an image. |
|
OpticalPlane(Position p,
Director n)
Form an OpticalPlane with a specified
reference point and surface normal with and null
refractive index which represents a non-diffracting surface,
form example an aperture or an image. |
|
OpticalPlane(Position p,
Director n,
RefractiveIndex index)
Form an OpticalPlane with a specified
reference point, plane normal
and refractive index on the image side of the plane. |
|
OpticalPlane(Position p,
RefractiveIndex index)
Form an OpticalPlane with a specified
reference point and refractive index on the image side of
the plane. |
Method Summary | |
---|---|
OpticalPlane |
clone()
Method to clone the current OpticalPlane . |
double |
distance(Position r,
Director v)
Get distance from a specified point to the OpticalPlane . |
void |
draw(java.awt.Graphics2D g)
Method to draw OpticalPlane in as
Graphics2D context. |
java.awt.geom.Rectangle2D |
getBounds()
Method to get the graphical bounds in two-dimensions in global coordinates. |
double |
getCurvature()
Method to get curvature, defaults to zero (which is correct for a flat plane). |
double |
getEdgePlane()
Method to get the plane at the maximum radius, will just be the position of the Optical Plane |
double |
getMaxRadius()
Method to get the maximum radius of the plane. |
Director |
getNormal(Position r)
Method to get the surface normal. |
Director |
getPlaneNormal()
Method to get the plane normal |
javax.vecmath.Point2d |
pointInPlane(Position r,
Director u)
Get two-dimensional point in the plane relative to its reference point where a ray from specified position and direction intersect the surface. |
void |
scale(double a)
Method to scale the OpticalPlane
scaling the surface point and the maximum radius. |
void |
setMaxRadius(double r)
Method to set the maximum radius of the plane. |
void |
setPlaneNormal(Director n)
Method to set the plane normal |
java.lang.String |
toString()
toString method |
Methods inherited from class optics.OpticalSurface |
---|
distance, edit, entranceAperture, exitAperture, fromString, fromTokens, getGroup, getIndex, getNormal, getPoint, getRefractiveIndex, getSurfacePoint, getSurfaceType, getSurfaceType, makeStandAlone, pointInPlane, setGroup, setRefractiveIndex, setSurfacePoint, setSurfaceType |
Methods inherited from class optics.Optics |
---|
getDefaultWaveLength, getErrorStream, getFormatString, getName, getStaticName, getVersion, printError, setDefaultWaveLength, setErrorStream, setFormatString, setMicrons |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected double maxRadius
protected Director planeNormal
protected static final Director blockedNormal
Constructor Detail |
---|
public OpticalPlane(Position p, Director n, RefractiveIndex index)
OpticalPlane
with a specified
reference point, plane normal
and refractive index on the image side of the plane.
This represents a flat refracting surface.
p
- the reference pointn
- the plane normalindex
- the refractive indexpublic OpticalPlane(Position p, RefractiveIndex index)
OpticalPlane
with a specified
reference point and refractive index on the image side of
the plane. This represents a flat refracting surface.
p
- the reference pointindex
- the refractive indexpublic OpticalPlane(Position p, Director n)
OpticalPlane
with a specified
reference point and surface normal with and null
refractive index which represents a non-diffracting surface,
form example an aperture or an image.
p
- the surface pointn
- the surface normalpublic OpticalPlane(Position p)
OpticalPlane
with a specified
reference point and null
refractive index which represents a non-diffracting surface,
form example an aperture or an image.
p
- the surface pointpublic OpticalPlane(double z, RefractiveIndex index)
OpticalPlane
with a specified
plane and refractive index where the reference poit in on-axis
being located at (0,0,z).
z
- the z locationindex
- the refractive indexpublic OpticalPlane(double z)
OpticalPlane
at specified location along the z axis with surface point a (0,0,z)
and null refractive index.
z
- the z locationpublic OpticalPlane()
OpticalPlane
at specified location along the z axis with surface point a (0,0,z)
and null refractive index.
public OpticalPlane(OpticalPlane p)
OpticalPlane
with the parameters
given by a specified OpticalPlane. All parameters
except the OpticalGroup
and copied.
p
- the specifying OpticalPlaneMethod Detail |
---|
public OpticalPlane clone()
OpticalPlane
.
clone
in class java.lang.Object
OpticalPlane
clone of current OpticalPlanepublic void setMaxRadius(double r)
setMaxRadius
in class OpticalSurface
r
- rhe radiuspublic double getMaxRadius()
getMaxRadius
in class OpticalSurface
double
the maximum radiuspublic void scale(double a)
OpticalPlane
scaling the surface point and the maximum radius.
scale
in class OpticalSurface
a
- the scalepublic double distance(Position r, Director v)
OpticalPlane
.
distance
in class OpticalSurface
r
- the ray positionv
- the ray direction
double
the distancepublic void setPlaneNormal(Director n)
n
- the plane normalpublic Director getPlaneNormal()
Director
the plane normalpublic Director getNormal(Position r)
getNormal
in class OpticalSurface
r
- the position, assumed to be in the plane.
Director
will be 0,0,1 if inside maximum
radius otherwise will be invalid.public javax.vecmath.Point2d pointInPlane(Position r, Director u)
Note either the Position
or the
Director
are changed.
pointInPlane
in class OpticalSurface
r
- the positionu
- the direction
Point2d
the position in the plane.public double getCurvature()
getCurvature
in class OpticalSurface
double
the curvature.public double getEdgePlane()
Optical Plane
getEdgePlane
in class OpticalSurface
double
the edge plane, being just the
plane position.public java.lang.String toString()
toString
in class java.lang.Object
public java.awt.geom.Rectangle2D getBounds()
getBounds
in interface Diagram2DComponent
Rectangle2D.Float
graphical boundspublic void draw(java.awt.Graphics2D g)
OpticalPlane
in as
Graphics2D context.
draw
in interface Diagram2DComponent
g
- the Graphics2D
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |