Class Parallel3DRenderer<O extends NumberVector>
- java.lang.Object
-
- elki.visualization.parallel3d.Parallel3DRenderer<O>
-
- Type Parameters:
O
- Object type
@Reference(authors="Elke Achtert, Hans-Peter Kriegel, Erich Schubert, Arthur Zimek", title="Interactive Data Mining with 3D-Parallel-Coordinate-Trees", booktitle="Proc. 2013 ACM Int. Conf. on Management of Data (SIGMOD 2013)", url="https://doi.org/10.1145/2463676.2463696", bibkey="DBLP:conf/sigmod/AchtertKSZ13") public class Parallel3DRenderer<O extends NumberVector> extends java.lang.Object
Renderer for 3D parallel plots.The tricky part here is the vertex buffer layout. We are drawing lines, so we need two vertices for each macro edge (edge between axes in the plot). We furthermore need the following properties: we need to draw edges sorted by depth to allow alpha and smoothing to work, and we need to be able to have different colors for clusters. An efficient batch therefore will consist of one edge-color combination. The input data comes in color-object ordering, so we need to seek through the edges when writing the buffer.
In total, we have 2 * obj.size * edges.size vertices.
Where obj.size = sum(col.sizes)
Reference:
Elke Achtert, Hans-Peter Kriegel, Erich Schubert, Arthur Zimek:
Interactive Data Mining with 3D-Parallel-Coordinate-Trees.
Proc. 2013 ACM Int. Conf. on Management of Data (SIGMOD 2013)TODO: generalize to non-numeric features and scales.
- Since:
- 0.6.0
- Author:
- Erich Schubert
-
-
Field Summary
Fields Modifier and Type Field Description (package private) DoubleIntPair[]
axes
Axes sorting array.(package private) float[]
colors
Color table.private int
completedTextures
Number of completely rendered textures.private int[]
dindex
Depth indexes of axes.(package private) int[]
frameBufferID
Framebuffer for render-to-textureprivate static Logging
LOG
Logging class.(package private) OpenGL3DParallelCoordinates.Instance.Shared<O>
shared
Shared data.private int[]
textures
Prerendered textures.(package private) int[]
vbi
Vertex buffer.
-
Constructor Summary
Constructors Modifier Constructor Description protected
Parallel3DRenderer(OpenGL3DParallelCoordinates.Instance.Shared<O> shared)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
drawParallelPlot(javax.media.opengl.GLAutoDrawable drawable, javax.media.opengl.GL2 gl)
protected void
forgetTextures(javax.media.opengl.GL gl)
protected int
prepare(javax.media.opengl.GL2 gl)
private void
prepareColors(StylingPolicy sp)
private void
renderLabels(javax.media.opengl.GL2 gl, IntIntPair[] edgesort)
(package private) void
renderTexture(javax.media.opengl.GL2 gl, int edge)
private void
sortAxes()
Depth-sort the axes.private IntIntPair[]
sortEdges(int[] dindex)
Sort the edges for rendering.
-
-
-
Field Detail
-
LOG
private static final Logging LOG
Logging class.
-
shared
OpenGL3DParallelCoordinates.Instance.Shared<O extends NumberVector> shared
Shared data.
-
textures
private int[] textures
Prerendered textures.
-
completedTextures
private int completedTextures
Number of completely rendered textures.
-
dindex
private int[] dindex
Depth indexes of axes.
-
colors
float[] colors
Color table.
-
axes
DoubleIntPair[] axes
Axes sorting array.
-
vbi
int[] vbi
Vertex buffer.
-
frameBufferID
int[] frameBufferID
Framebuffer for render-to-texture
-
-
Constructor Detail
-
Parallel3DRenderer
protected Parallel3DRenderer(OpenGL3DParallelCoordinates.Instance.Shared<O> shared)
Constructor.- Parameters:
shared
- Shared data.
-
-
Method Detail
-
prepare
protected int prepare(javax.media.opengl.GL2 gl)
-
drawParallelPlot
protected void drawParallelPlot(javax.media.opengl.GLAutoDrawable drawable, javax.media.opengl.GL2 gl)
-
renderTexture
void renderTexture(javax.media.opengl.GL2 gl, int edge)
-
prepareColors
private void prepareColors(StylingPolicy sp)
-
forgetTextures
protected void forgetTextures(javax.media.opengl.GL gl)
-
sortAxes
private void sortAxes()
Depth-sort the axes.
-
sortEdges
private IntIntPair[] sortEdges(int[] dindex)
Sort the edges for rendering. FIXME: THIS STILL HAS ERRORS SOMETIME!- Parameters:
dindex
- depth index of axes.- Returns:
- Sorted array of (minaxis, edgeid)
-
renderLabels
private void renderLabels(javax.media.opengl.GL2 gl, IntIntPair[] edgesort)
-
-