Class SortMethod

All Implemented Interfaces:
Serializable, Cloneable, Iterable<RenderState<?,?>>, Collection<RenderState<?,?>>, List<RenderState<?,?>>, RandomAccess, SequencedCollection<RenderState<?,?>>
Direct Known Subclasses:
CamDepthSort, CamDistSort, DDUUIDSort, VisibleSort

public abstract class SortMethod extends ArrayList<RenderState<?,?>>
SortMethod is an abstract class which extends ArrayList of GTri and represents a method for sorting triangles.
Author:
Lehlogonolo Poole
See Also:
  • Constructor Details

    • SortMethod

      public SortMethod()
  • Method Details

    • add

      public boolean add(RenderState<?,?> drawable)
      Specified by:
      add in interface Collection<RenderState<?,?>>
      Specified by:
      add in interface List<RenderState<?,?>>
      Overrides:
      add in class ArrayList<RenderState<?,?>>
    • backFaceCulled

      public boolean backFaceCulled(GTri tri)
      Determines if a triangle should be culled based on back-face culling.
      Parameters:
      tri - The triangle to be culled.
      Returns:
      true if the triangle should be culled, false otherwise.
    • sort

      public abstract void sort()