Documentation of 'ext.plantuml.com.ctreber.acearth.gui.PixelCanvas' Java class
PixelCanvas
ext.plantuml.com.ctreber.acearth.gui

Class PixelCanvas

  • All Implemented Interfaces:
    RenderTarget
    Direct Known Subclasses:
    CanvasACearth


    public class PixelCanvas
    extends java.lang.Object
    implements RenderTarget

    Swing compatible drawing surface for images and graphics.

    © 2002 Christian Treber, ct@ctreber.com

    • Constructor Summary

      Constructors 
      Constructor and Description
      PixelCanvas(int pWidth, int pHeight)
      Construct a canvas of the specified size.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      java.awt.Graphics2D getGraphics2D() 
      int getImageHeight() 
      int getImageWidth() 
      void saveToImage(java.io.OutputStream os) 
      boolean saveToImage(java.lang.String pFileName, java.lang.String pFormat) 
      void setPixel(int pX, int pY, java.awt.Color pColor) 
      void setPixel(int pX, int pY, int pA, int pR, int pG, int pB) 
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • PixelCanvas

        public PixelCanvas(int pWidth,
                           int pHeight)

        Construct a canvas of the specified size.

        Parameters:
        pWidth - Width
        pHeight - Height
    • Method Detail

      • getGraphics2D

        public java.awt.Graphics2D getGraphics2D()
      • setPixel

        public void setPixel(int pX,
                             int pY,
                             int pA,
                             int pR,
                             int pG,
                             int pB)
        Specified by:
        setPixel in interface RenderTarget
      • setPixel

        public void setPixel(int pX,
                             int pY,
                             java.awt.Color pColor)
        Specified by:
        setPixel in interface RenderTarget
      • saveToImage

        public boolean saveToImage(java.lang.String pFileName,
                                   java.lang.String pFormat)
                            throws java.io.IOException
        Throws:
        java.io.IOException
      • saveToImage

        public void saveToImage(java.io.OutputStream os)
                         throws java.io.IOException
        Throws:
        java.io.IOException

DataMelt 3.0 © DataMelt by jWork.ORG

Ads help maintain this website.