|
JClass DesktopViews 6.3.0 API Documentation |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.klg.jclass.chart3d.ParentTrackChange | +--com.klg.jclass.chart3d.JCContour
Object used to deal with information about contours and zones. It has methods to compute and to draw the contours/zones.
Field Summary | |
protected com.klg.jclass.chart3d.ColorBin[] |
bins
An array of color bins for faster rendering of 2D projections. |
protected static int |
BOTTOM_EDGE
|
protected static int |
BOTTOM_LEFT_CORNER
|
protected static int |
BOTTOM_RIGHT_CORNER
|
protected com.klg.jclass.chart3d.ContourCell[] |
contourCells
Contouring information by cell. |
protected boolean |
contoured
Asks if the contour lines are drawn. |
protected com.klg.jclass.chart3d.JCContourLevels |
contourLevels
A list of contour levels. |
protected ArrayList |
contourLines
A list of contour lines. |
protected com.klg.jclass.chart3d.JCContourMapping |
contourMapping
A mapping of contour levels to contour styles. |
protected ArrayList |
contourStyles
List of contour styles which determine how zones and contour lines are drawn. |
protected com.klg.jclass.chart3d.ContourSegment |
curSegment
|
protected static int |
CYCLE_CLOCKWISE
|
protected static int |
CYCLE_COUNTER_CLOCKWISE
|
protected com.klg.jclass.chart3d.Chart3dGridData |
data
|
protected double |
dataHoleValue
|
protected com.klg.jclass.chart3d.Chart3dDataView |
dataView
The parent dataView object. |
protected com.klg.jclass.chart3d.DefaultColors |
defaultColors
A list of default colors (for default contour styles generation). |
protected int |
firstIndex
|
protected com.klg.jclass.chart3d.PolygonChain[] |
fixedChain
|
protected com.klg.jclass.chart3d.PolygonChain |
freeList
|
protected static int |
LEFT_EDGE
|
protected int |
nHorizontalSides
|
protected int |
numX
|
protected int |
numY
|
protected int |
nVerticalSides
|
protected int |
pCount
|
protected static int |
RIGHT_EDGE
|
protected com.klg.jclass.chart3d.CellSide[] |
sides
|
protected static int |
TOP_EDGE
|
protected static int |
TOP_LEFT_CORNER
|
protected static int |
TOP_RIGHT_CORNER
|
protected int |
xOffset
|
protected int[] |
xPoints
|
protected int |
yOffset
|
protected int[] |
yPoints
|
static int |
ZONE_CELLS_AVERAGE
Instructs zoning to be done by cells using the average of the four corners of the cell. |
static int |
ZONE_CELLS_CORNER
Instructs zoning to be done by cells using the value at the bottom left corner of the cell. |
static int |
ZONE_CONTOURS
Instructs zoning to be done by contours. |
protected boolean |
zoned
Asks if the contour zones are drawn. |
protected com.klg.jclass.chart3d.Chart3dGridData |
zoneData
|
protected double |
zoneHoleValue
|
protected int |
zoneMethod
Zoning filling method. |
Fields inherited from class com.klg.jclass.chart3d.ParentTrackChange |
parents |
Constructor Summary | |
JCContour()
No args constructor. |
|
JCContour(com.klg.jclass.chart3d.Chart3dDataView dataView)
Constructor which specifies the parent dataView . |
Method Summary | |
protected void |
addContourCell(int xIndex,
int yIndex,
int level,
int side)
A contour line is entering this cell, this side. |
protected void |
addPoint(int xIndex,
int yIndex,
double x,
double y)
Adds this point to the current contour line. |
protected void |
allocatePoints(int n)
Allocates points only when necessary. |
protected void |
allocColorBins(Graphics gc)
Allocates a color bin for each level. |
protected com.klg.jclass.chart3d.PolygonChain |
appendChain(com.klg.jclass.chart3d.PolygonChain pChain1,
com.klg.jclass.chart3d.PolygonChain pChain2)
Appends chain pchain2 to the end of pchain1. |
protected boolean |
avail(int xIndex,
int yIndex,
int side,
int level,
double right,
double left)
Is the side of the cell at (x_index, y_index) available to cross a contour at this level? Make sure no other contour of this level has crossed; if not, see if a contour does cross it. |
protected int |
bottomSide(int x,
int y)
Gets the index of the bottom side of cell (x, y) in the sides array. |
void |
calcContours()
Calculates the contours for this data. |
protected int |
cellIndex(int x,
int y)
Returns the index in the ContourCells array for this cell. |
protected void |
contour(int cycle,
int xIndex,
int yIndex,
int level,
int side)
Generates a complete contour that starts at (xIndex, yIndex). |
int |
contourIndex(int level)
Returns the contour style index that corresponds to this level. |
protected com.klg.jclass.chart3d.PolygonChain |
copyChain(com.klg.jclass.chart3d.PolygonChain pChain)
Copies an entire chain to a new one, and returns the new one. |
protected void |
cycleArray(Object[] array,
int n)
Cycles the array's lower most four elements by n. |
protected void |
defaultContourStyles()
Resets the contour styles to their default value. |
protected void |
destroyChain(com.klg.jclass.chart3d.PolygonChain pChain)
Gets rid of this chain. |
void |
destroyContours()
Destroys the contour information. |
protected void |
draw2dZones(Graphics gc)
Draws flat zones in a 2D projection. |
protected void |
draw3dZones(Graphics gc)
Draws flat zones in a 3D projection ( projecting zones onto either the top or bottom of the cube). |
protected void |
drawCellContours(Graphics gc,
int xIndex,
int yIndex)
Draws all contours for the specified cell. |
protected void |
drawContours(Graphics gc)
Draws flat contours. |
protected boolean |
fillCell(Graphics gc,
int xIndex,
int yIndex)
Fills in the cell at (xIndex, yIndex) by breaking it into smaller polygons that must be filled individually. |
protected void |
fillCellCorners(Graphics gc,
com.klg.jclass.chart3d.PolygonChain[] chainArray,
int index)
Fills the zoned cell at each of the four corners. |
protected void |
fillCellSide(Graphics gc,
com.klg.jclass.chart3d.PolygonChain[] chainArray,
int corner1,
int corner2,
int index)
Fills the portions of the zoned cell relating to the left-to-right or bottom-to-top crossings. |
protected void |
fillChain(Graphics gc,
com.klg.jclass.chart3d.PolygonChain pChain)
Fills in a PolygonChain . |
protected void |
fillRectangle(int xIndex,
int yIndex,
boolean useAverage)
Fills a zoned rectangle, using either the value at the given grid point or the average of the four corner values of the cell. |
protected void |
flushColorBins()
Flushes the color bins. |
com.klg.jclass.chart3d.ContourCell[] |
getContourCells()
Returns the contour cell array. |
com.klg.jclass.chart3d.JCContourLevels |
getContourLevels()
Returns the contourLevels object. |
ArrayList |
getContourLines()
Returns the list of contour lines (internal use only). |
com.klg.jclass.chart3d.JCContourMapping |
getContourMapping()
Returns the object which currently implements the mapping between contour levels and contour styles (by default this is the JCContour object). |
com.klg.jclass.chart3d.JCContourStyle |
getContourStyleFromLevel(int level)
Returns the contour style used for a given contour level. |
ArrayList |
getContourStyles()
Returns the current contour styles. |
com.klg.jclass.chart3d.Chart3dPointDataModel |
getDataContours(int first,
int last,
int filter,
boolean combineLevels)
Returns the contour lines in point data format. |
com.klg.jclass.chart3d.Chart3dDataView |
getDataView()
Returns the parent dataView . |
protected com.klg.jclass.chart3d.DefaultColors |
getDefaultColors()
Retrieves the default colors object which stores the list of default contour style colors. |
protected int |
getSide(int x,
int y,
int side)
Gets the index of a given side in the sides array for cell (x, y). |
int |
getZoneMethod()
Returns the zone method - by ZONE_CONTOURS ,
ZONE_CELLS_AVERAGE , or ZONE_CELLS_CORNER . |
protected boolean |
horizontalSide(int x)
Is side x a horizontal side? It is if it is odd. |
protected double |
interp(double a1,
double a2,
double o1,
double o2,
double av)
Interpolates in 2D along the line running from (a1, o1) to (a2, o2) and point a = av. |
boolean |
isContoured()
Returns whether this data view is contoured . |
boolean |
isZoned()
Returns whether this data view is zoned . |
protected int |
leftSide(int x,
int y)
Gets the index of the left side of cell (x, y) in the sides array. |
protected com.klg.jclass.chart3d.PolygonChain |
makePChain(int xPixel,
int yPixel,
double zValue,
double cValue)
Makes a new chain, containing this single point. |
protected void |
modifyContourCell(int xIndex,
int yIndex,
int side)
Adds the second crossing point for the current segment across this cell. |
protected void |
precompContours()
Goes through each contour point and transforms it. |
void |
processPolygon(Graphics gc,
int count,
int level)
Given a list of points and a contour level, process the polygon that the list of points defines. |
void |
recalcContours()
Checks whether to calculate or destroy the contours based on the contour and zone flags from this object, and the floor and ceiling projections. |
void |
resetContourStyles()
Allows the user to reset the contour styles to their default. |
protected void |
reverseArray(Object[] array,
int n)
Reverses an array of length n. |
protected com.klg.jclass.chart3d.PolygonChain |
reverseChain(com.klg.jclass.chart3d.PolygonChain pChain)
Reverses the order of points in this chain. |
protected int |
rightSide(int x,
int y)
Gets the index of the right side of cell (x, y) in the sides array. |
protected void |
setContourCellHole(int xIndex,
int yIndex)
A zone hole has been detected during the contour search at point (xIndex, yIndex). |
void |
setContoured(boolean contoured)
Sets flag which determine whether this data view is contoured . |
protected void |
setContouredNoUpdate(boolean contoured)
Sets flag which determines whether this data view is contoured, but doesn't update the dataView . |
void |
setContourLevels(com.klg.jclass.chart3d.JCContourLevels contourLevels)
Sets the contourLevels object. |
void |
setContourMapping(com.klg.jclass.chart3d.JCContourMapping contourMapping)
Provides an object that implements the JCContourMapping
interface. |
void |
setContourStyles(ArrayList contourStyles)
Sets the contour styles array. |
protected void |
setDataView(com.klg.jclass.chart3d.Chart3dDataView dataView)
Sets the parent dataView . |
protected void |
setFillStyle(Graphics gc,
int level)
Sets the fill style for this level. |
protected void |
setInternalValues()
Sets some internal values (for easier access). |
protected boolean |
setLineStyle(Graphics gc,
int level)
Sets the line style for this level. |
protected void |
setZLineColor(Graphics gc,
int level)
Sets the line color for this level based on the fill (zone) style color (rather than the line style color). |
void |
setZoned(boolean zoned)
Sets flag which determines whether this data view is zoned . |
protected void |
setZonedNoUpdate(boolean zoned)
Sets flag which determines whether this data view is zoned, but doesn't update the dataView . |
void |
setZoneMethod(int zoneMethod)
Sets the zone method - by ZONE_CONTOURS or
ZONE_CELLS . |
protected void |
startContour(int xIndex,
int yIndex,
int level,
Point3d p1,
Point3d p2)
Starts a new contour at this level. |
protected int |
topSide(int x,
int y)
Gets the index of the top side of cell (x, y) in the sides array. |
protected boolean |
verticalSide(int x)
Is side x a vertical side? It is if it is even. |
protected boolean |
zoneMeshCell(Graphics gc,
int xIndex,
int yIndex)
Draws a zoned mesh for this cell. |
protected double |
zoneMeshIntersection(Graphics gc,
ArrayList intersectionList,
Point right,
double zr,
boolean doSeg1,
boolean increasing)
Draws the zoned mesh for this intersection list for a given mesh line. |
Methods inherited from class com.klg.jclass.chart3d.ParentTrackChange |
addParent, clearParents, removeParent |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int ZONE_CONTOURS
public static final int ZONE_CELLS_AVERAGE
public static final int ZONE_CELLS_CORNER
protected static final int CYCLE_CLOCKWISE
protected static final int CYCLE_COUNTER_CLOCKWISE
protected static final int LEFT_EDGE
protected static final int RIGHT_EDGE
protected static final int BOTTOM_EDGE
protected static final int TOP_EDGE
protected static final int BOTTOM_LEFT_CORNER
protected static final int TOP_LEFT_CORNER
protected static final int TOP_RIGHT_CORNER
protected static final int BOTTOM_RIGHT_CORNER
protected boolean contoured
protected boolean zoned
protected int zoneMethod
protected com.klg.jclass.chart3d.JCContourLevels contourLevels
protected ArrayList contourStyles
protected com.klg.jclass.chart3d.JCContourMapping contourMapping
protected com.klg.jclass.chart3d.Chart3dDataView dataView
dataView
object.
protected com.klg.jclass.chart3d.DefaultColors defaultColors
protected com.klg.jclass.chart3d.Chart3dGridData data
protected com.klg.jclass.chart3d.Chart3dGridData zoneData
protected int xOffset
protected int yOffset
protected int numX
protected int numY
protected double dataHoleValue
protected double zoneHoleValue
protected ArrayList contourLines
protected com.klg.jclass.chart3d.ContourCell[] contourCells
protected com.klg.jclass.chart3d.ColorBin[] bins
protected com.klg.jclass.chart3d.PolygonChain[] fixedChain
protected com.klg.jclass.chart3d.PolygonChain freeList
protected int pCount
protected com.klg.jclass.chart3d.CellSide[] sides
protected int nHorizontalSides
protected int nVerticalSides
protected int firstIndex
protected com.klg.jclass.chart3d.ContourSegment curSegment
protected int[] xPoints
protected int[] yPoints
Constructor Detail |
public JCContour()
public JCContour(com.klg.jclass.chart3d.Chart3dDataView dataView)
dataView
. There can be
only one dataView
parent since the contours are heavily
dependent on the data.
dataView
- the parent dataView
Method Detail |
protected void setDataView(com.klg.jclass.chart3d.Chart3dDataView dataView)
dataView
. There can be only one
dataView
parent since the contours are heavily dependent on
the data.
dataView
- the new parent dataViewpublic com.klg.jclass.chart3d.Chart3dDataView getDataView()
dataView
.
dataView
public void setContoured(boolean contoured)
contoured
.
contoured
- the new value of the contoured flagprotected void setContouredNoUpdate(boolean contoured)
dataView
. This is used in drawing projections where
the value of contoured
needs to be set to a temporary value
while drawing the projection.
contoured
- the new value of the contoured flagpublic boolean isContoured()
contoured
.
public void setZoned(boolean zoned)
zoned
.
zoned
- the new value of the zoned flagprotected void setZonedNoUpdate(boolean zoned)
dataView
. This is used in drawing projections where
the value of zoned
needs to be set to a temporary value while
drawing the projection.
zoned
- the new value of the zoned flagpublic boolean isZoned()
zoned
.
zoned
flagpublic void setZoneMethod(int zoneMethod)
zone
method - by ZONE_CONTOURS
or
ZONE_CELLS
.
zoneMethod
- the new zone
methodpublic int getZoneMethod()
zone
method - by ZONE_CONTOURS
,
ZONE_CELLS_AVERAGE
, or ZONE_CELLS_CORNER
.
zone
methodpublic void setContourLevels(com.klg.jclass.chart3d.JCContourLevels contourLevels)
contourLevels
object.
contourLevels
- the new contourLevels
objectpublic com.klg.jclass.chart3d.JCContourLevels getContourLevels()
contourLevels
object.
contourLevels
objectpublic void setContourMapping(com.klg.jclass.chart3d.JCContourMapping contourMapping)
JCContourMapping
interface. This object provides a mapping between contour levels and
contour styles.
contourMapping
- the new contour mappingpublic com.klg.jclass.chart3d.JCContourMapping getContourMapping()
JCContour
object).
public void setContourStyles(ArrayList contourStyles)
contourStyles
- the new list of contour stylespublic ArrayList getContourStyles()
public void resetContourStyles()
setContourStyles(null);
.
protected com.klg.jclass.chart3d.DefaultColors getDefaultColors()
public ArrayList getContourLines()
public com.klg.jclass.chart3d.ContourCell[] getContourCells()
cellIndex
(x, y) method will return the
correct position in the array for a given (x, y). For internal
use only.
protected boolean verticalSide(int x)
x
- the side in question
protected boolean horizontalSide(int x)
x
- the side in question
protected int leftSide(int x, int y)
x
- the x index of the celly
- the y index of the cell
protected int rightSide(int x, int y)
x
- the x index of the celly
- the y index of the cell
protected int bottomSide(int x, int y)
x
- the x index of the celly
- the y index of the cell
protected int topSide(int x, int y)
x
- the x index of the celly
- the y index of the cell
protected int getSide(int x, int y, int side)
x
- the x index of the celly
- the y index of the cellside
- the side in question
protected int cellIndex(int x, int y)
ContourCells
array for this cell.
x
- the x index of the celly
- the y index of the cell
ContourCells
array for this cellprotected void setInternalValues()
protected boolean avail(int xIndex, int yIndex, int side, int level, double right, double left)
xIndex
- xIndex of the cellyIndex
- yIndex of the cellside
- the side whose availability is in questionlevel
- the contour level who wants to cross the given sideright
- the z value on the "right" side of the contour level valueleft
- the z value on the "left" side of the contour level value
protected double interp(double a1, double a2, double o1, double o2, double av)
a1
- x value for first pointa2
- x value for second pointav
- o1
- y value for first pointo2
- y value for second point
protected void addContourCell(int xIndex, int yIndex, int level, int side)
xIndex
- xIndex of the cellyIndex
- yIndex of the celllevel
- the contour level entering cellside
- the side of the cell being enteredprotected void modifyContourCell(int xIndex, int yIndex, int side)
xIndex
- the xIndex of the cellyIndex
- the yIndex of the cellside
- the side which the contour line is crossingprotected void reverseArray(Object[] array, int n)
array
- the array to reversen
- The number of elements of the array to reverse. May not be equal
to array.length.protected void cycleArray(Object[] array, int n)
array
- the array to cyclen
- The number of elements to cycle. May not be equal to array.length.protected void addPoint(int xIndex, int yIndex, double x, double y)
xIndex
- the x grid index of the pointyIndex
- the y grid index of the pointx
- the x value of the point to addy
- the y value of the point to addprotected void startContour(int xIndex, int yIndex, int level, Point3d p1, Point3d p2)
xIndex
- the x grid index of the start pointyIndex
- the y grid index of the start pointlevel
- the contour level to startp1
- point 1 of the line the start point crossesp2
- point 2 of the line the start point crossesprotected void contour(int cycle, int xIndex, int yIndex, int level, int side)
We reorient everything to make it look like we're coming in side 3. The order we search the sides is determined by 'cycle' - either clockwise or counter-clockwise.
cycle
- the order we search the sides, either equal to CYCLE_CLOCKWISE
or CYCLE_COUNTER_CLOCKWISE
xIndex
- the x grid index of the start pointyIndex
- the y grid index of the start pointlevel
- the contour levelside
- the side of the cell to start contouringprotected void setContourCellHole(int xIndex, int yIndex)
xIndex
- the x grid index of the contour cellyIndex
- the y grid index of the contour cellpublic void calcContours()
Once we have found a crossing, this generates a starting point for the
contouring. The method contour()
will either search for a new
cell in either a clockwise or counter-clockwise fashion (this is done to
ensure that no two contour lines intersect).
All crossings are searched either clockwise or counter-clockwise; this maintains symmetry, and ensures the non-intersection rule (but see the Known Bugs section at the top of this file).
public void recalcContours()
public void destroyContours()
protected void precompContours()
protected void allocatePoints(int n)
n
- the number of points to allocateprotected void defaultContourStyles()
initContourStyles
method will assign colors
later.
protected void allocColorBins(Graphics gc)
gc
- the graphics object to use for drawingprotected void flushColorBins()
public int contourIndex(int level)
contourIndex
in interface JCContourMapping
level
- the level for which the contour style index is desired
public com.klg.jclass.chart3d.JCContourStyle getContourStyleFromLevel(int level)
contourMapping
's contourIndex
method to get the index of the
contour style in the contourStyles
array.
level
- the level for which the contour style index is desired
protected boolean setLineStyle(Graphics gc, int level)
false
(nothing should be drawn);
otherwise, return true
.
gc
- the graphics object to use for drawinglevel
- the level whose line style info you want to set on the gc
lineStyle
infoprotected void setFillStyle(Graphics gc, int level)
gc
- the graphics object to use for drawinglevel
- the level whose fill style info you want to set on the gcprotected void setZLineColor(Graphics gc, int level)
gc
- the graphics object to use for drawinglevel
- the level whose fill color you want to set on the gcprotected void fillRectangle(int xIndex, int yIndex, boolean useAverage)
zoneMethod
is ZONE_CELL_AVERAGE
. This fills
one grid cell, at (xIndex, yIndex).
xIndex
- the x grid index of the cellyIndex
- the y grid index of the celluseAverage
- use the average of the four corners of the cell to zone,
or just the value at the bottom left cornerprotected com.klg.jclass.chart3d.PolygonChain makePChain(int xPixel, int yPixel, double zValue, double cValue)
xPixel
- the x pixel value for this pointyPixel
- the y pixel value for this pointzValue
- elevation data z valuecValue
- zone (or contour) data value
protected com.klg.jclass.chart3d.PolygonChain copyChain(com.klg.jclass.chart3d.PolygonChain pChain)
pChain
- the chain to be copied
protected com.klg.jclass.chart3d.PolygonChain appendChain(com.klg.jclass.chart3d.PolygonChain pChain1, com.klg.jclass.chart3d.PolygonChain pChain2)
pChain1
- the initial chainpChain2
- the chain to be appended
protected com.klg.jclass.chart3d.PolygonChain reverseChain(com.klg.jclass.chart3d.PolygonChain pChain)
pChain
- the chain to be reversed
protected void destroyChain(com.klg.jclass.chart3d.PolygonChain pChain)
pChain
- the chain to be destroyedpublic void processPolygon(Graphics gc, int count, int level)
gc
- the graphics object to use for drawingcount
- the number of points in the listlevel
- the contour level for this polygonprotected void fillChain(Graphics gc, com.klg.jclass.chart3d.PolygonChain pChain)
PolygonChain
. This chain represents a polygon, which
should be filled in one solid color. We determine that value by taking the
average value of all the points, unless the zoneMethod
is ZONE_CELLS_CORNER
,
in which case we take the value of the bottom left corner of the cell.
gc
- the graphics object to use for drawingpChain
- the polygon chain to be filledprotected void fillCellCorners(Graphics gc, com.klg.jclass.chart3d.PolygonChain[] chainArray, int index)
gc
- the graphics object to use for drawingchainArray
- the array of polygon chains to fill (one per corner)index
- the index of the contourCell
whose corners are to be filledprotected void fillCellSide(Graphics gc, com.klg.jclass.chart3d.PolygonChain[] chainArray, int corner1, int corner2, int index)
gc
- the graphics object to use for drawingchainArray
- the array of polygons chains to fillcorner1
- the first cornercorner2
- the second cornerindex
- the index of the contourCell
whose cell sides are to be filledprotected boolean fillCell(Graphics gc, int xIndex, int yIndex)
All the contour crossings have been computed for this cell, and are stored
in the ContourCell
intersection lists. There are 5 lists.
The first four represent those lines which cross the 4 corners and are
stored in the corners array. The last represents those lines which cross
side-to-side or top-to-bottom (note that no cell can contain contour lines
which both cross side-to-side and top-to-bottom).
All those segments which cross the corners have been sorted (see
sortIntersectionLists()
method in ContourCells
for
the particulars). We construct a polygon chain for each corner that consists
only of the corner value, and then possible extend the polygons after that,
by growing outward from the corner. After that, do the side-to-side
crossings.
If this is a zone hole, return false
and the caller will fill the cell
normally (4D).
gc
- the graphics object to use for drawingxIndex
- the x index of the cell to be filledyIndex
- the y index of the cell to be filled
protected void drawCellContours(Graphics gc, int xIndex, int yIndex)
drawContours()
).
gc
- the graphics object to use for drawingxIndex
- the x index of the cell to be drawnyIndex
- the y index of the cell to be drawnprotected double zoneMeshIntersection(Graphics gc, ArrayList intersectionList, Point right, double zr, boolean doSeg1, boolean increasing)
gc
- the graphics object to use for drawingintersectionList
- the intersection list to draw line segments fromright
- the starting point - updated as the list is traversedzr
- the starting value - updated as the list is traverseddoSeg1
- draw the points in segment1 or segment2increasing
- draw forwards or backwards in list
protected boolean zoneMeshCell(Graphics gc, int xIndex, int yIndex)
false
and the
caller will draw a normal mesh in its place (4D).
Basic algorithm is to follow along each side of the mesh, from corner to corner, taking each contour intersection as they occur.
gc
- the graphics object to use for drawingxIndex
- the x index of the cell to drawyIndex
- the y index of the cell to draw
protected void draw2dZones(Graphics gc)
gc
- the graphics object to use for drawingprotected void draw3dZones(Graphics gc)
gc
- the graphics object to use for drawingprotected void drawContours(Graphics gc)
gc
- the graphics object to use for drawingpublic com.klg.jclass.chart3d.Chart3dPointDataModel getDataContours(int first, int last, int filter, boolean combineLevels)
first
- the first contour line to be in the data setlast
- the last contour line to be in the data set (by setting this
parameter to be Integer.MAX_VALUE
you will get all the
contours from first to the end of the contour line array).filter
- by setting this value to be n, you get every
nth contour line starting at firstcombineLevels
- A contour level can be specified by more than one
distinct line segment. If combineLevels
is false
, each
segment will be stored in its own series. If combineLevels
is true
, all segements from the same level will be stored in one series.
Chart3dPointDataModel
(stored in a
JCDefault3dPointDataSource
object) that contains the point
data. If an error occurs, or no contour lines match the inputted values
of first, last, and filter, null is returned. JCContour
object must
be true
for the contours to be generated.
|
Copyright © 2004 Quest Software Inc.. All rights reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |