

Public 2D createGraphics() Method to get a Graphics2D object for this picture which can Returns: a graphics object to use for drawing Public getGraphics() Method to get a graphics object for this picture to use to draw on Specified by: getBufferedImage in interface DigitalPicture Returns: the buffered image Public getBufferedImage() Method to get the buffered image Public void setAllPixelsToAColor( color) Method to set the color in the picture to the passed color Parameters: sourcePicture - the picture object to copy Public void copyPicture( SimplePicture sourcePicture) Method that will copy all of the passed source picture into Public getExtension() Method to get the extension for this picture Parameters: copyPicture - the picture to copy from Method Detail Public SimplePicture( SimplePicture copyPicture) A Constructor that takes a picture to copy information from Parameters: width - the desired width height - the desired height Int height) A constructor that takes the width and height desired for a picture andĬreates a buffered image of that size. Parameters: fileName - the file name to use in creating the picture Public SimplePicture( fileName) A Constructor that takes a file name and uses the file to create By default all subclasses will implicitlyĬall this in their parent's no argument constructor unless aĭifferent call to super() is explicitly made as the first line

All fields will be null.Ī no-argument constructor must be given in order for a class toīe able to be subclassed.

Public SimplePicture() A Constructor that takes no arguments. Methods inherited from class Ĭlone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait Method to write the contents of the picture to a file with Method to return a string with information about this picture Method to show the picture in a picture frame Method to make this picture visible or not Method to set the picture frame for this picture SetPictureFrame( PictureFrame pictureFrame) Method to set the media path by setting the directory to use Method to set the value of a pixel in the picture from an int Method to set the color in the picture to the passed color Method to force the picture to redraw itself. Method to load a picture from a file name and show it in a picture frame Method to load the picture from the passed file name Method to load the buffered image with the passed image Method to get the width of the picture in pixels Transformation is applied to the current picture Method to get the coordinates of the enclosing rectangle after this Method to get a one-dimensional array of Pixels for this simple picture Method to get a pixel object for the given x and y location Method to create a new picture of the passed height. Method to get the picture frame for the picture Method to get the directory for the media Method to get the height of the picture in pixels Method to get a graphics object for this picture to use to draw on Method to get the file name associated with the picture Method to get the extension for this picture Method to return the pixel value as an int for the given x and y location Method to open a picture explorer on a copy of this simple picture Method to get a Graphics2D object for this picture which can Method that will copy all of the passed source picture into

Method to draw a message as a string on the buffered imageĬopyPicture( SimplePicture sourcePicture) SimplePicture( SimplePicture copyPicture)Ī Constructor that takes a picture to copy information fromĪ Constructor that takes a file name and uses the file to create You can show a simple picture in aĬopyright Georgia Institute of Technology 2004Ī constructor that takes the width and height desired for a picture and A simple picture may haveĪn associated file name and a title. Public class SimplePicture extends implements DigitalPictureĪ class that represents a simple picture. SimplePicture All Implemented Interfaces: DigitalPicture Direct Known Subclasses: Picture SUMMARY: NESTED | FIELD | CONSTR | METHOD
