Package seamcarving.seamfinding
Class GenerativeSeamFinder
- java.lang.Object
- 
- seamcarving.seamfinding.GenerativeSeamFinder
 
- 
- All Implemented Interfaces:
- SeamFinder
 
 public class GenerativeSeamFinder extends Object implements SeamFinder Generative adjacency list graph single-sourceShortestPathSolverimplementation of theSeamFinderinterface.- See Also:
- Graph,- ShortestPathSolver,- SeamFinder,- SeamCarver
 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Class Description private static classGenerativeSeamFinder.PixelGraphGenerative adjacency list graph ofGenerativeSeamFinder.PixelGraph.Pixelvertices andEnergyFunction-weighted edges.
 - 
Field SummaryFields Modifier and Type Field Description private ShortestPathSolver.Constructor<Node>spsThe constructor for theShortestPathSolverimplementation.
 - 
Constructor SummaryConstructors Constructor Description GenerativeSeamFinder(ShortestPathSolver.Constructor<Node> sps)Constructs an instance with the givenShortestPathSolverimplementation.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description List<Integer>findHorizontal(Picture picture, EnergyFunction f)Returns a minimum-energy horizontal seam in the current image as aListof integers representing the vertical pixel index to remove from each column in the width of the horizontal seam.
 
- 
- 
- 
Field Detail- 
spsprivate final ShortestPathSolver.Constructor<Node> sps The constructor for theShortestPathSolverimplementation.
 
- 
 - 
Constructor Detail- 
GenerativeSeamFinderpublic GenerativeSeamFinder(ShortestPathSolver.Constructor<Node> sps) Constructs an instance with the givenShortestPathSolverimplementation.- Parameters:
- sps- the- ShortestPathSolverimplementation.
 
 
- 
 - 
Method Detail- 
findHorizontalpublic List<Integer> findHorizontal(Picture picture, EnergyFunction f) Description copied from interface:SeamFinderReturns a minimum-energy horizontal seam in the current image as aListof integers representing the vertical pixel index to remove from each column in the width of the horizontal seam.- Specified by:
- findHorizontalin interface- SeamFinder
- Parameters:
- picture- the- Picture.
- f- the- EnergyFunction.
- Returns:
- a Listof integers representing the vertical pixels to remove.
 
 
- 
 
-