Showing the changes to java/pkg/awt/iImageRepresentation.java (1 of 18352 files). Show all
Unified · Split
| @@ -0,0 +1,91 @@ | |||
| 1 | /* | ||
| 2 | * | ||
| 3 | */ | ||
| 4 | |||
| 5 | package inferno.awt; | ||
| 6 | |||
| 7 | import java.awt.Color; | ||
| 8 | import java.awt.Graphics; | ||
| 9 | //import java.awt.AWTException; | ||
| 10 | //import java.awt.Rectangle; | ||
| 11 | import java.awt.image.ColorModel; | ||
| 12 | import java.awt.image.ImageConsumer; | ||
| 13 | import java.awt.image.ImageObserver; | ||
| 14 | import sun.awt.image.ImageWatched; | ||
| 15 | import sun.awt.image.Image; | ||
| 16 | //import sun.awt.AWTFinalizeable; | ||
| 17 | //import sun.awt.AWTFinalizer; | ||
| 18 | //import java.util.Hashtable; | ||
| 19 | |||
| 20 | /* | ||
| 21 | * This implementation the implementation class for Sun's | ||
| 22 | * sun.awt.image.ImageRepresentation. | ||
| 23 | * - jfs | ||
| 24 | */ | ||
| 25 | public class iImageRepresentation extends sun.awt.image.ImageRepresentation | ||
| 26 | { | ||
| 27 | /* ref Draw->Image, used by native code */ | ||
| 28 | Object piImage; | ||
| 29 | |||
| 30 | /** | ||
| 31 | * Create an ImageRepresentation for the given Image scaled | ||
| 32 | * to the given width and height and dithered or converted to | ||
| 33 | * a ColorModel appropriate for the given image tag. | ||
| 34 | */ | ||
| 35 | //public iImageRepresentation(Image im, int w, int h, int t) { | ||
| 36 | public iImageRepresentation(iImage im, int w, int h, int t) { | ||
| 37 | super(im, w, h, t); | ||
| 38 | System.out.println("iImageRep.iImagRep(): w=" + w + " h=" + h + | ||
| 39 | "t=" + t + "im=" + im); | ||
| 40 | } | ||
| 41 | /** | ||
| 42 | * Initialize this ImageRepresentation object to act as the | ||
| 43 | * destination drawable for this OffScreen Image. | ||
| 44 | */ | ||
| 45 | protected native void offscreenInit(Color bg); | ||
| 46 | |||
| 47 | /* make Inferno's own ImageRepresentation - jfs | ||
| 48 | private native boolean setBytePixels(int x, int y, int w, int h, | ||
| 49 | ColorModel model, | ||
| 50 | byte pix[], int off, int scansize); | ||
| 51 | */ | ||
| 52 | protected native boolean setBytePixels(int x, int y, int w, int h, | ||
| 53 | ColorModel model, | ||
| 54 | byte pix[], int off, int scansize); | ||
| 55 | |||
| 56 | /* make Inferno's own ImageRepresentation - jfs | ||
| 57 | private native boolean setIntPixels(int x, int y, int w, int h, | ||
| 58 | ColorModel model, | ||
| 59 | int pix[], int off, int scansize); | ||
| 60 | */ | ||
| 61 | protected native boolean setIntPixels(int x, int y, int w, int h, | ||
| 62 | ColorModel model, | ||
| 63 | int pix[], int off, int scansize); | ||
| 64 | |||
| 65 | /* make Inferno's own ImageRepresentation - jfs | ||
| 66 | private native boolean finish(boolean force); | ||
| 67 | */ | ||
| 68 | protected native boolean finish(boolean force); | ||
| 69 | |||
| 70 | /* make Inferno's own ImageRepresentation - jfs | ||
| 71 | native synchronized void imageDraw(Graphics g, int x, int y, Color c); | ||
| 72 | |||
| 73 | */ | ||
| 74 | native protected synchronized void imageDraw(Graphics g, int x, int y, Color c); | ||
| 75 | |||
| 76 | /* make Inferno's own ImageRepresentation - jfs | ||
| 77 | native synchronized void imageStretch(Graphics g, | ||
| 78 | int dx1, int dy1, int dx2, int dy2, | ||
| 79 | int sx1, int sy1, int sx2, int sy2, | ||
| 80 | Color c); | ||
| 81 | */ | ||
| 82 | native protected synchronized void imageStretch(Graphics g, | ||
| 83 | int dx1, int dy1, int dx2, int dy2, | ||
| 84 | int sx1, int sy1, int sx2, int sy2, | ||
| 85 | Color c); | ||
| 86 | |||
| 87 | /* make Inferno's own ImageRepresentation - jfs | ||
| 88 | private native void disposeImage(); | ||
| 89 | */ | ||
| 90 | protected native void disposeImage(); | ||
| 91 | } | ||