< prev index next >

src/java.desktop/share/classes/sun/java2d/pipe/hw/AccelSurface.java

Print this page


   1 /*
   2  * Copyright (c) 2007, 2013, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.  Oracle designates this
   8  * particular file as subject to the "Classpath" exception as provided
   9  * by Oracle in the LICENSE file that accompanied this code.
  10  *
  11  * This code is distributed in the hope that it will be useful, but WITHOUT
  12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14  * version 2 for more details (a copy is included in the LICENSE file that
  15  * accompanied this code).
  16  *
  17  * You should have received a copy of the GNU General Public License version
  18  * 2 along with this work; if not, write to the Free Software Foundation,
  19  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20  *
  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any


  26 package sun.java2d.pipe.hw;
  27 
  28 import java.awt.Rectangle;
  29 import sun.java2d.Surface;
  30 
  31 import java.lang.annotation.Native;
  32 
  33 /**
  34  * Abstraction for a hardware accelerated surface.
  35  */
  36 public interface AccelSurface extends BufferedContextProvider, Surface {
  37     /**
  38      * Undefined
  39      */
  40     @Native public static final int UNDEFINED       = 0;
  41     /**
  42      * Window (or window substitute) surface
  43      */
  44     @Native public static final int WINDOW          = 1;
  45     /**
  46      * Render-To Plain surface (pbuffer for OpenGL, Render Target surface
  47      * for Direct3D)
  48      */
  49     @Native public static final int RT_PLAIN        = 2;
  50     /**
  51      * Texture surface
  52      */
  53     @Native public static final int TEXTURE         = 3;
  54     /**
  55      * A back-buffer surface (SwapChain surface for Direct3D, backbuffer for
  56      * OpenGL)
  57      */
  58     @Native public static final int FLIP_BACKBUFFER = 4;
  59     /**
  60      * Render-To Texture surface (fbobject for OpenGL, texture with render-to
  61      * attribute for Direct3D)
  62      */
  63     @Native public static final int RT_TEXTURE      = 5;
  64 
  65     /**
  66      * Returns {@code int} representing surface's type as defined by constants
  67      * in this interface.


   1 /*
   2  * Copyright (c) 2007, 2015, Oracle and/or its affiliates. All rights reserved.
   3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
   4  *
   5  * This code is free software; you can redistribute it and/or modify it
   6  * under the terms of the GNU General Public License version 2 only, as
   7  * published by the Free Software Foundation.  Oracle designates this
   8  * particular file as subject to the "Classpath" exception as provided
   9  * by Oracle in the LICENSE file that accompanied this code.
  10  *
  11  * This code is distributed in the hope that it will be useful, but WITHOUT
  12  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14  * version 2 for more details (a copy is included in the LICENSE file that
  15  * accompanied this code).
  16  *
  17  * You should have received a copy of the GNU General Public License version
  18  * 2 along with this work; if not, write to the Free Software Foundation,
  19  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
  20  *
  21  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
  22  * or visit www.oracle.com if you need additional information or have any


  26 package sun.java2d.pipe.hw;
  27 
  28 import java.awt.Rectangle;
  29 import sun.java2d.Surface;
  30 
  31 import java.lang.annotation.Native;
  32 
  33 /**
  34  * Abstraction for a hardware accelerated surface.
  35  */
  36 public interface AccelSurface extends BufferedContextProvider, Surface {
  37     /**
  38      * Undefined
  39      */
  40     @Native public static final int UNDEFINED       = 0;
  41     /**
  42      * Window (or window substitute) surface
  43      */
  44     @Native public static final int WINDOW          = 1;
  45     /**
  46      * Render-To Plain surface (Render Target surface for Direct3D)

  47      */
  48     @Native public static final int RT_PLAIN        = 2;
  49     /**
  50      * Texture surface
  51      */
  52     @Native public static final int TEXTURE         = 3;
  53     /**
  54      * A back-buffer surface (SwapChain surface for Direct3D, backbuffer for
  55      * OpenGL)
  56      */
  57     @Native public static final int FLIP_BACKBUFFER = 4;
  58     /**
  59      * Render-To Texture surface (fbobject for OpenGL, texture with render-to
  60      * attribute for Direct3D)
  61      */
  62     @Native public static final int RT_TEXTURE      = 5;
  63 
  64     /**
  65      * Returns {@code int} representing surface's type as defined by constants
  66      * in this interface.


< prev index next >