Bug 1169 - ScreenResSelector doesn't use the right mean of detecting multi bit depth
: ScreenResSelector doesn't use the right mean of detecting multi bit depth
Status: RESOLVED WORKSFORME
: None
: Jogl
: JogAmp
: awt (show other bugs)
: 2.4.0
: All all
: P5 trivial
: Julien Gouesse
:
:
:
 
Reported: 2015-07-02 11:01 CEST by Julien Gouesse
Modified: 2019-03-30 06:23 CET (History)
2 users (show)

:
Type: DEFECT
SCM Refs:
Workaround: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Julien Gouesse 2015-07-02 11:01:38 CEST
This demo assumes that java.awt.DisplayMode.getBitDepth() returns a strictly negative number when multiple bit depths are supported:
https://github.com/sgothel/jogl-demos/blob/master/src/demos/util/ScreenResSelector.java#L66

Actually, the documentation indicates that there is only one possible value in this case:
http://docs.oracle.com/javase/7/docs/api/java/awt/DisplayMode.html#getBitDepth()

It should use java.awt.DisplayMode.BIT_DEPTH_MULTI:
http://docs.oracle.com/javase/7/docs/api/java/awt/DisplayMode.html#BIT_DEPTH_MULTI
Comment 1 Sven Gothel 2015-10-09 06:37:21 CEST
pls fix ..
Comment 2 Sven Gothel 2019-03-30 03:13:06 CET
(In reply to Sven Gothel from comment #1)
> pls fix ..

and java.awt.DisplayMode.BIT_DEPTH_MULTI == -1

well, closing this bug report for this old 2003 demo ;-)