src/share/classes/java/awt/image/DataBuffer.java

Print this page

        

*** 1,7 **** /* ! * Copyright (c) 1997, 2008, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this --- 1,7 ---- /* ! * Copyright (c) 1997, 2013, Oracle and/or its affiliates. All rights reserved. * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. * * This code is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public License version 2 only, as * published by the Free Software Foundation. Oracle designates this
*** 39,49 **** import static sun.java2d.StateTrackable.State.*; import sun.java2d.StateTrackableDelegate; import sun.awt.image.SunWritableRaster; ! import javax.tools.annotation.GenerateNativeHeader; /** * This class exists to wrap one or more data arrays. Each data array in * the DataBuffer is referred to as a bank. Accessor methods for getting * and setting elements of the DataBuffer's banks exist with and without --- 39,49 ---- import static sun.java2d.StateTrackable.State.*; import sun.java2d.StateTrackableDelegate; import sun.awt.image.SunWritableRaster; ! import java.lang.annotation.Native; /** * This class exists to wrap one or more data arrays. Each data array in * the DataBuffer is referred to as a bank. Accessor methods for getting * and setting elements of the DataBuffer's banks exist with and without
*** 65,98 **** * image classes use TYPE_BYTE, TYPE_USHORT, TYPE_INT, TYPE_SHORT, * TYPE_FLOAT, and TYPE_DOUBLE DataBuffers to store image data. * @see java.awt.image.Raster * @see java.awt.image.SampleModel */ - /* No native methods here, but the constants are needed in the supporting JNI code */ - @GenerateNativeHeader public abstract class DataBuffer { /** Tag for unsigned byte data. */ ! public static final int TYPE_BYTE = 0; /** Tag for unsigned short data. */ ! public static final int TYPE_USHORT = 1; /** Tag for signed short data. Placeholder for future use. */ ! public static final int TYPE_SHORT = 2; /** Tag for int data. */ ! public static final int TYPE_INT = 3; /** Tag for float data. Placeholder for future use. */ ! public static final int TYPE_FLOAT = 4; /** Tag for double data. Placeholder for future use. */ ! public static final int TYPE_DOUBLE = 5; /** Tag for undefined data. */ ! public static final int TYPE_UNDEFINED = 32; /** The data type of this DataBuffer. */ protected int dataType; /** The number of banks in this DataBuffer. */ --- 65,96 ---- * image classes use TYPE_BYTE, TYPE_USHORT, TYPE_INT, TYPE_SHORT, * TYPE_FLOAT, and TYPE_DOUBLE DataBuffers to store image data. * @see java.awt.image.Raster * @see java.awt.image.SampleModel */ public abstract class DataBuffer { /** Tag for unsigned byte data. */ ! @Native public static final int TYPE_BYTE = 0; /** Tag for unsigned short data. */ ! @Native public static final int TYPE_USHORT = 1; /** Tag for signed short data. Placeholder for future use. */ ! @Native public static final int TYPE_SHORT = 2; /** Tag for int data. */ ! @Native public static final int TYPE_INT = 3; /** Tag for float data. Placeholder for future use. */ ! @Native public static final int TYPE_FLOAT = 4; /** Tag for double data. Placeholder for future use. */ ! @Native public static final int TYPE_DOUBLE = 5; /** Tag for undefined data. */ ! @Native public static final int TYPE_UNDEFINED = 32; /** The data type of this DataBuffer. */ protected int dataType; /** The number of banks in this DataBuffer. */