Java Code Examples for sun.awt.Win32GraphicsConfig#createBackBuffer()
The following examples show how to use
sun.awt.Win32GraphicsConfig#createBackBuffer() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: WComponentPeer.java From dragonwell8_jdk with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 2
Source File: WComponentPeer.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 3
Source File: WComponentPeer.java From jdk8u60 with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 4
Source File: WComponentPeer.java From openjdk-jdk8u with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 5
Source File: WComponentPeer.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 6
Source File: WComponentPeer.java From openjdk-jdk9 with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 7
Source File: WComponentPeer.java From jdk8u-jdk with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 8
Source File: WComponentPeer.java From hottub with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 9
Source File: WComponentPeer.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 10
Source File: WComponentPeer.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 11
Source File: WComponentPeer.java From jdk8u_jdk with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 12
Source File: WComponentPeer.java From jdk8u-jdk with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }
Example 13
Source File: WComponentPeer.java From jdk8u-dev-jdk with GNU General Public License v2.0 | 4 votes |
/** * Multi-buffer version of replaceSurfaceData. This version is called * by createBuffers(), which needs to acquire the same locks in the same * order, but also needs to perform additional functions inside the * locks. */ public void replaceSurfaceData(int newNumBackBuffers, BufferCapabilities caps) { SurfaceData oldData = null; VolatileImage oldBB = null; synchronized(((Component)target).getTreeLock()) { synchronized(this) { if (pData == 0) { return; } numBackBuffers = newNumBackBuffers; ScreenUpdateManager mgr = ScreenUpdateManager.getInstance(); oldData = surfaceData; mgr.dropScreenSurface(oldData); createScreenSurface(true); if (oldData != null) { oldData.invalidate(); } oldBB = backBuffer; if (numBackBuffers > 0) { // set the caps first, they're used when creating the bb backBufferCaps = caps; Win32GraphicsConfig gc = (Win32GraphicsConfig)getGraphicsConfiguration(); backBuffer = gc.createBackBuffer(this); } else if (backBuffer != null) { backBufferCaps = null; backBuffer = null; } } } // it would be better to do this before we create new ones, // but then we'd run into deadlock issues if (oldData != null) { oldData.flush(); // null out the old data to make it collected faster oldData = null; } if (oldBB != null) { oldBB.flush(); // null out the old data to make it collected faster oldData = null; } }