Class VertexOBJ

java.lang.Object
com.irurueta.geometry.io.VertexOBJ

public class VertexOBJ extends Object
This class defines the structure that contains data for a single vertex in an OBJ file.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private int
    Index of normal corresponding to this vertex in OBJ file.
    private int
    Index of texture assigned to this vertex in OBJ file.
    private com.irurueta.geometry.Point3D
    Contains coordinates of 3D point.
    private int
    Index of vertex in OBJ file.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructor.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    Returns index of normal corresponding to this vertex in OBJ file.
    int
    Returns index of texture assigned to this vertex in OBJ file.
    com.irurueta.geometry.Point3D
    Returns coordinates of 3D point.
    int
    Returns index of vertex in OBJ file.
    boolean
    Indicates whether normal index has been provided or not.
    boolean
    Indicates if texture assigned to this vertex is available or not
    boolean
    Indicates whether 3D point has been provided or not.
    boolean
    Indicates whether vertex index has been provided or not.
    void
    setNormalIndex(int normalIndex)
    Sets index of normal corresponding to this vertex in OBJ file.
    void
    setTextureIndex(int textureIndex)
    Sets index of texture assigned to this vertex in OBJ file.
    void
    setVertex(com.irurueta.geometry.Point3D vertex)
    Sets coordinates of 3D point.
    void
    setVertexIndex(int vertexIndex)
    Sets index of vertex in OBJ file.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • vertex

      private com.irurueta.geometry.Point3D vertex
      Contains coordinates of 3D point.
    • vertexIndex

      private int vertexIndex
      Index of vertex in OBJ file.
    • normalIndex

      private int normalIndex
      Index of normal corresponding to this vertex in OBJ file.
    • textureIndex

      private int textureIndex
      Index of texture assigned to this vertex in OBJ file.
  • Constructor Details

    • VertexOBJ

      public VertexOBJ()
      Constructor.
  • Method Details

    • getVertex

      public com.irurueta.geometry.Point3D getVertex()
      Returns coordinates of 3D point.
      Returns:
      coordinates of 3D point.
    • setVertex

      public void setVertex(com.irurueta.geometry.Point3D vertex)
      Sets coordinates of 3D point.
      Parameters:
      vertex - coordinates of 3D point.
    • isVertexAvailable

      public boolean isVertexAvailable()
      Indicates whether 3D point has been provided or not.
      Returns:
      true if 3D point is available, false otherwise.
    • getVertexIndex

      public int getVertexIndex()
      Returns index of vertex in OBJ file.
      Returns:
      index of vertex in OBJ file.
    • setVertexIndex

      public void setVertexIndex(int vertexIndex)
      Sets index of vertex in OBJ file.
      Parameters:
      vertexIndex - index of vertex in OBJ file.
    • isVertexIndexAvailable

      public boolean isVertexIndexAvailable()
      Indicates whether vertex index has been provided or not.
      Returns:
      true if vertex index is available, false otherwise.
    • getNormalIndex

      public int getNormalIndex()
      Returns index of normal corresponding to this vertex in OBJ file.
      Returns:
      index of normal corresponding to this vertex in OBJ file.
    • setNormalIndex

      public void setNormalIndex(int normalIndex)
      Sets index of normal corresponding to this vertex in OBJ file.
      Parameters:
      normalIndex - index of normal corresponding to this vertex in OBJ file.
    • isNormalIndexAvailable

      public boolean isNormalIndexAvailable()
      Indicates whether normal index has been provided or not.
      Returns:
      true if normal index is available, false otherwise.
    • getTextureIndex

      public int getTextureIndex()
      Returns index of texture assigned to this vertex in OBJ file.
      Returns:
      index of texture assigned to this vertex in OBJ file.
    • setTextureIndex

      public void setTextureIndex(int textureIndex)
      Sets index of texture assigned to this vertex in OBJ file.
      Parameters:
      textureIndex - index of texture assigned to this vertex in OBJ file.
    • isTextureIndexAvailable

      public boolean isTextureIndexAvailable()
      Indicates if texture assigned to this vertex is available or not
      Returns:
      true if available, false otherwise.