aboutsummaryrefslogtreecommitdiffstats
path: root/src/test/com
diff options
context:
space:
mode:
authorSven Gothel <[email protected]>2013-06-14 17:51:45 +0200
committerSven Gothel <[email protected]>2013-06-14 17:51:45 +0200
commita83aea49479818a1e5037d11a3e7f7d1f019c939 (patch)
treed98bbacb4a55a3e65b8f5b3c2d6a0d4c989526ce /src/test/com
parent33b4f95581938ebbb5af4c37a1c5c2b5ee968f76 (diff)
Fix Bug 745: NPE - QTT definition shall be allowd to _follow_ SOF (frame) - Reference QTT via QTT[] passed to frame, validate after parsing.
Diffstat (limited to 'src/test/com')
-rw-r--r--src/test/com/jogamp/opengl/test/junit/jogl/util/texture/TestJPEGTextureFromFileNEWT.java21
-rw-r--r--src/test/com/jogamp/opengl/test/junit/jogl/util/texture/bug745_qttdef_post_frame.jpgbin0 -> 8415 bytes
2 files changed, 19 insertions, 2 deletions
diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/util/texture/TestJPEGTextureFromFileNEWT.java b/src/test/com/jogamp/opengl/test/junit/jogl/util/texture/TestJPEGTextureFromFileNEWT.java
index 55e8152ae..82867f9e6 100644
--- a/src/test/com/jogamp/opengl/test/junit/jogl/util/texture/TestJPEGTextureFromFileNEWT.java
+++ b/src/test/com/jogamp/opengl/test/junit/jogl/util/texture/TestJPEGTextureFromFileNEWT.java
@@ -74,6 +74,8 @@ public class TestJPEGTextureFromFileNEWT extends UITestCase {
InputStream testTextureStream03CMYK_01;
InputStream testTextureStream03YCCK_01;
+ InputStream testTextureStream04QTTDefPostFrame;
+
@Before
public void initTest() throws IOException {
{
@@ -132,6 +134,13 @@ public class TestJPEGTextureFromFileNEWT extends UITestCase {
testTextureStream03YCCK_01 = testTextureUrlConn.getInputStream();
Assert.assertNotNull(testTextureStream03YCCK_01);
}
+ {
+ URLConnection testTextureUrlConn = IOUtil.getResource(this.getClass(), "bug745_qttdef_post_frame.jpg");
+ Assert.assertNotNull(testTextureUrlConn);
+ testTextureStream04QTTDefPostFrame = testTextureUrlConn.getInputStream();
+ Assert.assertNotNull(testTextureStream04QTTDefPostFrame);
+ }
+
}
@After
@@ -142,7 +151,10 @@ public class TestJPEGTextureFromFileNEWT extends UITestCase {
testTextureStream01YUV422h_Prog = null;
testTextureStream02YUV420_Base = null;
testTextureStream02YUV420_Prog = null;
- testTextureStream02YUV420_BaseGray = null;
+ testTextureStream02YUV420_BaseGray = null;
+ testTextureStream03CMYK_01 = null;
+ testTextureStream03YCCK_01 = null;
+ testTextureStream04QTTDefPostFrame = null;
}
public void testImpl(boolean useFFP, final InputStream istream) throws InterruptedException, IOException {
@@ -241,7 +253,7 @@ public class TestJPEGTextureFromFileNEWT extends UITestCase {
@Test
public void test02YUV420BaseGray_ES2() throws InterruptedException, IOException {
testImpl(false, testTextureStream02YUV420_BaseGray);
- }
+ }
@Test
public void test03CMYK_01_ES2() throws InterruptedException, IOException {
@@ -251,6 +263,11 @@ public class TestJPEGTextureFromFileNEWT extends UITestCase {
public void test03YCCK_01_ES2() throws InterruptedException, IOException {
testImpl(false, testTextureStream03YCCK_01);
}
+
+ @Test
+ public void test04QTTDefPostFrame_ES2() throws InterruptedException, IOException {
+ testImpl(false, testTextureStream04QTTDefPostFrame);
+ }
public static void main(String args[]) throws IOException {
for(int i=0; i<args.length; i++) {
diff --git a/src/test/com/jogamp/opengl/test/junit/jogl/util/texture/bug745_qttdef_post_frame.jpg b/src/test/com/jogamp/opengl/test/junit/jogl/util/texture/bug745_qttdef_post_frame.jpg
new file mode 100644
index 000000000..1c7009321
--- /dev/null
+++ b/src/test/com/jogamp/opengl/test/junit/jogl/util/texture/bug745_qttdef_post_frame.jpg
Binary files differ