diff options
author | Sven Gothel <[email protected]> | 2014-07-01 21:02:21 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2014-07-01 21:02:21 +0200 |
commit | 36327e24cf586b50bf18e87d7d13d53eb41cf1d9 (patch) | |
tree | b34c88274eebce4839ee18b5958a2019de565b87 /make | |
parent | a0498e240b9dfde345a704ec6de1d6abcee7b318 (diff) |
Bug 1021: Add OculusVR distortion renderer (single FBO and dual FBO); Add GLEventListener2 (WIP); Refine FloatUtil
- GLEventListener2 extends GLEventListener adds refined control:
- display w/ flags, i.e. repeat, don't clear
- setProjectionModelview(..)
- FloatUtil.* Add return value for chaining, where missing
+++
- jogamp.opengl.oculusvr.OVRDistortion
- Handles all OVR related data and maps it to shader + GL buffers
- display method
- com.jogamp.opengl.oculusvr.OVRSBSRendererSingleFBO implements GLEventListener
- Simple OVRDistortion renderer using single FBO
- Using upstream GLEventListener2 (the content)
- com.jogamp.opengl.oculusvr.OVRSBSRendererDualFBO implements GLEventListener
- Simple OVRDistortion renderer using two FBOs
- Using upstream GLEventListener2 (the content)
Manual Test: com.jogamp.opengl.test.junit.jogl.stereo.ovr.OVRDemo01
Diffstat (limited to 'make')
-rw-r--r-- | make/build-common.xml | 14 | ||||
-rw-r--r-- | make/build-oculusvr.xml | 38 | ||||
-rw-r--r-- | make/build-test.xml | 25 | ||||
-rw-r--r-- | make/scripts/tests.sh | 8 |
4 files changed, 75 insertions, 10 deletions
diff --git a/make/build-common.xml b/make/build-common.xml index 4eafd5386..583425043 100644 --- a/make/build-common.xml +++ b/make/build-common.xml @@ -513,6 +513,20 @@ <path refid="nativewindow_all_atoms.classpath" /> <path refid="jogl_all_atoms.classpath" /> <path refid="newt_all_atoms.classpath" /> + </path> + + <path id="junit_jogl_newt_oculusvr.compile.classpath"> + <pathelement location="${junit.jar}" /> + <pathelement location="${ant.jar}" /> + <pathelement location="${ant-junit.jar}" /> + <pathelement location="${ant-junit4.jar}" /> + <pathelement location="${semver.jar}" /> + <pathelement location="${gluegen-rt.jar}" /> + <pathelement location="${gluegen-test-util.jar}" /> + <pathelement location="${swt.jar}" /> + <path refid="nativewindow_all_atoms.classpath" /> + <path refid="jogl_all_atoms.classpath" /> + <path refid="newt_all_atoms.classpath" /> <path refid="oculusvr_all_atoms.classpath"/> </path> diff --git a/make/build-oculusvr.xml b/make/build-oculusvr.xml index c9370c547..15ed6bde4 100644 --- a/make/build-oculusvr.xml +++ b/make/build-oculusvr.xml @@ -16,9 +16,15 @@ --> <target name="partitioning.setup" depends="common.init"> <property name="java.part.oculusvr" - value="com/jogamp/oculusvr/* jogamp/oculusvr/*"/> + value="com/jogamp/oculusvr/**"/> + <property name="java.part.opengl.oculusvr" + value="com/jogamp/opengl/oculusvr/** jogamp/opengl/oculusvr/**"/> <property name="java.part.oculusvr.exclude" - value="com/jogamp/oculusvr/renderer/*" /> + value="" /> + <property name="java.part.oculusvr.shadercode" + value="jogamp/opengl/oculusvr/shader/**"/> + <property name="java.part.nonjava" + value="${java.part.oculusvr.shadercode}"/> </target> <!-- ================================================================== --> @@ -127,7 +133,7 @@ <!-- Now check for the presence of one well-known file --> <uptodate property="java.generate.skip.ovr" - targetfile="${src.generated.java}/com/jogamp/oculusvr/OVR.java"> + targetfile="${src.generated.java}/com/jogamp/opengl/oculusvr/OVR.java"> <srcfiles refid="stub.includes.dependencies.fileset.1" /> <srcfiles refid="stub.includes.dependencies.fileset.2" /> <srcfiles refid="stub.includes.dependencies.fileset.3" /> @@ -161,7 +167,22 @@ <!-- ================================================================== --> <target name="java.compile" depends="java.generate"> - <!-- Perform the second pass Java compile; everything except portion of fixed function emulation depending on generated code. --> + <!-- Pure non JOGL OculusVR part --> + <javac destdir="${classes}" + excludes="${java.part.oculusvr.exclude} ${java.part.opengl.oculusvr}" + fork="yes" + includeAntRuntime="false" + memoryMaximumSize="${javac.memorymax}" + encoding="UTF-8" + source="${target.sourcelevel}" + target="${target.targetlevel}" + bootclasspath="${target.rt.jar}" + debug="${javacdebug}" debuglevel="${javacdebuglevel}"> + <classpath refid="nativewindow_gluegen.classpath"/> + <src path="${src.java}" /> + <src path="${src.generated.java}" /> + </javac> + <!-- Add JOGL OculusVR part --> <javac destdir="${classes}" excludes="${java.part.oculusvr.exclude}" fork="yes" @@ -172,11 +193,16 @@ target="${target.targetlevel}" bootclasspath="${target.rt.jar}" debug="${javacdebug}" debuglevel="${javacdebuglevel}"> - <!-- classpath refid="nativewindow_gluegen.classpath"/ --> <classpath refid="jogl_nativewindow_gluegen.classpath"/> <src path="${src.java}" /> <src path="${src.generated.java}" /> </javac> + <!-- make shadercode and fonts available in classpath --> + <copy todir="${classes}"> + <fileset dir="${src.java}" + includes="${java.part.nonjava}" + excludes="**/*.java"/> + </copy> </target> <!-- ================================================================== --> @@ -616,7 +642,7 @@ <target name="build-jars-javase" depends="setup-manifestfile"> <jar manifest="${build.oculusvr}/manifest.mf" destfile="${build.oculusvr}/oculusvr.jar" filesonly="true"> <fileset dir="${classes}" - includes="${java.part.oculusvr}" + includes="${java.part.oculusvr} ${java.part.opengl.oculusvr}" excludes="${java.part.oculusvr.exclude}"/> </jar> <jar manifest="${build.oculusvr}/manifest.mf" destfile="${build.oculusvr}/oculusvr-natives-${os.and.arch}.jar" filesonly="true"> diff --git a/make/build-test.xml b/make/build-test.xml index 10c00c865..daa5e563d 100644 --- a/make/build-test.xml +++ b/make/build-test.xml @@ -28,6 +28,7 @@ <property name="java.part.test.all" value="com/jogamp/** jogamp/**"/> <property name="java.part.test.android" value="com/jogamp/opengl/test/android/**"/> + <property name="java.part.test.oculusvr" value="com/jogamp/opengl/test/junit/jogl/stereo/ovr/**"/> <property name="java.dir.test" value="com/jogamp/opengl/test"/> <property name="java.dir.junit" value="${java.dir.test}/junit"/> <property name="java.dir.bugs" value="${java.dir.test}/bugs"/> @@ -62,10 +63,10 @@ <!-- - Build/run tests/junit. --> - <target name="test.compile.javase"> - <!-- Perform the junit pass Java SE compile --> + + <target name="test.compile.javase.generic"> <javac destdir="${classes}" - excludes="${java.part.test.android}" + excludes="${java.part.test.android} ${java.part.test.oculusvr}" fork="yes" includeAntRuntime="false" memoryMaximumSize="${javac.memorymax}" @@ -77,6 +78,24 @@ <classpath refid="junit_jogl_newt.compile.classpath"/> <src path="${src.test}" /> </javac> + </target> + <target name="test.compile.javase.oculusvr" if="oculusvr.sdk.available"> + <javac destdir="${classes}" + includes="${java.part.test.oculusvr}" + excludes="${java.part.test.android}" + fork="yes" + includeAntRuntime="false" + memoryMaximumSize="${javac.memorymax}" + encoding="UTF-8" + source="${target.sourcelevel}" + target="${target.targetlevel}" + bootclasspath="${target.rt.jar}" + debug="${javacdebug}" debuglevel="${javacdebuglevel}"> + <classpath refid="junit_jogl_newt_oculusvr.compile.classpath"/> + <src path="${src.test}" /> + </javac> + </target> + <target name="test.compile.javase" depends="test.compile.javase.generic, test.compile.javase.oculusvr"> <copy file="joglversion-test" tofile="${build.test}/manifest-test.mf" overwrite="true"> diff --git a/make/scripts/tests.sh b/make/scripts/tests.sh index fe6d70db8..dd7c2c0a0 100644 --- a/make/scripts/tests.sh +++ b/make/scripts/tests.sh @@ -124,6 +124,7 @@ function jrun() { #D_ARGS="-Djogl.debug.GLBufferObjectTracker" #D_ARGS="-Djogl.debug.GLBufferObjectTracker -Djogl.debug.GLArrayData -Djogl.debug.TraceGL -Djogl.debug.DebugGL" #D_ARGS="-Djogl.debug.GLSLCode" + #D_ARGS="-Djogl.debug.GLSLCode -Djogl.debug.TraceGL" #D_ARGS="-Djogl.debug.GLSLCode -Djogl.debug.DebugGL" #D_ARGS="-Djogl.debug.GLContext -Dnativewindow.debug.JAWT -Dnewt.debug.Window" #D_ARGS="-Dnativewindow.debug.JAWT -Djogl.debug.GLCanvas" @@ -367,6 +368,11 @@ function testawtswt() { #testnoawt com.jogamp.opengl.test.junit.jogl.acore.TestVersionSemanticsNOUI $* # +# Stereo +# +testnoawt com.jogamp.opengl.test.junit.jogl.stereo.ovr.OVRDemo01 $* + +# # HiDPI # #testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT $* @@ -394,7 +400,7 @@ function testawtswt() { #testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestLandscapeES2NEWT $* #testawtswt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NewtCanvasSWT $* #testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestElektronenMultipliziererNEWT $* -testnoawtatomics com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT $* +#testnoawtatomics com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT $* #testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NEWT $* #testnoawt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestRedSquareES2NEWT $* #testswt com.jogamp.opengl.test.junit.jogl.demos.es2.newt.TestGearsES2NewtCanvasSWT $* |