Plot.PlotChangedListener, Plot.PlotFlag, Plot.PlotMarker, Plot.PlotMarkerDefault, Plot.PlotStyle
Modifier and Type | Field and Description |
---|---|
de.lme.plotview.Plot.PlotAxis |
yAxis |
Constructor and Description |
---|
Plot2D(java.lang.String plotTitle,
Paint paint,
Plot.PlotStyle style,
int maxCache)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
void |
addValue(float value,
long x,
float y)
Adds a single new value to this plot using the given x and y coordinate.
|
void |
clear() |
void |
getViewport(de.lme.plotview.PlotView.PlotSurface surface)
Calculates certain viewport-related values.
|
int |
loadFromFile(Context con,
java.io.InputStream streamIn)
Loads from streamIn.
|
void |
setAxis(java.lang.String xTitle,
java.lang.String xUnit,
float xMultiplier,
java.lang.String yTitle,
java.lang.String yUnit,
float yMultiplier) |
void |
setViewport(long xPivot,
long yPivot,
long xRange,
long yRange)
Sets the desired viewport in the 2D-plane.
|
addValue, addValue, addValue, addValueFast, addValueFast, create, saveToFile
drawGlobalMarks, generatePlotPaint, generatePlotPaint, generatePlotPaint, getMarker, getValueHead, setAxis, setFile, setMarker, setMarker, setPaint, setViewport
public Plot2D(java.lang.String plotTitle, Paint paint, Plot.PlotStyle style, int maxCache)
plotTitle
- title for the plotm_paint
- Paint to use for this plot. Can be null (default m_paint). Use
PlotView.generatePlotPaint to create various randomized paints
easily.style
- type of the plot.maxCache
- maximum number of entries to store. 0 means no limit. due to
performance issues it is HIGHLY recommended that you set this
value! you have to set this to 0 though if you manage the
arrays yourself!public void setAxis(java.lang.String xTitle, java.lang.String xUnit, float xMultiplier, java.lang.String yTitle, java.lang.String yUnit, float yMultiplier)
public void setViewport(long xPivot, long yPivot, long xRange, long yRange)
xPivot
- Pivot point for xRange. Displayed values will be: [xPivot -
xRange/2; xPivot + xRange/2]yPivot
- Pivot point for yRange.xRange
- Range of values to display in x-direction.yRange
- Range of values to display in y-direction.public void addValue(float value, long x, float y)
value
- Sample value.x
- X coordinatey
- Y coordinatepublic void getViewport(de.lme.plotview.PlotView.PlotSurface surface)
Plot
getViewport
in class Plot1D
surface
- Structure has to be filled with missing values.public int loadFromFile(Context con, java.io.InputStream streamIn)
loadFromFile
in class Plot1D
con
- streamIn
-