Examples of loadFrom()


Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

      long a = java.lang.System.nanoTime();
      long b;
      try {
        System.out.println("Rendering "+textFile+" to "+toFile);
       
        grid.loadFrom(textFile.toString());
        Diagram diagram = new Diagram(grid, options);

        RenderedImage image = new BitmapRenderer().renderToImage(diagram, options.renderingOptions);
       
        b = java.lang.System.nanoTime();
View Full Code Here

Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

      long a = java.lang.System.nanoTime();
      long b;
      try {
        System.out.println("Rendering "+textFile+" to "+toFile);
       
        grid.loadFrom(textFile.toString());
        Diagram diagram = new Diagram(grid, options);

        RenderedImage image = new BitmapRenderer().renderToImage(diagram, options.renderingOptions);
       
        b = java.lang.System.nanoTime();
View Full Code Here

Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

  }
 
  @Test public void testFillContinuousAreaSquareOutside() throws FileNotFoundException, IOException {
    TextGrid squareGrid;
    squareGrid = new TextGrid();
    squareGrid.loadFrom("tests/text/simple_square01.txt");

    CellSet filledArea = squareGrid.fillContinuousArea(0, 0, '*');
    int size = filledArea.size();
    assertEquals(64, size);
   
View Full Code Here

Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

  }

  @Test public void testFillContinuousAreaSquareInside() throws FileNotFoundException, IOException {
    TextGrid squareGrid;
    squareGrid = new TextGrid();
    squareGrid.loadFrom("tests/text/simple_square01.txt");
   
    CellSet filledArea = squareGrid.fillContinuousArea(3, 3, '*');
    int size = filledArea.size();
    assertEquals(15, size);
   
View Full Code Here

Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

  }

  @Test public void testFillContinuousAreaUInside() throws FileNotFoundException, IOException {
    TextGrid uGrid;
    uGrid = new TextGrid();
    uGrid.loadFrom("tests/text/simple_U01.txt");
   
    CellSet filledArea = uGrid.fillContinuousArea(3, 3, '*');
    int size = filledArea.size();
   
    assertEquals(62, size);
View Full Code Here

Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

  }

  @Test public void testFillContinuousAreaUOutside() throws FileNotFoundException, IOException {
    TextGrid uGrid;
    uGrid = new TextGrid();
    uGrid.loadFrom("tests/text/simple_U01.txt");
   
    CellSet filledArea = uGrid.fillContinuousArea(0, 0, '*');
    int size = filledArea.size();
   
    assertEquals(128, size);
View Full Code Here

Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

  }

  @Test public void testFillContinuousAreaSOutside() throws FileNotFoundException, IOException {
    TextGrid uGrid;
    uGrid = new TextGrid();
    uGrid.loadFrom("tests/text/simple_S01.txt");
   
    CellSet filledArea = uGrid.fillContinuousArea(0, 0, '*');
    int size = filledArea.size();
   
    assertEquals(246, size);
View Full Code Here

Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

  }

  @Test public void testFillContinuousAreaSInside1() throws FileNotFoundException, IOException {
    TextGrid uGrid;
    uGrid = new TextGrid();
    uGrid.loadFrom("tests/text/simple_S01.txt");
   
    CellSet filledArea = uGrid.fillContinuousArea(3, 3, '*');
    int size = filledArea.size();
   
    assertEquals(15, size);
View Full Code Here

Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

  }

  @Test public void testFillContinuousAreaSInside2() throws FileNotFoundException, IOException {
    TextGrid uGrid;
    uGrid = new TextGrid();
    uGrid.loadFrom("tests/text/simple_S01.txt");
   
    CellSet filledArea = uGrid.fillContinuousArea(17, 3, '*');
    int size = filledArea.size();

    assertEquals(15, size);
View Full Code Here

Examples of org.stathissideris.ascii2image.text.TextGrid.loadFrom()

 
  @Test public void testFindBoundariesExpandingFromSquare() throws FileNotFoundException, IOException {
    TextGrid grid;
    grid = new TextGrid();
    grid.loadFrom("tests/text/simple_square01.txt");

    CellSet wholeGridSet = new CellSet();
    addSquareToCellSet(grid, wholeGridSet, 0,0, grid.getWidth(),grid.getHeight());
   
    TextGrid copyGrid = new AbstractionGrid(grid, wholeGridSet).getCopyOfInternalBuffer();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.