summaryrefslogtreecommitdiffstats
path: root/src/demos/hdr/HDR.java
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2013-04-18 03:40:40 +0200
committerSven Gothel <[email protected]>2013-04-18 03:40:40 +0200
commitaffa7c075773cbafdd815c81422bb280bccf6aac (patch)
tree8bc41f6c9964d2729af10d29f426984fd47d09f3 /src/demos/hdr/HDR.java
parentf8b936ff873536d54c711ec272a2df7a1dbd5ae9 (diff)
Adapt to JOGL changes commit fd418a69eca7b8c1bb74244982305fc6004d0a52
Note: We have to find an independent impl. of HDR demo, due to removal of pbuffer floating point texture properties.
Diffstat (limited to 'src/demos/hdr/HDR.java')
-rwxr-xr-xsrc/demos/hdr/HDR.java13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/demos/hdr/HDR.java b/src/demos/hdr/HDR.java
index 1a2c6a1..faab668 100755
--- a/src/demos/hdr/HDR.java
+++ b/src/demos/hdr/HDR.java
@@ -45,6 +45,9 @@ import javax.swing.JOptionPane;
/** HDR demo by NVidia Corporation - Simon Green, [email protected] <P>
Ported to Java by Kenneth Russell
+
+ Currently not working due to loss of pbuffer attributes [floating point buffer, etc].
+ Need to evaluate proper floating point texture solution.
*/
public class HDR extends Demo {
@@ -307,7 +310,6 @@ public class HDR extends Demo {
GLCapabilities caps = new GLCapabilities(null);
caps.setDoubleBuffered(false);
- caps.setPbufferFloatingPointBuffers(true);
caps.setRedBits(floatBits);
caps.setGreenBits(floatBits);
caps.setBlueBits(floatBits);
@@ -347,7 +349,6 @@ public class HDR extends Demo {
blur2_pbuffer.addGLEventListener(new Blur2PbufferListener());
gl.glGenTextures(1, tmp, 0);
blur2_pbuffer_tex = tmp[0];
- caps.setPbufferFloatingPointBuffers(false);
caps.setRedBits(8);
caps.setGreenBits(8);
caps.setBlueBits(8);
@@ -605,10 +606,12 @@ public class HDR extends Demo {
// FIXME: what about the ExaminerViewer?
setPerspectiveProjection(gl, pbuffer_w, pbuffer_h);
+ @SuppressWarnings("deprecation")
GLPbuffer pbuffer = (GLPbuffer) drawable;
- int fpmode = pbuffer.getFloatingPointMode();
+ int fpmode = 0; // FIXME: pbuffer.getFloatingPointMode();
int texmode = 0;
switch (fpmode) {
+ /** FIXME
case GLPbuffer.NV_FLOAT:
System.err.println("Creating HILO cubemap");
hdr_tex = hdr.createCubemapHILO(gl, true);
@@ -626,10 +629,12 @@ public class HDR extends Demo {
hdr_tex = hdr.createCubemap(gl, GL2.GL_RGB_FLOAT16_ATI);
texmode = GL2.GL_RGBA_FLOAT16_ATI;
break;
+ */
default:
throw new RuntimeException("Unexpected floating-point mode " + fpmode);
}
+ /**
if (useCg) {
initCg(gl);
} else {
@@ -637,7 +642,7 @@ public class HDR extends Demo {
}
initBlurCode(gl, blurWidth);
- pipeline.initFloatingPointTexture(gl, pbuffer_tex, pbuffer_w, pbuffer_h);
+ pipeline.initFloatingPointTexture(gl, pbuffer_tex, pbuffer_w, pbuffer_h); */
}
public void display(GLAutoDrawable drawable) {