org.scilab.forge.scirenderer.implementation.g2d.buffers
Class G2DElementsBuffer

java.lang.Object
  extended by org.scilab.forge.scirenderer.implementation.g2d.buffers.G2DElementsBuffer
All Implemented Interfaces:
DataBuffer, ElementsBuffer

public class G2DElementsBuffer
extends java.lang.Object
implements DataBuffer, ElementsBuffer

Author:
Calixte DENIZET

Field Summary
static int ELEMENT_SIZE
          The current size of one element.
 
Method Summary
 void clear()
           
 java.nio.FloatBuffer getData()
          Return the data.
 int getElementsSize()
          Return the number of coordinate for one element.
 int getSize()
          Return the number of elements.
 void setData(float[] newData, int elementSize)
          Set the data.
 void setData(java.lang.Float[] newData, int elementSize)
          Set the data.
 void setData(java.nio.FloatBuffer newData, int elementsSize)
          Set the data.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

ELEMENT_SIZE

public static final int ELEMENT_SIZE
The current size of one element.

See Also:
Constant Field Values
Method Detail

setData

public void setData(float[] newData,
                    int elementSize)
Description copied from interface: ElementsBuffer
Set the data.

Specified by:
setData in interface ElementsBuffer
Parameters:
newData - the new data.
elementSize - the size of data elements.

setData

public void setData(java.lang.Float[] newData,
                    int elementSize)
Description copied from interface: ElementsBuffer
Set the data.

Specified by:
setData in interface ElementsBuffer
Parameters:
newData - the new data.
elementSize - the size of data elements.

setData

public void setData(java.nio.FloatBuffer newData,
                    int elementsSize)
Description copied from interface: ElementsBuffer
Set the data.

Specified by:
setData in interface ElementsBuffer
Parameters:
newData - the new data.
elementsSize - the size of data elements.

getSize

public int getSize()
Description copied from interface: DataBuffer
Return the number of elements.

Specified by:
getSize in interface DataBuffer
Returns:
the number of elements.

getElementsSize

public int getElementsSize()
Description copied from interface: ElementsBuffer
Return the number of coordinate for one element.

Specified by:
getElementsSize in interface ElementsBuffer
Returns:
the number of coordinate for one element.

getData

public java.nio.FloatBuffer getData()
Description copied from interface: DataBuffer
Return the data.

Specified by:
getData in interface DataBuffer
Specified by:
getData in interface ElementsBuffer
Returns:
the data.

clear

public void clear()
Specified by:
clear in interface DataBuffer
Specified by:
clear in interface ElementsBuffer