diff options
Diffstat (limited to 'src/jogl/classes/jogamp/opengl/windows/wgl')
3 files changed, 15 insertions, 15 deletions
diff --git a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLDrawableFactory.java b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLDrawableFactory.java index f8ba8d277..b7941c3bb 100644 --- a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLDrawableFactory.java +++ b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLDrawableFactory.java @@ -414,7 +414,7 @@ public class WindowsWGLDrawableFactory extends GLDrawableFactoryImpl { RegisteredClassFactory.shutdownSharedClasses(); } - protected List/*GLCapabilitiesImmutable*/ getAvailableCapabilitiesImpl(AbstractGraphicsDevice device) { + protected List<GLCapabilitiesImmutable> getAvailableCapabilitiesImpl(AbstractGraphicsDevice device) { return WindowsWGLGraphicsConfigurationFactory.getAvailableCapabilities(this, device); } diff --git a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfiguration.java b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfiguration.java index 8859d636a..a82a7a38c 100644 --- a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfiguration.java +++ b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfiguration.java @@ -299,10 +299,10 @@ public class WindowsWGLGraphicsConfiguration extends DefaultGraphicsConfiguratio throw new GLException("wglARBPFID2GLCapabilities: Error getting pixel format attributes for pixel format " + pfdID + " of device context " + toHexString(hdc) + ", werr " + GDI.GetLastError()); } - ArrayList bucket = new ArrayList(1); + ArrayList<WGLGLCapabilities> bucket = new ArrayList<WGLGLCapabilities>(1); final int winattrbits = GLGraphicsConfigurationUtil.getWinAttributeBits(onscreen, usePBuffer); if(AttribList2GLCapabilities(bucket, glp, hdc, pfdID, iattributes, niattribs, iresults, winattrbits)) { - return (WGLGLCapabilities) bucket.get(0); + return bucket.get(0); } return null; } @@ -376,7 +376,7 @@ public class WindowsWGLGraphicsConfiguration extends DefaultGraphicsConfiguratio int[] iresults = new int [2*MAX_ATTRIBS]; int niattribs = fillAttribsForGeneralWGLARBQuery(sharedResource, iattributes); - ArrayList bucket = new ArrayList(); + ArrayList<GLCapabilitiesImmutable> bucket = new ArrayList<GLCapabilitiesImmutable>(); for(int i = 0; i<numFormats; i++) { if ( pfdIDs[i] >= 1 && @@ -578,7 +578,7 @@ public class WindowsWGLGraphicsConfiguration extends DefaultGraphicsConfiguratio return val; } - static boolean AttribList2GLCapabilities( ArrayList capsBucket, + static boolean AttribList2GLCapabilities( ArrayList<? extends GLCapabilitiesImmutable> capsBucket, final GLProfile glp, final long hdc, final int pfdID, final int[] iattribs, final int niattribs, final int[] iresults, final int winattrmask) { @@ -590,7 +590,7 @@ public class WindowsWGLGraphicsConfiguration extends DefaultGraphicsConfiguratio } PIXELFORMATDESCRIPTOR pfd = createPixelFormatDescriptor(); - if (GDI.DescribePixelFormat(hdc, pfdID, pfd.size(), pfd) == 0) { + if (GDI.DescribePixelFormat(hdc, pfdID, PIXELFORMATDESCRIPTOR.size(), pfd) == 0) { // remove displayable bits, since pfdID is non displayable drawableTypeBits = drawableTypeBits & ~(GLGraphicsConfigurationUtil.WINDOW_BIT | GLGraphicsConfigurationUtil.BITMAP_BIT); if( 0 == drawableTypeBits ) { @@ -637,14 +637,14 @@ public class WindowsWGLGraphicsConfiguration extends DefaultGraphicsConfiguratio static WGLGLCapabilities PFD2GLCapabilities(GLProfile glp, long hdc, int pfdID, boolean onscreen) { final int winattrmask = GLGraphicsConfigurationUtil.getWinAttributeBits(onscreen, false); - ArrayList capsBucket = new ArrayList(1); + ArrayList<WGLGLCapabilities> capsBucket = new ArrayList<WGLGLCapabilities>(1); if( PFD2GLCapabilities(capsBucket, glp, hdc, pfdID, winattrmask) ) { - return (WGLGLCapabilities) capsBucket.get(0); + return capsBucket.get(0); } return null; } - static boolean PFD2GLCapabilities(ArrayList capsBucket, final GLProfile glp, final long hdc, final int pfdID, final int winattrmask) { + static boolean PFD2GLCapabilities(ArrayList<? extends GLCapabilitiesImmutable> capsBucket, final GLProfile glp, final long hdc, final int pfdID, final int winattrmask) { PIXELFORMATDESCRIPTOR pfd = createPixelFormatDescriptor(hdc, pfdID); if(null == pfd) { return false; diff --git a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfigurationFactory.java b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfigurationFactory.java index d765572a6..1c607d2c7 100644 --- a/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfigurationFactory.java +++ b/src/jogl/classes/jogamp/opengl/windows/wgl/WindowsWGLGraphicsConfigurationFactory.java @@ -105,7 +105,7 @@ public class WindowsWGLGraphicsConfigurationFactory extends GLGraphicsConfigurat return new WindowsWGLGraphicsConfiguration( absScreen, capsChosen, capsReq, (GLCapabilitiesChooser)chooser ); } - protected static List/*<WGLGLCapabilities>*/ getAvailableCapabilities(WindowsWGLDrawableFactory factory, AbstractGraphicsDevice device) { + protected static List<GLCapabilitiesImmutable> getAvailableCapabilities(WindowsWGLDrawableFactory factory, AbstractGraphicsDevice device) { WindowsWGLDrawableFactory.SharedResource sharedResource = factory.getOrCreateSharedResource(device); if(null == sharedResource) { throw new GLException("Shared resource for device n/a: "+device); @@ -113,7 +113,7 @@ public class WindowsWGLGraphicsConfigurationFactory extends GLGraphicsConfigurat WindowsWGLDrawable sharedDrawable = sharedResource.getDrawable(); GLCapabilitiesImmutable capsChosen = sharedDrawable.getChosenGLCapabilities(); WindowsWGLContext sharedContext = sharedResource.getContext(); - List availableCaps = null; + List/*<GLCapabilitiesImmutable>*/ availableCaps = null; if ( sharedResource.needsCurrentContext4ARBPFDQueries() ) { if(GLContext.CONTEXT_NOT_CURRENT == sharedContext.makeCurrent()) { @@ -147,15 +147,15 @@ public class WindowsWGLGraphicsConfigurationFactory extends GLGraphicsConfigurat return availableCaps; } - static List/*<WGLGLCapabilities>*/ getAvailableGLCapabilitiesARB(long hdc, WindowsWGLDrawableFactory.SharedResource sharedResource, GLProfile glProfile) { + static List/*<GLCapabilitiesImmutable>*/ getAvailableGLCapabilitiesARB(long hdc, WindowsWGLDrawableFactory.SharedResource sharedResource, GLProfile glProfile) { int[] pformats = WindowsWGLGraphicsConfiguration.wglAllARBPFIDs(sharedResource.getContext(), hdc); return WindowsWGLGraphicsConfiguration.wglARBPFIDs2AllGLCapabilities(sharedResource, hdc, pformats, glProfile); } - static List/*<WGLGLCapabilities>*/ getAvailableGLCapabilitiesGDI(long hdc, GLProfile glProfile) { + static List/*<GLCapabilitiesImmutable>*/ getAvailableGLCapabilitiesGDI(long hdc, GLProfile glProfile) { int[] pformats = WindowsWGLGraphicsConfiguration.wglAllGDIPFIDs(hdc); int numFormats = pformats.length; - ArrayList bucket = new ArrayList(numFormats); + ArrayList<GLCapabilitiesImmutable> bucket = new ArrayList<GLCapabilitiesImmutable>(numFormats); for (int i = 0; i < numFormats; i++) { WindowsWGLGraphicsConfiguration.PFD2GLCapabilities(bucket, glProfile, hdc, pformats[i], GLGraphicsConfigurationUtil.ALL_BITS); } @@ -391,7 +391,7 @@ public class WindowsWGLGraphicsConfigurationFactory extends GLGraphicsConfigurat if( null == pixelFormatCaps) { throw new GLException("Null Capabilities with "+ " chosen pfdID: native recommended "+ (recommendedIndex+1) + - " chosen "+pixelFormatCaps.getPFDID()); + " chosen idx "+chosenIndex); } if (DEBUG) { System.err.println("!!! chosen pfdID (ARB): native recommended "+ (recommendedIndex+1) + |