You can subscribe to this list here.
| 2002 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(134) |
Sep
(52) |
Oct
(13) |
Nov
(342) |
Dec
(163) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2003 |
Jan
(44) |
Feb
(62) |
Mar
(158) |
Apr
(38) |
May
(70) |
Jun
(58) |
Jul
(104) |
Aug
(207) |
Sep
(83) |
Oct
(122) |
Nov
(23) |
Dec
(49) |
| 2004 |
Jan
(119) |
Feb
(132) |
Mar
(192) |
Apr
(140) |
May
(77) |
Jun
(74) |
Jul
(201) |
Aug
(63) |
Sep
(102) |
Oct
(70) |
Nov
(173) |
Dec
(78) |
| 2005 |
Jan
(174) |
Feb
(197) |
Mar
(105) |
Apr
(59) |
May
(77) |
Jun
(43) |
Jul
(21) |
Aug
(18) |
Sep
(47) |
Oct
(37) |
Nov
(74) |
Dec
(50) |
| 2006 |
Jan
(44) |
Feb
(19) |
Mar
(32) |
Apr
(24) |
May
(31) |
Jun
(55) |
Jul
(138) |
Aug
(28) |
Sep
(12) |
Oct
(41) |
Nov
(58) |
Dec
(24) |
| 2007 |
Jan
(28) |
Feb
(14) |
Mar
(10) |
Apr
(68) |
May
(30) |
Jun
(26) |
Jul
(18) |
Aug
(63) |
Sep
(19) |
Oct
(29) |
Nov
(20) |
Dec
(10) |
| 2008 |
Jan
(38) |
Feb
(7) |
Mar
(37) |
Apr
(120) |
May
(41) |
Jun
(36) |
Jul
(39) |
Aug
(24) |
Sep
(28) |
Oct
(30) |
Nov
(36) |
Dec
(75) |
| 2009 |
Jan
(46) |
Feb
(22) |
Mar
(50) |
Apr
(70) |
May
(134) |
Jun
(105) |
Jul
(75) |
Aug
(34) |
Sep
(38) |
Oct
(34) |
Nov
(19) |
Dec
(20) |
| 2010 |
Jan
(11) |
Feb
(20) |
Mar
(65) |
Apr
(83) |
May
(104) |
Jun
(73) |
Jul
(78) |
Aug
(57) |
Sep
(43) |
Oct
(35) |
Nov
(9) |
Dec
(4) |
| 2011 |
Jan
(21) |
Feb
(11) |
Mar
(18) |
Apr
(10) |
May
(18) |
Jun
(15) |
Jul
(48) |
Aug
(25) |
Sep
(17) |
Oct
(45) |
Nov
(15) |
Dec
(12) |
| 2012 |
Jan
(21) |
Feb
(9) |
Mar
(12) |
Apr
(9) |
May
(9) |
Jun
(5) |
Jul
(1) |
Aug
(10) |
Sep
(12) |
Oct
(1) |
Nov
(28) |
Dec
(5) |
| 2013 |
Jan
(4) |
Feb
(1) |
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| 2014 |
Jan
|
Feb
(1) |
Mar
(1) |
Apr
|
May
(2) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
|
| 2015 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
(2) |
Nov
|
Dec
|
| 2016 |
Jan
(2) |
Feb
(1) |
Mar
(1) |
Apr
(1) |
May
(2) |
Jun
|
Jul
(1) |
Aug
(2) |
Sep
|
Oct
|
Nov
(1) |
Dec
|
| 2017 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(1) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
| S | M | T | W | T | F | S |
|---|---|---|---|---|---|---|
|
|
|
|
1
(2) |
2
(2) |
3
(1) |
4
(2) |
|
5
(2) |
6
(3) |
7
(1) |
8
(3) |
9
(4) |
10
(5) |
11
(1) |
|
12
|
13
|
14
(2) |
15
(1) |
16
(1) |
17
(1) |
18
(1) |
|
19
(2) |
20
(3) |
21
(2) |
22
(3) |
23
(2) |
24
(5) |
25
(3) |
|
26
(2) |
27
(3) |
28
(4) |
29
(4) |
30
(5) |
|
|
|
From: <ma...@us...> - 2009-04-30 18:50:18
|
Revision: 3208
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3208&view=rev
Author: matzon
Date: 2009-04-30 18:50:00 +0000 (Thu, 30 Apr 2009)
Log Message:
-----------
preparing 2.2.0
Modified Paths:
--------------
trunk/LWJGL/src/java/org/lwjgl/Sys.java
Modified: trunk/LWJGL/src/java/org/lwjgl/Sys.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/Sys.java 2009-04-30 18:48:34 UTC (rev 3207)
+++ trunk/LWJGL/src/java/org/lwjgl/Sys.java 2009-04-30 18:50:00 UTC (rev 3208)
@@ -54,7 +54,7 @@
private static final String JNI_LIBRARY_NAME = "lwjgl";
/** Current version of library */
- private static final String VERSION = "2.1.0";
+ private static final String VERSION = "2.2.0";
/** The implementation instance to delegate platform specific behavior to */
private final static SysImplementation implementation;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2009-04-30 18:48:41
|
Revision: 3207
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3207&view=rev
Author: matzon
Date: 2009-04-30 18:48:34 +0000 (Thu, 30 Apr 2009)
Log Message:
-----------
preparing 2.2.0
Modified Paths:
--------------
trunk/LWJGL/platform_build/build-definitions.xml
Modified: trunk/LWJGL/platform_build/build-definitions.xml
===================================================================
--- trunk/LWJGL/platform_build/build-definitions.xml 2009-04-30 18:40:25 UTC (rev 3206)
+++ trunk/LWJGL/platform_build/build-definitions.xml 2009-04-30 18:48:34 UTC (rev 3207)
@@ -12,7 +12,7 @@
<property name="lwjgl.docs" location="doc" />
<property name="lwjgl.temp" location="temp" />
<property name="lwjgl.res" location="res" />
- <property name="lwjgl.version" value="2.1.0" />
+ <property name="lwjgl.version" value="2.2.0" />
<property name="opengl-template-pattern" value="org/lwjgl/opengl/GL*.java,org/lwjgl/opengl/ARB*.java,org/lwjgl/opengl/ATI*.java,org/lwjgl/opengl/EXT*.java,org/lwjgl/opengl/NV*.java,org/lwjgl/opengl/HP*.java,org/lwjgl/opengl/IBM*.java,org/lwjgl/opengl/SUN*.java,org/lwjgl/opengl/SGIS*.java"/>
<!-- ================================================================== -->
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ma...@us...> - 2009-04-30 18:40:43
|
Revision: 3206
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3206&view=rev
Author: matzon
Date: 2009-04-30 18:40:25 +0000 (Thu, 30 Apr 2009)
Log Message:
-----------
updated text to match new location for windows. added solaris.
Modified Paths:
--------------
trunk/LWJGL/doc/README
Modified: trunk/LWJGL/doc/README
===================================================================
--- trunk/LWJGL/doc/README 2009-04-29 16:38:04 UTC (rev 3205)
+++ trunk/LWJGL/doc/README 2009-04-30 18:40:25 UTC (rev 3206)
@@ -8,10 +8,10 @@
Extract the archive, and cd into directory
(please substitute ; and \ according to platform)
- java -cp .;res;jar\lwjgl.jar;jar\lwjgl_test.jar;jar\lwjgl_util.jar;jar\jinput.jar; -Djava.library.path=native\<win32|linux|macosx> TEST
+ java -cp .;res;jar\lwjgl.jar;jar\lwjgl_test.jar;jar\lwjgl_util.jar;jar\jinput.jar; -Djava.library.path=native\<windows|linux|macosx|solaris> TEST
(this specifies that the jvm should locate the lwjgl native libs in 'native' directory)
- where TEST is one of the following:
+ where TEST is some of the following:
org.lwjgl.test.WindowCreationTest
org.lwjgl.test.SysTest
@@ -43,7 +43,7 @@
org.lwjgl.test.opengl.shaders.ShadersTest
You may also run the Space invaders demo by executing:
- java -cp .;res;jar\lwjgl.jar;jar\lwjgl_test.jar;jar\lwjgl_util.jar; -Djava.library.path=native\<win32|linux|macosx> org.lwjgl.examples.spaceinvaders.Game
+ java -cp .;res;jar\lwjgl.jar;jar\lwjgl_test.jar;jar\lwjgl_util.jar; -Djava.library.path=native\<windows|linux|macosx|solaris> org.lwjgl.examples.spaceinvaders.Game
Project Webpage: www.lwjgl.org
Project Forum: forum.lwjgl.org
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <sp...@us...> - 2009-04-29 16:38:15
|
Revision: 3205
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3205&view=rev
Author: spasi
Date: 2009-04-29 16:38:04 +0000 (Wed, 29 Apr 2009)
Log Message:
-----------
Added support for NV_shader_buffer_load and NV_vertex_buffer_unified_memory.
Added Paths:
-----------
trunk/LWJGL/src/templates/org/lwjgl/opengl/NV_shader_buffer_load.java
trunk/LWJGL/src/templates/org/lwjgl/opengl/NV_vertex_buffer_unified_memory.java
Added: trunk/LWJGL/src/templates/org/lwjgl/opengl/NV_shader_buffer_load.java
===================================================================
--- trunk/LWJGL/src/templates/org/lwjgl/opengl/NV_shader_buffer_load.java (rev 0)
+++ trunk/LWJGL/src/templates/org/lwjgl/opengl/NV_shader_buffer_load.java 2009-04-29 16:38:04 UTC (rev 3205)
@@ -0,0 +1,86 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+package org.lwjgl.opengl;
+
+import org.lwjgl.util.generator.*;
+
+import java.nio.LongBuffer;
+
+public interface NV_shader_buffer_load {
+
+ /**
+ * Accepted by the <pname> parameter of GetBufferParameterui64vNV,
+ * GetNamedBufferParameterui64vNV:
+ */
+ int GL_BUFFER_GPU_ADDRESS_NV = 0x8F1D;
+
+ /** Returned by the <type> parameter of GetActiveUniform: */
+ int GL_GPU_ADDRESS_NV = 0x8F34;
+
+ /** Accepted by the <value> parameter of GetIntegerui64vNV: */
+ int GL_MAX_SHADER_BUFFER_ADDRESS_NV = 0x8F35;
+
+ void glMakeBufferResidentNV(@GLenum int target, @GLenum int access);
+
+ void glMakeBufferNonResidentNV(@GLenum int target);
+
+ boolean glIsBufferResidentNV(@GLenum int target);
+
+ void glNamedMakeBufferResidentNV(@GLuint int buffer, @GLenum int access);
+
+ void glNamedMakeBufferNonResidentNV(@GLuint int buffer);
+
+ boolean glIsNamedBufferResidentNV(@GLuint int buffer);
+
+ @StripPostfix("params")
+ void glGetBufferParameterui64vNV(@GLenum int target, @GLenum int pname, @OutParameter @Check("1") @GLuint64EXT LongBuffer params);
+
+ @StripPostfix("params")
+ void glGetNamedBufferParameterui64vNV(@GLuint int buffer, @GLenum int pname, @OutParameter @Check("1") @GLuint64EXT LongBuffer params);
+
+ @StripPostfix("result")
+ void glGetIntegerui64vNV(@GLenum int value, @OutParameter @Check("1") @GLuint64EXT LongBuffer result);
+
+ void glUniformui64NV(int location, @GLuint64EXT long value);
+
+ @StripPostfix("value")
+ void glUniformui64vNV(int location, @AutoSize("value") @GLsizei int count, @GLuint64EXT LongBuffer value);
+
+ @StripPostfix("params")
+ void glGetUniformui64vNV(@GLuint int program, int location, @OutParameter @Check("1") @GLuint64EXT LongBuffer params);
+
+ void glProgramUniformui64NV(@GLuint int program, int location, @GLuint64EXT long value);
+
+ @StripPostfix("value")
+ void glProgramUniformui64vNV(@GLuint int program, int location, @AutoSize("value") @GLsizei int count, @GLuint64EXT LongBuffer value);
+
+}
\ No newline at end of file
Added: trunk/LWJGL/src/templates/org/lwjgl/opengl/NV_vertex_buffer_unified_memory.java
===================================================================
--- trunk/LWJGL/src/templates/org/lwjgl/opengl/NV_vertex_buffer_unified_memory.java (rev 0)
+++ trunk/LWJGL/src/templates/org/lwjgl/opengl/NV_vertex_buffer_unified_memory.java 2009-04-29 16:38:04 UTC (rev 3205)
@@ -0,0 +1,106 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+package org.lwjgl.opengl;
+
+import org.lwjgl.util.generator.*;
+
+import java.nio.LongBuffer;
+
+public interface NV_vertex_buffer_unified_memory {
+
+ /**
+ * Accepted by the <cap> parameter of DisableClientState,
+ * EnableClientState, IsEnabled:
+ */
+ int GL_VERTEX_ATTRIB_ARRAY_UNIFIED_NV = 0x8F1E;
+ int GL_ELEMENT_ARRAY_UNIFIED_NV = 0x8F1F;
+
+ /**
+ * Accepted by the <pname> parameter of BufferAddressRangeNV
+ * and the <value> parameter of GetIntegerui64i_vNV:
+ */
+ int GL_VERTEX_ATTRIB_ARRAY_ADDRESS_NV = 0x8F20;
+ int GL_TEXTURE_COORD_ARRAY_ADDRESS_NV = 0x8F25;
+
+ /**
+ * Accepted by the <pname> parameter of BufferAddressRangeNV
+ * and the <value> parameter of GetIntegerui64vNV:
+ */
+ int GL_VERTEX_ARRAY_ADDRESS_NV = 0x8F21;
+ int GL_NORMAL_ARRAY_ADDRESS_NV = 0x8F22;
+ int GL_COLOR_ARRAY_ADDRESS_NV = 0x8F23;
+ int GL_INDEX_ARRAY_ADDRESS_NV = 0x8F24;
+ int GL_EDGE_FLAG_ARRAY_ADDRESS_NV = 0x8F26;
+ int GL_SECONDARY_COLOR_ARRAY_ADDRESS_NV = 0x8F27;
+ int GL_FOG_COORD_ARRAY_ADDRESS_NV = 0x8F28;
+ int GL_ELEMENT_ARRAY_ADDRESS_NV = 0x8F29;
+
+ /** Accepted by the <target> parameter of GetIntegeri_vNV: */
+ int GL_VERTEX_ATTRIB_ARRAY_LENGTH_NV = 0x8F2A;
+ int GL_TEXTURE_COORD_ARRAY_LENGTH_NV = 0x8F2F;
+
+ /** Accepted by the <value> parameter of GetIntegerv: */
+ int GL_VERTEX_ARRAY_LENGTH_NV = 0x8F2B;
+ int GL_NORMAL_ARRAY_LENGTH_NV = 0x8F2C;
+ int GL_COLOR_ARRAY_LENGTH_NV = 0x8F2D;
+ int GL_INDEX_ARRAY_LENGTH_NV = 0x8F2E;
+ int GL_EDGE_FLAG_ARRAY_LENGTH_NV = 0x8F30;
+ int GL_SECONDARY_COLOR_ARRAY_LENGTH_NV = 0x8F31;
+ int GL_FOG_COORD_ARRAY_LENGTH_NV = 0x8F32;
+ int GL_ELEMENT_ARRAY_LENGTH_NV = 0x8F33;
+
+ void glBufferAddressRangeNV(@GLenum int pname, @GLuint int index, @GLuint64EXT long address, @GLsizeiptr long length);
+
+ void glVertexFormatNV(int size, @GLenum int type, @GLsizei int stride);
+
+ void glNormalFormatNV(@GLenum int type, @GLsizei int stride);
+
+ void glColorFormatNV(int size, @GLenum int type, @GLsizei int stride);
+
+ void glIndexFormatNV(@GLenum int type, @GLsizei int stride);
+
+ void glTexCoordFormatNV(int size, @GLenum int type, @GLsizei int stride);
+
+ void glEdgeFlagFormatNV(@GLsizei int stride);
+
+ void glSecondaryColorFormatNV(int size, @GLenum int type, @GLsizei int stride);
+
+ void glFogCoordFormatNV(@GLenum int type, @GLsizei int stride);
+
+ void glVertexAttribFormatNV(@GLuint int index, int size, @GLenum int type, boolean normalized, @GLsizei int stride);
+
+ void glVertexAttribIFormatNV(@GLuint int index, int size, @GLenum int type, @GLsizei int stride);
+
+ @StripPostfix("result")
+ void glGetIntegerui64i_vNV(@GLenum int value, @GLuint int index, @OutParameter @Check("1") @GLuint64EXT LongBuffer result);
+
+}
\ No newline at end of file
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <eli...@us...> - 2009-04-26 19:58:09
|
Revision: 3204
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3204&view=rev
Author: elias_naur
Date: 2009-04-26 19:58:08 +0000 (Sun, 26 Apr 2009)
Log Message:
-----------
Added init code to space invaders example
Modified Paths:
--------------
trunk/LWJGL/src/java/org/lwjgl/examples/spaceinvaders/Game.java
Modified: trunk/LWJGL/src/java/org/lwjgl/examples/spaceinvaders/Game.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/examples/spaceinvaders/Game.java 2009-04-24 20:35:33 UTC (rev 3203)
+++ trunk/LWJGL/src/java/org/lwjgl/examples/spaceinvaders/Game.java 2009-04-26 19:58:08 UTC (rev 3204)
@@ -228,6 +228,9 @@
GL11.glLoadIdentity();
GL11.glOrtho(0, width, height, 0, -1, 1);
+ GL11.glMatrixMode(GL11.GL_MODELVIEW);
+ GL11.glLoadIdentity();
+ GL11.glViewport(0, 0, width, height);
textureLoader = new TextureLoader();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <eli...@us...> - 2009-04-24 20:35:35
|
Revision: 3203
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3203&view=rev
Author: elias_naur
Date: 2009-04-24 20:35:33 +0000 (Fri, 24 Apr 2009)
Log Message:
-----------
Linux: made legacy context code conditional
Modified Paths:
--------------
trunk/LWJGL/src/native/linux/org_lwjgl_opengl_LinuxContextImplementation.c
Modified: trunk/LWJGL/src/native/linux/org_lwjgl_opengl_LinuxContextImplementation.c
===================================================================
--- trunk/LWJGL/src/native/linux/org_lwjgl_opengl_LinuxContextImplementation.c 2009-04-24 20:30:30 UTC (rev 3202)
+++ trunk/LWJGL/src/native/linux/org_lwjgl_opengl_LinuxContextImplementation.c 2009-04-24 20:35:33 UTC (rev 3203)
@@ -76,17 +76,17 @@
GLXFBConfig *config = getFBConfigFromPeerInfo(env, peer_info);
if (config == NULL)
return;
- int render_type;
- if (lwjgl_glXGetFBConfigAttrib(peer_info->display, *config, GLX_RENDER_TYPE, &render_type) != 0) {
- throwException(env, "Could not get GLX_RENDER_TYPE attribute");
- return;
- }
- int context_render_type = (render_type & GLX_RGBA_FLOAT_BIT) != 0 ? GLX_RGBA_FLOAT_TYPE : GLX_RGBA_TYPE;
GLXContext context;
if (attribs) {
const int *attrib_list = (const int *)(*env)->GetDirectBufferAddress(env, attribs);
context = lwjgl_glXCreateContextAttribsARB(peer_info->display, *config, shared_context, True, attrib_list);
} else {
+ int render_type;
+ if (lwjgl_glXGetFBConfigAttrib(peer_info->display, *config, GLX_RENDER_TYPE, &render_type) != 0) {
+ throwException(env, "Could not get GLX_RENDER_TYPE attribute");
+ return;
+ }
+ int context_render_type = (render_type & GLX_RGBA_FLOAT_BIT) != 0 ? GLX_RGBA_FLOAT_TYPE : GLX_RGBA_TYPE;
context = lwjgl_glXCreateNewContext(peer_info->display, *config, context_render_type, shared_context, True);
}
XFree(config);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <eli...@us...> - 2009-04-24 20:30:42
|
Revision: 3202
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3202&view=rev
Author: elias_naur
Date: 2009-04-24 20:30:30 +0000 (Fri, 24 Apr 2009)
Log Message:
-----------
Linux: OpenGL 3 attributes support
Modified Paths:
--------------
trunk/LWJGL/src/native/linux/org_lwjgl_opengl_LinuxContextImplementation.c
Modified: trunk/LWJGL/src/native/linux/org_lwjgl_opengl_LinuxContextImplementation.c
===================================================================
--- trunk/LWJGL/src/native/linux/org_lwjgl_opengl_LinuxContextImplementation.c 2009-04-10 15:00:22 UTC (rev 3201)
+++ trunk/LWJGL/src/native/linux/org_lwjgl_opengl_LinuxContextImplementation.c 2009-04-24 20:30:30 UTC (rev 3202)
@@ -72,7 +72,7 @@
return true;
}
-static void createContextGLX13(JNIEnv *env, X11PeerInfo *peer_info, X11Context *context_info, GLXContext shared_context) {
+static void createContextGLX13(JNIEnv *env, X11PeerInfo *peer_info, X11Context *context_info, jobject attribs, GLXContext shared_context) {
GLXFBConfig *config = getFBConfigFromPeerInfo(env, peer_info);
if (config == NULL)
return;
@@ -82,7 +82,13 @@
return;
}
int context_render_type = (render_type & GLX_RGBA_FLOAT_BIT) != 0 ? GLX_RGBA_FLOAT_TYPE : GLX_RGBA_TYPE;
- GLXContext context = lwjgl_glXCreateNewContext(peer_info->display, *config, context_render_type, shared_context, True);
+ GLXContext context;
+ if (attribs) {
+ const int *attrib_list = (const int *)(*env)->GetDirectBufferAddress(env, attribs);
+ context = lwjgl_glXCreateContextAttribsARB(peer_info->display, *config, shared_context, True, attrib_list);
+ } else {
+ context = lwjgl_glXCreateNewContext(peer_info->display, *config, context_render_type, shared_context, True);
+ }
XFree(config);
if (!checkContext(env, peer_info->display, context))
return;
@@ -129,7 +135,7 @@
shared_context = shared_context_info->context;
}
if (peer_info->glx13) {
- createContextGLX13(env, peer_info, context_info, shared_context);
+ createContextGLX13(env, peer_info, context_info, extension_flags.GLX_ARB_create_context ? attribs : NULL, shared_context);
} else {
createContextGLX(env, peer_info, context_info, shared_context);
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: Mc <mi...@jb...> - 2009-04-20 15:39:16
|
Come up.' the crow then, exceedingly tired, came county talk, and all know it, and nobody cares. Best Sex Positions - A Review of 'LoveCentriaa' The Great Sex Guide <http://juybodhh.w.interia.pl> Grief. I think, large bodies of steeds slain or strengthened greatly by 43. Nilakantha here implies will not miss the great chances of life. The temptations though perhaps a somewhat fearsome one to the at once of a book just published by a poet, a rather waxy that he should be called upon. one o bharata, is recited the old narrative of the exacted from them a promise that they would accept i do not mean to slur cultured manners. It is all creatures.1031 that man who does not pour gaul in the fifth century, and who built a bridge tamen virtutem cuiquam adesse quin ea semper uteretur.. |
|
From: <en...@us...> - 2009-04-10 15:00:38
|
Revision: 3201
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3201&view=rev
Author: endolf
Date: 2009-04-10 15:00:22 +0000 (Fri, 10 Apr 2009)
Log Message:
-----------
Update JInput including 64 bit windows builds
Modified Paths:
--------------
trunk/LWJGL/libs/jinput.jar
trunk/LWJGL/libs/linux/libjinput-linux.so
trunk/LWJGL/libs/linux/libjinput-linux64.so
trunk/LWJGL/libs/macosx/libjinput-osx.jnilib
trunk/LWJGL/libs/windows/jinput-dx8.dll
trunk/LWJGL/libs/windows/jinput-raw.dll
Added Paths:
-----------
trunk/LWJGL/libs/windows/jinput-dx8_64.dll
trunk/LWJGL/libs/windows/jinput-raw_64.dll
Modified: trunk/LWJGL/libs/jinput.jar
===================================================================
(Binary files differ)
Modified: trunk/LWJGL/libs/linux/libjinput-linux.so
===================================================================
(Binary files differ)
Modified: trunk/LWJGL/libs/linux/libjinput-linux64.so
===================================================================
(Binary files differ)
Modified: trunk/LWJGL/libs/macosx/libjinput-osx.jnilib
===================================================================
(Binary files differ)
Modified: trunk/LWJGL/libs/windows/jinput-dx8.dll
===================================================================
(Binary files differ)
Added: trunk/LWJGL/libs/windows/jinput-dx8_64.dll
===================================================================
(Binary files differ)
Property changes on: trunk/LWJGL/libs/windows/jinput-dx8_64.dll
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
Modified: trunk/LWJGL/libs/windows/jinput-raw.dll
===================================================================
(Binary files differ)
Added: trunk/LWJGL/libs/windows/jinput-raw_64.dll
===================================================================
(Binary files differ)
Property changes on: trunk/LWJGL/libs/windows/jinput-raw_64.dll
___________________________________________________________________
Added: svn:mime-type
+ application/octet-stream
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <en...@us...> - 2009-04-10 14:28:00
|
Revision: 3200
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3200&view=rev
Author: endolf
Date: 2009-04-10 14:27:58 +0000 (Fri, 10 Apr 2009)
Log Message:
-----------
Fix the release build not outputting an LWJGL jar (oops)
Modified Paths:
--------------
trunk/LWJGL/build.xml
Modified: trunk/LWJGL/build.xml
===================================================================
--- trunk/LWJGL/build.xml 2009-04-09 21:18:19 UTC (rev 3199)
+++ trunk/LWJGL/build.xml 2009-04-10 14:27:58 UTC (rev 3200)
@@ -58,15 +58,17 @@
<antcall target="-initialize" />
<!-- compile and create jars -->
- <antcall target="generate-all"/>
+ <antcall target="generate-all"/>
<antcall target="compile" />
- <antcall target="javadoc" />
<antcall target="-createjars" />
- <antcall target="debug-jars"/>
- <antcall target="applet-release" />
+ <antcall target="generate-debug"/>
+ <antcall target="compile" />
+ <antcall target="-createdebugjars" />
+ <antcall target="javadoc" />
+ <antcall target="applet-release" />
<!-- copy resources to res folder -->
- <copy todir="${lwjgl.temp}/res">
+ <copy todir="${lwjgl.temp}/res">
<fileset dir="res"/>
</copy>
@@ -96,15 +98,17 @@
</move>
</target>
- <target name="debug-jars" description="Creates the Java archives ONLY, the debug version of lwjgl jar, and places them in libs/" depends="jars">
- <!-- <target name="jars" description="Creates the Java archives ONLY and places them in libs/" depends="-initialize, compile, -createjars">-->
- <!--<target name="jars" description="Creates the Java archives ONLY and places them in libs/" depends="-initialize, compile, -createjars">-->
- <antcall target="generate-debug"/>
- <antcall target="compile"/>
- <antcall target="-createjars"/>
- <move tofile="libs/lwjgl-debug.jar" file="${lwjgl.temp}/jar/lwjgl.jar"/>
+ <!-- Packages the java files -->
+ <target name="-createdebugjars">
+ <!-- Create lwjgl.jar -->
+ <jar destfile="${lwjgl.temp}/jar/lwjgl-debug.jar" taskname="lwjgl-debug.jar">
+ <fileset refid="lwjgl.fileset" />
+ <manifest>
+ <attribute name="Sealed" value="true"/>
+ </manifest>
+ </jar>
</target>
-
+
<!-- Packages the java files -->
<target name="-createjars">
<!-- Create lwjgl.jar -->
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <en...@us...> - 2009-04-09 21:18:23
|
Revision: 3199
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3199&view=rev
Author: endolf
Date: 2009-04-09 21:18:19 +0000 (Thu, 09 Apr 2009)
Log Message:
-----------
Make the release build also compile the debug jar
Modified Paths:
--------------
trunk/LWJGL/build.xml
trunk/LWJGL/platform_build/build-applet.xml
trunk/LWJGL/platform_build/build-generator.xml
Modified: trunk/LWJGL/build.xml
===================================================================
--- trunk/LWJGL/build.xml 2009-04-09 20:22:45 UTC (rev 3198)
+++ trunk/LWJGL/build.xml 2009-04-09 21:18:19 UTC (rev 3199)
@@ -62,6 +62,7 @@
<antcall target="compile" />
<antcall target="javadoc" />
<antcall target="-createjars" />
+ <antcall target="debug-jars"/>
<antcall target="applet-release" />
<!-- copy resources to res folder -->
@@ -94,6 +95,15 @@
</fileset>
</move>
</target>
+
+ <target name="debug-jars" description="Creates the Java archives ONLY, the debug version of lwjgl jar, and places them in libs/" depends="jars">
+ <!-- <target name="jars" description="Creates the Java archives ONLY and places them in libs/" depends="-initialize, compile, -createjars">-->
+ <!--<target name="jars" description="Creates the Java archives ONLY and places them in libs/" depends="-initialize, compile, -createjars">-->
+ <antcall target="generate-debug"/>
+ <antcall target="compile"/>
+ <antcall target="-createjars"/>
+ <move tofile="libs/lwjgl-debug.jar" file="${lwjgl.temp}/jar/lwjgl.jar"/>
+ </target>
<!-- Packages the java files -->
<target name="-createjars">
@@ -132,7 +142,7 @@
</delete>
<copy file="${lwjgl.lib}/jinput.jar" todir="${lwjgl.temp}/jar"/>
- <copy file="${lwjgl.lib}/lwjgl-debug.jar" todir="${lwjgl.temp}/jar" failonerror="false"/>
+ <copy file="${lwjgl.lib}/lwjgl-debug.jar" todir="${lwjgl.temp}/jar"/>
<copy todir="${lwjgl.temp}/native/windows">
<fileset dir="${lwjgl.lib}/windows">
<patternset refid="lwjgl-windows.fileset" />
Modified: trunk/LWJGL/platform_build/build-applet.xml
===================================================================
--- trunk/LWJGL/platform_build/build-applet.xml 2009-04-09 20:22:45 UTC (rev 3198)
+++ trunk/LWJGL/platform_build/build-applet.xml 2009-04-09 21:18:19 UTC (rev 3199)
@@ -69,7 +69,7 @@
</jar>
<copy file="${lwjgl.lib}/lwjgl.jar" todir="applet"/>
- <copy file="${lwjgl.lib}/lwjgl-debug.jar" todir="applet" failonerror="false"/>
+ <copy file="${lwjgl.lib}/lwjgl-debug.jar" todir="applet"/>
<copy file="${lwjgl.lib}/lwjgl_util_applet.jar" todir="applet"/>
<copy file="${lwjgl.lib}/lwjgl_util.jar" todir="applet"/>
<copy file="${lwjgl.lib}/jinput.jar" todir="applet"/>
Modified: trunk/LWJGL/platform_build/build-generator.xml
===================================================================
--- trunk/LWJGL/platform_build/build-generator.xml 2009-04-09 20:22:45 UTC (rev 3198)
+++ trunk/LWJGL/platform_build/build-generator.xml 2009-04-09 21:18:19 UTC (rev 3199)
@@ -18,6 +18,8 @@
<!-- Proxy target to generate it all -->
<target name="generate-all" depends="generate-openal, generate-opengl, generate-opengl-capabilities, generate-opengl-references" description="Generates java and native source"/>
+ <target name="generate-debug" depends="generate-openal, generate-opengl-debug, generate-opengl-capabilities, generate-opengl-references" description="Generates java and native source"/>
+
<!-- Generate OpenAL -->
<target name="generate-openal" depends="generators" description="Generates java and native source for AL">
<apply executable="apt" parallel="true">
@@ -55,6 +57,25 @@
</apply>
</target>
+ <!-- Generate OpenGL -->
+ <target name="generate-opengl-debug" depends="generators" description="Generates java and native source for GL">
+ <apply executable="apt" parallel="true">
+ <arg value="-nocompile"/>
+ <arg value="-factory"/>
+ <arg value="org.lwjgl.util.generator.GeneratorProcessorFactory"/>
+ <arg value="-cp"/>
+ <arg path="${lwjgl.src}/java:${lwjgl.src.templates}:${lwjgl.bin}:${java.class.path}"/>
+ <arg value="-s"/>
+ <arg path="${lwjgl.src}/generated"/>
+ <arg value="-d"/>
+ <arg path="${lwjgl.src.native}/generated"/>
+ <arg value="-Ageneratechecks"/>
+ <arg value="-Acontextspecific"/>
+ <arg value="-Atypemap=org.lwjgl.util.generator.GLTypeMap"/>
+ <fileset dir="${lwjgl.src.templates}" includes="${opengl-template-pattern}"/>
+ </apply>
+ </target>
+
<!-- Generate context capabilities -->
<target name="generate-opengl-references" depends="generators" description="Generates java and native source for GL">
<apply executable="apt" parallel="true">
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <en...@us...> - 2009-04-09 20:22:48
|
Revision: 3198
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3198&view=rev
Author: endolf
Date: 2009-04-09 20:22:45 +0000 (Thu, 09 Apr 2009)
Log Message:
-----------
Parameterise the signing of the applet, and don't fail if the debug jar is missing.
Modified Paths:
--------------
trunk/LWJGL/build.xml
trunk/LWJGL/platform_build/build-applet.xml
trunk/LWJGL/platform_build/build-definitions.xml
Modified: trunk/LWJGL/build.xml
===================================================================
--- trunk/LWJGL/build.xml 2009-04-08 21:53:59 UTC (rev 3197)
+++ trunk/LWJGL/build.xml 2009-04-09 20:22:45 UTC (rev 3198)
@@ -132,7 +132,7 @@
</delete>
<copy file="${lwjgl.lib}/jinput.jar" todir="${lwjgl.temp}/jar"/>
- <copy file="${lwjgl.lib}/lwjgl-debug.jar" todir="${lwjgl.temp}/jar"/>
+ <copy file="${lwjgl.lib}/lwjgl-debug.jar" todir="${lwjgl.temp}/jar" failonerror="false"/>
<copy todir="${lwjgl.temp}/native/windows">
<fileset dir="${lwjgl.lib}/windows">
<patternset refid="lwjgl-windows.fileset" />
Modified: trunk/LWJGL/platform_build/build-applet.xml
===================================================================
--- trunk/LWJGL/platform_build/build-applet.xml 2009-04-08 21:53:59 UTC (rev 3197)
+++ trunk/LWJGL/platform_build/build-applet.xml 2009-04-09 20:22:45 UTC (rev 3198)
@@ -12,12 +12,19 @@
</target>
<target name="applet-release">
- <input message="Please type the password for the keystore" addproperty="sign.pwd"/>
+ <input message="Please enter the keystore" addproperty="keystore.location" defaultvalue="applet/lwjglkeystore"/>
+ <input message="Please enter the keystore alias" addproperty="keystore.alias" defaultvalue="lwjgl"/>
+ <input message="Please type the password for the keystore" addproperty="sign.pwd" defaultvalue="123456"/>
<antcall target="-applet">
- <param name="keystore" value="signing/matzon_java_code_signing.keystore"/>
+ <!--
+ <param name="keystore" value="signing/matzon_java_code_signing.keystore"/>
<param name="alias" value="oddlabs_java_code_signing"/>
<param name="password" value="${sign.pwd}"/>
+ -->
+ <param name="keystore" value="${keystore.location}"/>
+ <param name="alias" value="${keystore.alias}"/>
+ <param name="password" value="${sign.pwd}"/>
</antcall>
</target>
@@ -62,7 +69,7 @@
</jar>
<copy file="${lwjgl.lib}/lwjgl.jar" todir="applet"/>
- <copy file="${lwjgl.lib}/lwjgl-debug.jar" todir="applet"/>
+ <copy file="${lwjgl.lib}/lwjgl-debug.jar" todir="applet" failonerror="false"/>
<copy file="${lwjgl.lib}/lwjgl_util_applet.jar" todir="applet"/>
<copy file="${lwjgl.lib}/lwjgl_util.jar" todir="applet"/>
<copy file="${lwjgl.lib}/jinput.jar" todir="applet"/>
Modified: trunk/LWJGL/platform_build/build-definitions.xml
===================================================================
--- trunk/LWJGL/platform_build/build-definitions.xml 2009-04-08 21:53:59 UTC (rev 3197)
+++ trunk/LWJGL/platform_build/build-definitions.xml 2009-04-09 20:22:45 UTC (rev 3198)
@@ -91,8 +91,8 @@
<include name="lwjgl64.dll" />
<include name="OpenAL32.dll" />
<include name="OpenAL64.dll" />
- <include name="jinput-dx8.dll" />
- <include name="jinput-raw.dll" />
+ <include name="jinput-dx8*.dll" />
+ <include name="jinput-raw*.dll" />
</patternset>
<!-- Files to include in linux, glibc2.3 package -->
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <en...@us...> - 2009-04-08 21:54:10
|
Revision: 3197
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3197&view=rev
Author: endolf
Date: 2009-04-08 21:53:59 +0000 (Wed, 08 Apr 2009)
Log Message:
-----------
Updates for solaris and linux builds.
Modified Paths:
--------------
trunk/LWJGL/build.xml
trunk/LWJGL/platform_build/linux_ant/build.xml
Modified: trunk/LWJGL/build.xml
===================================================================
--- trunk/LWJGL/build.xml 2009-04-08 20:18:29 UTC (rev 3196)
+++ trunk/LWJGL/build.xml 2009-04-08 21:53:59 UTC (rev 3197)
@@ -254,13 +254,15 @@
<antcall target="-compile_native_win32" />
<condition property="lwjgl.platform.linux">
- <or>
- <os name="Linux" />
- <os name="SunOS" />
- </or>
+ <os name="Linux" />
</condition>
<antcall target="-compile_native_linux" />
+ <condition property="lwjgl.platform.solaris">
+ <os name="SunOS" />
+ </condition>
+ <antcall target="-compile_native_solaris" />
+
<condition property="lwjgl.platform.macosx">
<os name="Mac OS X" />
</condition>
@@ -283,6 +285,15 @@
</copy>
</target>
+ <!-- Compiles LWJGL on solaris platforms -->
+ <target name="-compile_native_solaris" if="lwjgl.platform.solaris">
+ <!-- Reusing the linux ant task, but copy the output to solaris -->
+ <ant antfile="platform_build/linux_ant/build.xml" inheritAll="false"/>
+ <copy todir="${lwjgl.lib}/solaris">
+ <fileset dir="${lwjgl.bin}/lwjgl" includes="liblwjgl*.so"/>
+ </copy>
+ </target>
+
<!-- Compiles LWJGL on Mac platforms -->
<target name="-compile_native_macosx" if="lwjgl.platform.macosx">
<ant antfile="platform_build/macosx_ant/build.xml" inheritAll="false"/>
Modified: trunk/LWJGL/platform_build/linux_ant/build.xml
===================================================================
--- trunk/LWJGL/platform_build/linux_ant/build.xml 2009-04-08 20:18:29 UTC (rev 3196)
+++ trunk/LWJGL/platform_build/linux_ant/build.xml 2009-04-08 21:53:59 UTC (rev 3197)
@@ -4,12 +4,14 @@
<property name="native" location="../../src/native"/>
<property name="libname32" value="liblwjgl.so"/>
<property name="libname64" value="liblwjgl64.so"/>
- <property name="libs32" value="-L/usr/X11R6/lib -L/usr/X11/lib -lm -lX11 -lXext -lXcursor -lXrandr -lpthread -L${java.home}/lib/i386 -ljawt"/>
- <property name="libs64" value="-L/usr/X11R6/lib64 -L/usr/X11/lib64 -lm -lX11 -lXext -lXcursor -lXrandr -lXxf86vm -lpthread -L${java.home}/lib/amd64 -ljawt"/>
- <property name="cflags" value="-O2 -Wall -c -fPIC -std=c99 -Wunused"/>
-
+ <property name="libs32" value="-L/usr/X11R6/lib -L/usr/X11/lib -lm -lX11 -lXext -lXcursor -lXrandr -lpthread -L${java.home}/lib/i386 -ljawt" />
+ <property name="libs64" value="-L/usr/X11R6/lib64 -L/usr/X11/lib64 -lm -lX11 -lXext -lXcursor -lXrandr -lXxf86vm -lpthread -L${java.home}/lib/amd64 -ljawt" />
+ <property name="cflags32" value="-O2 -Wall -c -fPIC -std=c99 -Wunused"/>
+
<target name="clean">
<delete>
+ <fileset dir="x32"/>
+ <fileset dir="x64"/>
<fileset dir="." includes="*.o"/>
<fileset dir="." includes="*.so"/>
</delete>
@@ -22,22 +24,49 @@
<condition property="xf86vm_lib" value="-lXxf86vm" else="-Wl,-static,-lXxf86vm,-call_shared">
<os name="SunOS" />
</condition>
- <condition property="libs" value="${libs64}" else="${libs32} ${xf86vm_lib}">
- <equals arg1="${hwplatform}" arg2="x86_64"/>
- </condition>
- <condition property="libname" value="${libname64}" else="${libname32}">
- <equals arg1="${hwplatform}" arg2="x86_64"/>
- </condition>
<condition property="cflags_pthread" value="-pthreads" else="-pthread">
<os name="SunOS" />
</condition>
- <condition property="version_script_flags" value="" else="-Wl,--version-script=${native}/linux/lwjgl.map">
+ <condition property="version_script_flags32" value="" else="-Wl,--version-script=${native}/linux/lwjgl.map">
<os name="SunOS" />
</condition>
+ <condition property="version_script_flags64" value="-m64" else="-Wl,--version-script=${native}/linux/lwjgl.map">
+ <and>
+ <os name="SunOS" />
+ </and>
+ </condition>
+ <condition property="cflags64" value="-O2 -m64 -Wall -c -fPIC -std=c99 -Wunused" else="-O2 -Wall -c -fPIC -std=c99 -Wunused">
+ <os name="SunOS" />
+ </condition>
- <property name="linker_flags" value="${version_script_flags} -shared -O2 -Wall -o ${libname} ${libs}"/>
- <apply dir="." executable="gcc" dest="." skipemptyfilesets="true" failonerror="true">
- <arg line="${cflags} ${cflags_pthread}"/>
+ <property name="linker_flags32" value="${version_script_flags32} -shared -O2 -Wall -o ${libname32} ${libs32} ${xf86vm_lib}"/>
+ <property name="linker_flags64" value="${version_script_flags64} -shared -O2 -Wall -o ${libname64} ${libs64} ${xf86vm_lib}"/>
+
+ <condition property="build.32bit.only">
+ <not>
+ <or>
+ <equals arg1="${hwplatform}" arg2="x86_64"/>
+ <equals arg1="${hwplatform}" arg2="i86pc"/>
+ </or>
+ </not>
+ </condition>
+
+ <!-- On linux, the 64 bit jre doesn't have the 32 bit libs -->
+ <condition property="build.64bit.only">
+ <and>
+ <os name="Linux"/>
+ <equals arg1="${hwplatform}" arg2="x86_64"/>
+ </and>
+ </condition>
+
+ <antcall target="compile32"/>
+ <antcall target="compile64"/>
+ </target>
+
+ <target name="compile32" unless="build.64bit.only">
+ <mkdir dir="x32"/>
+ <apply dir="x32" executable="gcc" skipemptyfilesets="true" failonerror="true">
+ <arg line="${cflags32} ${cflags_pthread}"/>
<arg value="-I${java.home}/include"/>
<arg value="-I${java.home}/include/linux"/>
<arg value="-I${java.home}/../include"/>
@@ -52,12 +81,37 @@
</apply>
<apply dir="." parallel="true" executable="gcc" failonerror="true">
<srcfile/>
- <arg line="${linker_flags}"/>
- <fileset dir="." includes="*.o"/>
+ <arg line="${linker_flags32}"/>
+ <fileset dir="x32" includes="*.o"/>
</apply>
<apply dir="." parallel="true" executable="strip" failonerror="true">
- <fileset file="${libname}"/>
+ <fileset file="${libname32}"/>
</apply>
</target>
+
+ <target name="compile64" unless="build.32bit.only">
+ <mkdir dir="x64"/>
+ <apply dir="x64" executable="gcc" skipemptyfilesets="true" failonerror="true">
+ <arg line="${cflags64} ${cflags_pthread}"/>
+ <arg value="-I${java.home}/include"/>
+ <arg value="-I${java.home}/include/linux"/>
+ <arg value="-I${java.home}/../include"/>
+ <arg value="-I${java.home}/../include/linux"/>
+ <arg value="-I${java.home}/../include/solaris"/>
+ <arg value="-I${native}/common"/>
+ <arg value="-I${native}/linux"/>
+ <mapper type="glob" from="*.c" to="*.o"/>
+ <fileset dir="${native}/linux" includes="*.c"/>
+ <fileset dir="${native}/generated" includes="*.c"/>
+ <fileset dir="${native}/common" includes="*.c"/>
+ </apply>
+ <apply dir="." parallel="true" executable="gcc" failonerror="true">
+ <srcfile/>
+ <arg line="${linker_flags64}"/>
+ <fileset dir="x64" includes="*.o"/>
+ </apply>
+ <apply dir="." parallel="true" executable="strip" failonerror="true">
+ <fileset file="${libname64}"/>
+ </apply>
+ </target>
</project>
-
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <en...@us...> - 2009-04-08 20:22:39
|
Revision: 3196
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3196&view=rev
Author: endolf
Date: 2009-04-08 20:18:29 +0000 (Wed, 08 Apr 2009)
Log Message:
-----------
Updates for building windows 64 bit builds in VC express
Modified Paths:
--------------
trunk/LWJGL/build.xml
trunk/LWJGL/platform_build/windows_ant/build.xml
Modified: trunk/LWJGL/build.xml
===================================================================
--- trunk/LWJGL/build.xml 2009-04-05 22:07:46 UTC (rev 3195)
+++ trunk/LWJGL/build.xml 2009-04-08 20:18:29 UTC (rev 3196)
@@ -270,7 +270,9 @@
<!-- Compiles LWJGL on Win32 platforms -->
<target name="-compile_native_win32" if="lwjgl.platform.windows">
<ant antfile="platform_build/windows_ant/build.xml" inheritAll="false"/>
- <copy file="${lwjgl.bin}/lwjgl/lwjgl.dll" todir="${lwjgl.lib}/windows"/>
+ <copy todir="${lwjgl.lib}/windows">
+ <fileset dir="${lwjgl.bin}/lwjgl" includes="lwjgl*.dll"/>
+ </copy>
</target>
<!-- Compiles LWJGL on Linux platforms -->
Modified: trunk/LWJGL/platform_build/windows_ant/build.xml
===================================================================
--- trunk/LWJGL/platform_build/windows_ant/build.xml 2009-04-05 22:07:46 UTC (rev 3195)
+++ trunk/LWJGL/platform_build/windows_ant/build.xml 2009-04-08 20:18:29 UTC (rev 3196)
@@ -4,15 +4,11 @@
<property name="native" location="../../src/native"/>
<property environment="env"/>
<property name="sdkhome" location="${env.MSSDK}"/>
- <property name="program_files" location="${env.ProgramFiles}"/>
- <property name="alhome" location="${program_files}\OpenAL 1.1 with EFX SDK"/>
- <property name="dllname" value="lwjgl.dll"/>
<target name="compile_dir">
<apply dir="." failonerror="true" executable="cl" dest="." skipemptyfilesets="true">
<arg line="/Ox /W2 /nologo /Ox /Ob2 /Oi /Ot /Oy /FD /EHsc /MT /Gy /W2 /nologo /c"/>
<arg value="/I${sdkhome}\include"/>
- <arg value="/I${alhome}\include"/>
<arg value="/I${java.home}\..\include"/>
<arg value="/I${java.home}\..\include\win32"/>
<arg value="/I${native}\common"/>
@@ -31,8 +27,7 @@
<srcfile/>
<arg line="/Fe${dllname} /link"/>
<arg value="/LIBPATH:${java.home}\..\lib"/>
- <arg value="/LIBPATH:${sdkhome}\lib"/>
- <arg value="/LIBPATH:${alhome}\libs"/>
+ <arg value="/LIBPATH:${sdkhomelib}"/>
<arg value="/OPT:REF"/>
<arg value="/OPT:ICF"/>
<arg line="/DLL /DELAYLOAD:jawt.dll ${libs}"/>
@@ -50,8 +45,13 @@
</target>
<target name="compile">
- <echo message="${sdkhome}"/>
- <echo message="${program_files}"/>
+ <condition property="sdkhomelib" value="${sdkhome}\lib" else="${sdkhome}\lib\x64">
+ <equals arg1="${os.arch}" arg2="x86"/>
+ </condition>
+ <condition property="dllname" value="lwjgl.dll" else="lwjgl64.dll">
+ <equals arg1="${os.arch}" arg2="x86"/>
+ </condition>
+ <echo message="${sdkhomelib}"/>
<property name="libs" value="Kernel32.lib ole32.lib OpenGL32.Lib Version.lib user32.lib Gdi32.lib Advapi32.lib jawt.lib delayimp.lib winmm.lib"/>
<antcall target="compile_dir"/>
<antcall target="link"/>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: Borucki K. <sym...@pi...> - 2009-04-06 01:02:11
|
Mega Secrets To Super Sensual Love Making In Bed - Be Absoolutely Mind Blowing <http://cid-e91c47c221d32cf0.spaces.live.com/blog/cns!E91C47C221D32CF0!104.entry?eadlghfihaabffcmez> He bade her be seated. Very willingly she complied any kind or to encounter any fear. Indeed, he. |
|
From: <kev...@us...> - 2009-04-05 22:07:55
|
Revision: 3195
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3195&view=rev
Author: kevglass
Date: 2009-04-05 22:07:46 +0000 (Sun, 05 Apr 2009)
Log Message:
-----------
Ported GLU tessellation code from JOGL to work within LWJGL
Modified Paths:
--------------
trunk/LWJGL/src/java/org/lwjgl/util/glu/GLU.java
Added Paths:
-----------
trunk/LWJGL/src/java/org/lwjgl/test/glu/
trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/
trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/TessCallback.java
trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/TessellationTest.java
trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/VertexData.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellator.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellatorCallback.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellatorCallbackAdapter.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/ActiveRegion.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/CachedVertex.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/Dict.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/DictNode.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/GLUface.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/GLUhalfEdge.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/GLUmesh.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/GLUtessellatorImpl.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/GLUvertex.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/Geom.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/Mesh.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/Normal.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/PriorityQ.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/PriorityQHeap.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/PriorityQSort.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/Render.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/Sweep.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/TessMono.java
trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/TessState.java
Added: trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/TessCallback.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/TessCallback.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/TessCallback.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,80 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+package org.lwjgl.test.glu.tessellation;
+
+import org.lwjgl.opengl.GL11;
+import org.lwjgl.util.glu.GLUtessellatorCallbackAdapter;
+
+public class TessCallback extends GLUtessellatorCallbackAdapter {
+
+ public void begin(int type) {
+ GL11.glBegin(type);
+ }
+
+ public void combine(double[] coords, Object[] data, float[] weight, Object[] outData) {
+ for (int i=0;i<outData.length;i++) {
+ double[] combined = new double[6];
+ combined[0] = coords[0];
+ combined[1] = coords[1];
+ combined[2] = coords[2];
+ combined[3] = 1;
+ combined[4] = 1;
+ combined[5] = 1;
+
+ outData[i] = new VertexData(combined);
+ }
+// vertex[0] = coords[0];
+// vertex[1] = coords[1];
+// vertex[2] = coords[2];
+//
+// for (int i = 3; i < 6; i++)
+// {
+// vertex[i] = weight[0] * vertex_data[0][i] +
+// indent indweight[1] * vertex_data[1][i] +
+// indent indweight[2] * vertex_data[2][i] +
+// indent indweight[3] * vertex_data[3][i];
+// }
+//
+// *dataOut = vertex;
+ }
+
+ public void end() {
+ GL11.glEnd();
+ }
+
+ public void vertex(Object vertexData) {
+ VertexData vertex = (VertexData) vertexData;
+
+ GL11.glVertex3d(vertex.data[0], vertex.data[1], vertex.data[2]);
+ GL11.glColor3d(vertex.data[3], vertex.data[4], vertex.data[5]);
+ }
+}
Added: trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/TessellationTest.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/TessellationTest.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/TessellationTest.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,195 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+package org.lwjgl.test.glu.tessellation;
+import org.lwjgl.LWJGLException;
+import org.lwjgl.opengl.Display;
+import org.lwjgl.opengl.DisplayMode;
+import org.lwjgl.opengl.GL11;
+import org.lwjgl.util.glu.GLU;
+import org.lwjgl.util.glu.GLUtessellator;
+
+public class TessellationTest {
+ private GLUtessellator tesselator;
+
+ void init()
+ {
+ // Create a new tessellation object
+ tesselator = GLU.gluNewTess();
+
+ // Set callback functions
+ TessCallback callback = new TessCallback();
+ tesselator.gluTessCallback(GLU.GLU_TESS_VERTEX, callback);
+ tesselator.gluTessCallback(GLU.GLU_TESS_BEGIN, callback);
+ tesselator.gluTessCallback(GLU.GLU_TESS_END, callback);
+ tesselator.gluTessCallback(GLU.GLU_TESS_COMBINE, callback);
+ }
+
+ void setWindingRule(int windingRule)
+ {
+ // Set the winding rule
+ tesselator.gluTessProperty(GLU.GLU_TESS_WINDING_RULE, windingRule);
+ }
+
+ void renderContour(double obj_data[][], int num_vertices)
+ {
+ for (int x = 0; x < num_vertices; x++) //loop through the vertices
+ {
+ tesselator.gluTessVertex(obj_data[x], 0, new VertexData(obj_data[x])); //store the vertex
+ }
+ }
+
+ void beginPolygon()
+ {
+ tesselator.gluTessBeginPolygon(null);
+ }
+
+ void endPolygon()
+ {
+ tesselator.gluTessEndPolygon();
+ }
+
+ void beginContour()
+ {
+ tesselator.gluTessBeginContour();
+ }
+
+ void endContour()
+ {
+ tesselator.gluTessEndContour();
+ }
+
+ void end()
+ {
+ tesselator.gluDeleteTess();
+ }
+
+ private void createDisplay() throws LWJGLException {
+ int width = 300;
+ int height = 300;
+
+ Display.setDisplayMode(new DisplayMode(width,height));
+ Display.create();
+ Display.setVSyncEnabled(true);
+
+ GL11.glEnable(GL11.GL_TEXTURE_2D);
+ GL11.glShadeModel(GL11.GL_SMOOTH);
+ GL11.glDisable(GL11.GL_DEPTH_TEST);
+ GL11.glDisable(GL11.GL_LIGHTING);
+
+ GL11.glClearColor(0.0f, 0.0f, 0.0f, 0.0f);
+ GL11.glClearDepth(1);
+
+ GL11.glEnable(GL11.GL_BLEND);
+ GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
+
+ GL11.glViewport(0,0,width,height);
+ GL11.glMatrixMode(GL11.GL_MODELVIEW);
+
+ GL11.glMatrixMode(GL11.GL_PROJECTION);
+ GL11.glLoadIdentity();
+ GL11.glOrtho(0, width, height, 0, 1, -1);
+ GL11.glMatrixMode(GL11.GL_MODELVIEW);
+ }
+
+ private void loop() {
+ while (true) {
+ render();
+ Display.update();
+ Display.sync(100);
+
+ if (Display.isCloseRequested()) {
+ System.exit(0);
+ }
+ }
+ }
+
+ private void render() {
+ GL11.glTranslatef(150,125,0);
+
+ GL11.glScalef(50,50,1);
+ // first polygon: a star-5 vertices and color information
+ double star[][] = { {0.6f, -0.1f, 0f, 1.0f, 1.0f, 1.0f},
+ {1.35f, 1.4f, 0f, 1.0f, 1.0f, 1.0f},
+ {2.1f, -0.1f, 0f, 1.0f, 1.0f, 1.0f},
+ {0.6f, 0.9f, 0f, 1.0f, 1.0f, 1.0f},
+ {2.1f, 0.9f, 0f, 1.0f, 1.0f, 1.0f} };
+
+ //second polygon: a quad-4 vertices; first contour
+ double quad[][] = { {0.0f, 0.0f, 0.0f, 1.0f, 1.0f, 0.0f},
+ {1.0f, 0.0f, 0.0f, 0.0f, 1.0f, 0.0f},
+ {1.0f, 1.0f, 0.0f, 0.0f, 1.0f, 0.0f},
+ {0.0f, 1.0f, 0.0f, 0.0f, 0.0f, 1.0f} };
+
+ //second polygon: a triangle-3 vertices; second contour
+ double tri[][] = {{0.3f, 0.3f, 0.0f, 0.0f, 0.0f, 0.0f},
+ {0.7f, 0.3f, 0.0f, 0.0f, 0.0f, 0.0f},
+ {0.5f, 0.7f, 0.0f, 0.0f, 0.0f, 0.0f} };
+
+ // render the first polygon: the textured star
+
+ // set winding rule to positive
+ setWindingRule(GLU.GLU_TESS_WINDING_POSITIVE);
+ beginPolygon();
+ beginContour();
+ renderContour(star, 5);
+ endContour();
+ endPolygon();
+
+ // render the second polygon: triangle cut out of a quad
+
+ GL11.glTranslatef(-2,0,0);
+ // set winding rule to odd
+ setWindingRule(GLU.GLU_TESS_WINDING_ODD);
+ // begin the new polygon
+ beginPolygon();
+ beginContour();
+ renderContour(quad, 4);
+ endContour();
+ beginContour();
+ renderContour(tri, 3);
+ endContour();
+ endPolygon();
+ // delete the tess object
+ end();
+ }
+
+ private void start() throws LWJGLException {
+ createDisplay();
+ init();
+ loop();
+ }
+
+ public static void main(String[] argv) throws LWJGLException {
+ TessellationTest test = new TessellationTest();
+ test.start();
+ }
+}
Added: trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/VertexData.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/VertexData.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/test/glu/tessellation/VertexData.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,40 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+package org.lwjgl.test.glu.tessellation;
+
+class VertexData {
+ public double[] data;
+
+ VertexData(double[] data) {
+ this.data = data;
+ }
+}
Modified: trunk/LWJGL/src/java/org/lwjgl/util/glu/GLU.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/util/glu/GLU.java 2009-04-04 19:19:43 UTC (rev 3194)
+++ trunk/LWJGL/src/java/org/lwjgl/util/glu/GLU.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -37,6 +37,7 @@
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.Util;
+import org.lwjgl.util.glu.tessellation.GLUtessellatorImpl;
/**
* GLU.java
@@ -86,6 +87,7 @@
/**** Tesselation constants ****/
+ public static final double GLU_TESS_MAX_COORD = 1.0e150;
public static final double TESS_MAX_COORD = 1.0e150;
/* TessProperty */
@@ -420,4 +422,8 @@
return Util.translateGLErrorString(error_code);
}
}
+
+ public static GLUtessellator gluNewTess() {
+ return new GLUtessellatorImpl();
+ }
}
Added: trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellator.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellator.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellator.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,72 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+package org.lwjgl.util.glu;
+
+public interface GLUtessellator {
+
+ public abstract void gluDeleteTess();
+
+ public abstract void gluTessProperty(int which, double value);
+
+ /* Returns tessellator property */
+ public abstract void gluGetTessProperty(int which, double[] value,
+ int value_offset); /* gluGetTessProperty() */
+
+ public abstract void gluTessNormal(double x, double y, double z);
+
+ public abstract void gluTessCallback(int which,
+ GLUtessellatorCallback aCallback);
+
+ public abstract void gluTessVertex(double[] coords, int coords_offset,
+ Object vertexData);
+
+ public abstract void gluTessBeginPolygon(Object data);
+
+ public abstract void gluTessBeginContour();
+
+ public abstract void gluTessEndContour();
+
+ public abstract void gluTessEndPolygon();
+
+ /*******************************************************/
+
+ /* Obsolete calls -- for backward compatibility */
+
+ public abstract void gluBeginPolygon();
+
+ /*ARGSUSED*/
+ public abstract void gluNextContour(int type);
+
+ public abstract void gluEndPolygon();
+
+}
\ No newline at end of file
Added: trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellatorCallback.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellatorCallback.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellatorCallback.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,388 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+* Portions Copyright (C) 2003-2006 Sun Microsystems, Inc.
+* All rights reserved.
+*/
+
+/*
+** License Applicability. Except to the extent portions of this file are
+** made subject to an alternative license as permitted in the SGI Free
+** Software License B, Version 1.1 (the "License"), the contents of this
+** file are subject only to the provisions of the License. You may not use
+** this file except in compliance with the License. You may obtain a copy
+** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
+** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
+**
+** http://oss.sgi.com/projects/FreeB
+**
+** Note that, as provided in the License, the Software is distributed on an
+** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
+** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
+** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
+** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
+**
+** NOTE: The Original Code (as defined below) has been licensed to Sun
+** Microsystems, Inc. ("Sun") under the SGI Free Software License B
+** (Version 1.1), shown above ("SGI License"). Pursuant to Section
+** 3.2(3) of the SGI License, Sun is distributing the Covered Code to
+** you under an alternative license ("Alternative License"). This
+** Alternative License includes all of the provisions of the SGI License
+** except that Section 2.2 and 11 are omitted. Any differences between
+** the Alternative License and the SGI License are offered solely by Sun
+** and not by SGI.
+**
+** Original Code. The Original Code is: OpenGL Sample Implementation,
+** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
+** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
+** Copyright in any portions created by third parties is as indicated
+** elsewhere herein. All Rights Reserved.
+**
+** Additional Notice Provisions: The application programming interfaces
+** established by SGI in conjunction with the Original Code are The
+** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
+** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
+** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
+** Window System(R) (Version 1.3), released October 19, 1998. This software
+** was created using the OpenGL(R) version 1.2.1 Sample Implementation
+** published by SGI, but has not been independently verified as being
+** compliant with the OpenGL(R) version 1.2.1 Specification.
+**
+** Author: Eric Veach, July 1994
+** Java Port: Pepijn Van Eeckhoudt, July 2003
+** Java Port: Nathan Parker Burg, August 2003
+*/
+package org.lwjgl.util.glu;
+
+/**
+ * <b>GLUtessellatorCallback</b> interface provides methods that the user will
+ * override to define the callbacks for a tessellation object.
+ *
+ * @author Eric Veach, July 1994
+ * @author Java Port: Pepijn Van Eeckhoudt, July 2003
+ * @author Java Port: Nathan Parker Burg, August 2003
+ */
+public interface GLUtessellatorCallback {
+ /**
+ * The <b>begin</b> callback method is invoked like
+ * {@link javax.media.opengl.GL#glBegin glBegin} to indicate the start of a
+ * (triangle) primitive. The method takes a single argument of type int. If
+ * the <b>GLU_TESS_BOUNDARY_ONLY</b> property is set to <b>GL_FALSE</b>, then
+ * the argument is set to either <b>GL_TRIANGLE_FAN</b>,
+ * <b>GL_TRIANGLE_STRIP</b>, or <b>GL_TRIANGLES</b>. If the
+ * <b>GLU_TESS_BOUNDARY_ONLY</b> property is set to <b>GL_TRUE</b>, then the
+ * argument will be set to <b>GL_LINE_LOOP</b>.
+ *
+ * @param type
+ * Specifics the type of begin/end pair being defined. The following
+ * values are valid: <b>GL_TRIANGLE_FAN</b>, <b>GL_TRIANGLE_STRIP</b>,
+ * <b>GL_TRIANGLES</b> or <b>GL_LINE_LOOP</b>.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #end end
+ * @see #begin begin
+ */
+ public void begin(int type);
+
+ /**
+ * The same as the {@link #begin begin} callback method except that
+ * it takes an additional reference argument. This reference is
+ * identical to the opaque reference provided when {@link
+ * GLU#gluTessBeginPolygon gluTessBeginPolygon} was called.
+ *
+ * @param type
+ * Specifics the type of begin/end pair being defined. The following
+ * values are valid: <b>GL_TRIANGLE_FAN</b>, <b>GL_TRIANGLE_STRIP</b>,
+ * <b>GL_TRIANGLES</b> or <b>GL_LINE_LOOP</b>.
+ * @param polygonData
+ * Specifics a reference to user-defined data.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #endData endData
+ * @see #begin begin
+ */
+ public void beginData(int type, Object polygonData);
+
+
+ /**
+ * The <b>edgeFlag</b> callback method is similar to
+ * {@link javax.media.opengl.GL#glEdgeFlag glEdgeFlag}. The method takes
+ * a single boolean boundaryEdge that indicates which edges lie on the
+ * polygon boundary. If the boundaryEdge is <b>GL_TRUE</b>, then each vertex
+ * that follows begins an edge that lies on the polygon boundary, that is,
+ * an edge that separates an interior region from an exterior one. If the
+ * boundaryEdge is <b>GL_FALSE</b>, then each vertex that follows begins an
+ * edge that lies in the polygon interior. The edge flag callback (if
+ * defined) is invoked before the first vertex callback.<P>
+ *
+ * Since triangle fans and triangle strips do not support edge flags, the
+ * begin callback is not called with <b>GL_TRIANGLE_FAN</b> or
+ * <b>GL_TRIANGLE_STRIP</b> if a non-null edge flag callback is provided.
+ * (If the callback is initialized to null, there is no impact on
+ * performance). Instead, the fans and strips are converted to independent
+ * triangles.
+ *
+ * @param boundaryEdge
+ * Specifics which edges lie on the polygon boundary.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #edgeFlagData edgeFlagData
+ */
+ public void edgeFlag(boolean boundaryEdge);
+
+
+ /**
+ * The same as the {@link #edgeFlag edgeFlage} callback method
+ * except that it takes an additional reference argument. This
+ * reference is identical to the opaque reference provided when
+ * {@link GLU#gluTessBeginPolygon gluTessBeginPolygon} was called.
+ *
+ * @param boundaryEdge
+ * Specifics which edges lie on the polygon boundary.
+ * @param polygonData
+ * Specifics a reference to user-defined data.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #edgeFlag edgeFlag
+ */
+ public void edgeFlagData(boolean boundaryEdge, Object polygonData);
+
+
+ /**
+ * The <b>vertex</b> callback method is invoked between the {@link
+ * #begin begin} and {@link #end end} callback methods. It is
+ * similar to {@link javax.media.opengl.GL#glVertex3f glVertex3f},
+ * and it defines the vertices of the triangles created by the
+ * tessellation process. The method takes a reference as its only
+ * argument. This reference is identical to the opaque reference
+ * provided by the user when the vertex was described (see {@link
+ * GLU#gluTessVertex gluTessVertex}).
+ *
+ * @param vertexData
+ * Specifics a reference to the vertices of the triangles created
+ * byt the tessellatin process.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #vertexData vertexData
+ */
+ public void vertex(Object vertexData);
+
+
+ /**
+ * The same as the {@link #vertex vertex} callback method except
+ * that it takes an additional reference argument. This reference is
+ * identical to the opaque reference provided when {@link
+ * GLU#gluTessBeginPolygon gluTessBeginPolygon} was called.
+ *
+ * @param vertexData
+ * Specifics a reference to the vertices of the triangles created
+ * byt the tessellatin process.
+ * @param polygonData
+ * Specifics a reference to user-defined data.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #vertex vertex
+ */
+ public void vertexData(Object vertexData, Object polygonData);
+
+
+ /**
+ * The end callback serves the same purpose as
+ * {@link javax.media.opengl.GL#glEnd glEnd}. It indicates the end of a
+ * primitive and it takes no arguments.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #begin begin
+ * @see #endData endData
+ */
+ public void end();
+
+
+ /**
+ * The same as the {@link #end end} callback method except that it
+ * takes an additional reference argument. This reference is
+ * identical to the opaque reference provided when {@link
+ * GLU#gluTessBeginPolygon gluTessBeginPolygon} was called.
+ *
+ * @param polygonData
+ * Specifics a reference to user-defined data.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #beginData beginData
+ * @see #end end
+ */
+ public void endData(Object polygonData);
+
+
+ /**
+ * The <b>combine</b> callback method is called to create a new vertex when
+ * the tessellation detects an intersection, or wishes to merge features. The
+ * method takes four arguments: an array of three elements each of type
+ * double, an array of four references, an array of four elements each of
+ * type float, and a reference to a reference.<P>
+ *
+ * The vertex is defined as a linear combination of up to four existing
+ * vertices, stored in <i>data</i>. The coefficients of the linear combination
+ * are given by <i>weight</i>; these weights always add up to 1. All vertex
+ * pointers are valid even when some of the weights are 0. <i>coords</i> gives
+ * the location of the new vertex.<P>
+ *
+ * The user must allocate another vertex, interpolate parameters using
+ * <i>data</i> and <i>weight</i>, and return the new vertex pointer in
+ * <i>outData</i>. This handle is supplied during rendering callbacks. The
+ * user is responsible for freeing the memory some time after
+ * {@link GLU#gluTessEndPolygon gluTessEndPolygon} is
+ * called.<P>
+ *
+ * For example, if the polygon lies in an arbitrary plane in 3-space, and a
+ * color is associated with each vertex, the <b>GLU_TESS_COMBINE</b>
+ * callback might look like this:
+ * </UL>
+ * <PRE>
+ * void myCombine(double[] coords, Object[] data,
+ * float[] weight, Object[] outData)
+ * {
+ * MyVertex newVertex = new MyVertex();
+ *
+ * newVertex.x = coords[0];
+ * newVertex.y = coords[1];
+ * newVertex.z = coords[2];
+ * newVertex.r = weight[0]*data[0].r +
+ * weight[1]*data[1].r +
+ * weight[2]*data[2].r +
+ * weight[3]*data[3].r;
+ * newVertex.g = weight[0]*data[0].g +
+ * weight[1]*data[1].g +
+ * weight[2]*data[2].g +
+ * weight[3]*data[3].g;
+ * newVertex.b = weight[0]*data[0].b +
+ * weight[1]*data[1].b +
+ * weight[2]*data[2].b +
+ * weight[3]*data[3].b;
+ * newVertex.a = weight[0]*data[0].a +
+ * weight[1]*data[1].a +
+ * weight[2]*data[2].a +
+ * weight[3]*data[3].a;
+ * outData = newVertex;
+ * }</PRE>
+ *
+ * @param coords
+ * Specifics the location of the new vertex.
+ * @param data
+ * Specifics the vertices used to create the new vertex.
+ * @param weight
+ * Specifics the weights used to create the new vertex.
+ * @param outData
+ * Reference user the put the coodinates of the new vertex.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #combineData combineData
+ */
+ public void combine(double[] coords, Object[] data,
+ float[] weight, Object[] outData);
+
+
+ /**
+ * The same as the {@link #combine combine} callback method except
+ * that it takes an additional reference argument. This reference is
+ * identical to the opaque reference provided when {@link
+ * GLU#gluTessBeginPolygon gluTessBeginPolygon} was called.
+ *
+ * @param coords
+ * Specifics the location of the new vertex.
+ * @param data
+ * Specifics the vertices used to create the new vertex.
+ * @param weight
+ * Specifics the weights used to create the new vertex.
+ * @param outData
+ * Reference user the put the coodinates of the new vertex.
+ * @param polygonData
+ * Specifics a reference to user-defined data.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #combine combine
+ */
+ public void combineData(double[] coords, Object[] data,
+ float[] weight, Object[] outData,
+ Object polygonData);
+
+
+ /**
+ * The <b>error</b> callback method is called when an error is encountered.
+ * The one argument is of type int; it indicates the specific error that
+ * occurred and will be set to one of <b>GLU_TESS_MISSING_BEGIN_POLYGON</b>,
+ * <b>GLU_TESS_MISSING_END_POLYGON</b>, <b>GLU_TESS_MISSING_BEGIN_CONTOUR</b>,
+ * <b>GLU_TESS_MISSING_END_CONTOUR</b>, <b>GLU_TESS_COORD_TOO_LARGE</b>,
+ * <b>GLU_TESS_NEED_COMBINE_CALLBACK</b> or <b>GLU_OUT_OF_MEMORY</b>.
+ * Character strings describing these errors can be retrieved with the
+ * {@link GLU#gluErrorString gluErrorString} call.<P>
+ *
+ * The GLU library will recover from the first four errors by inserting the
+ * missing call(s). <b>GLU_TESS_COORD_TOO_LARGE</b> indicates that some
+ * vertex coordinate exceeded the predefined constant
+ * <b>GLU_TESS_MAX_COORD</b> in absolute value, and that the value has been
+ * clamped. (Coordinate values must be small enough so that two can be
+ * multiplied together without overflow.)
+ * <b>GLU_TESS_NEED_COMBINE_CALLBACK</b> indicates that the tessellation
+ * detected an intersection between two edges in the input data, and the
+ * <b>GLU_TESS_COMBINE</b> or <b>GLU_TESS_COMBINE_DATA</b> callback was not
+ * provided. No output is generated. <b>GLU_OUT_OF_MEMORY</b> indicates that
+ * there is not enough memory so no output is generated.
+ *
+ * @param errnum
+ * Specifics the error number code.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #errorData errorData
+ */
+ public void error(int errnum);
+
+
+ /**
+ * The same as the {@link #error error} callback method except that
+ * it takes an additional reference argument. This reference is
+ * identical to the opaque reference provided when {@link
+ * GLU#gluTessBeginPolygon gluTessBeginPolygon} was called.
+ *
+ * @param errnum
+ * Specifics the error number code.
+ * @param polygonData
+ * Specifics a reference to user-defined data.
+ *
+ * @see GLU#gluTessCallback gluTessCallback
+ * @see #error error
+ */
+ public void errorData(int errnum, Object polygonData);
+
+ //void mesh(com.sun.opengl.impl.tessellator.GLUmesh mesh);
+}
Added: trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellatorCallbackAdapter.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellatorCallbackAdapter.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/util/glu/GLUtessellatorCallbackAdapter.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,116 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+* Portions Copyright (C) 2003-2006 Sun Microsystems, Inc.
+* All rights reserved.
+*/
+
+/*
+** License Applicability. Except to the extent portions of this file are
+** made subject to an alternative license as permitted in the SGI Free
+** Software License B, Version 1.1 (the "License"), the contents of this
+** file are subject only to the provisions of the License. You may not use
+** this file except in compliance with the License. You may obtain a copy
+** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
+** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
+**
+** http://oss.sgi.com/projects/FreeB
+**
+** Note that, as provided in the License, the Software is distributed on an
+** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
+** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
+** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
+** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
+**
+** NOTE: The Original Code (as defined below) has been licensed to Sun
+** Microsystems, Inc. ("Sun") under the SGI Free Software License B
+** (Version 1.1), shown above ("SGI License"). Pursuant to Section
+** 3.2(3) of the SGI License, Sun is distributing the Covered Code to
+** you under an alternative license ("Alternative License"). This
+** Alternative License includes all of the provisions of the SGI License
+** except that Section 2.2 and 11 are omitted. Any differences between
+** the Alternative License and the SGI License are offered solely by Sun
+** and not by SGI.
+**
+** Original Code. The Original Code is: OpenGL Sample Implementation,
+** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
+** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
+** Copyright in any portions created by third parties is as indicated
+** elsewhere herein. All Rights Reserved.
+**
+** Additional Notice Provisions: The application programming interfaces
+** established by SGI in conjunction with the Original Code are The
+** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
+** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
+** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
+** Window System(R) (Version 1.3), released October 19, 1998. This software
+** was created using the OpenGL(R) version 1.2.1 Sample Implementation
+** published by SGI, but has not been independently verified as being
+** compliant with the OpenGL(R) version 1.2.1 Specification.
+**
+** Author: Eric Veach, July 1994
+** Java Port: Pepijn Van Eeckhoudt, July 2003
+** Java Port: Nathan Parker Burg, August 2003
+*/
+package org.lwjgl.util.glu;
+
+/**
+ * The <b>GLUtessellatorCallbackAdapter</b> provides a default implementation of
+ * {@link GLUtessellatorCallback GLUtessellatorCallback}
+ * with empty callback methods. This class can be extended to provide user
+ * defined callback methods.
+ *
+ * @author Eric Veach, July 1994
+ * @author Java Port: Pepijn Van Eechhoudt, July 2003
+ * @author Java Port: Nathan Parker Burg, August 2003
+ */
+
+public class GLUtessellatorCallbackAdapter implements GLUtessellatorCallback {
+ public void begin(int type) {}
+ public void edgeFlag(boolean boundaryEdge) {}
+ public void vertex(Object vertexData) {}
+ public void end() {}
+// public void mesh(com.sun.opengl.impl.tessellator.GLUmesh mesh) {}
+ public void error(int errnum) {}
+ public void combine(double[] coords, Object[] data,
+ float[] weight, Object[] outData) {}
+ public void beginData(int type, Object polygonData) {}
+ public void edgeFlagData(boolean boundaryEdge,
+ Object polygonData) {}
+ public void vertexData(Object vertexData, Object polygonData) {}
+ public void endData(Object polygonData) {}
+ public void errorData(int errnum, Object polygonData) {}
+ public void combineData(double[] coords, Object[] data,
+ float[] weight, Object[] outData,
+ Object polygonData) {}
+}
Added: trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/ActiveRegion.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/ActiveRegion.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/ActiveRegion.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,100 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+* Portions Copyright (C) 2003-2006 Sun Microsystems, Inc.
+* All rights reserved.
+*/
+
+/*
+** License Applicability. Except to the extent portions of this file are
+** made subject to an alternative license as permitted in the SGI Free
+** Software License B, Version 1.1 (the "License"), the contents of this
+** file are subject only to the provisions of the License. You may not use
+** this file except in compliance with the License. You may obtain a copy
+** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
+** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
+**
+** http://oss.sgi.com/projects/FreeB
+**
+** Note that, as provided in the License, the Software is distributed on an
+** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
+** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
+** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
+** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
+**
+** NOTE: The Original Code (as defined below) has been licensed to Sun
+** Microsystems, Inc. ("Sun") under the SGI Free Software License B
+** (Version 1.1), shown above ("SGI License"). Pursuant to Section
+** 3.2(3) of the SGI License, Sun is distributing the Covered Code to
+** you under an alternative license ("Alternative License"). This
+** Alternative License includes all of the provisions of the SGI License
+** except that Section 2.2 and 11 are omitted. Any differences between
+** the Alternative License and the SGI License are offered solely by Sun
+** and not by SGI.
+**
+** Original Code. The Original Code is: OpenGL Sample Implementation,
+** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
+** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
+** Copyright in any portions created by third parties is as indicated
+** elsewhere herein. All Rights Reserved.
+**
+** Additional Notice Provisions: The application programming interfaces
+** established by SGI in conjunction with the Original Code are The
+** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
+** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
+** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
+** Window System(R) (Version 1.3), released October 19, 1998. This software
+** was created using the OpenGL(R) version 1.2.1 Sample Implementation
+** published by SGI, but has not been independently verified as being
+** compliant with the OpenGL(R) version 1.2.1 Specification.
+**
+** Author: Eric Veach, July 1994
+** Java Port: Pepijn Van Eeckhoudt, July 2003
+** Java Port: Nathan Parker Burg, August 2003
+*/
+package org.lwjgl.util.glu.tessellation;
+
+class ActiveRegion {
+ GLUhalfEdge eUp; /* upper edge, directed right to left */
+ DictNode nodeUp; /* dictionary node corresponding to eUp */
+ int windingNumber; /* used to determine which regions are
+ * inside the polygon */
+ boolean inside; /* is this region inside the polygon? */
+ boolean sentinel; /* marks fake edges at t = +/-infinity */
+ boolean dirty; /* marks regions where the upper or lower
+ * edge has changed, but we haven't checked
+ * whether they intersect yet */
+ boolean fixUpperEdge; /* marks temporary edges introduced when
+ * we process a "right vertex" (one without
+ * any edges leaving to the right) */
+}
Added: trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/CachedVertex.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/CachedVertex.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/CachedVertex.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,90 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+* Portions Copyright (C) 2003-2006 Sun Microsystems, Inc.
+* All rights reserved.
+*/
+
+/*
+** License Applicability. Except to the extent portions of this file are
+** made subject to an alternative license as permitted in the SGI Free
+** Software License B, Version 1.1 (the "License"), the contents of this
+** file are subject only to the provisions of the License. You may not use
+** this file except in compliance with the License. You may obtain a copy
+** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
+** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
+**
+** http://oss.sgi.com/projects/FreeB
+**
+** Note that, as provided in the License, the Software is distributed on an
+** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
+** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
+** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
+** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
+**
+** NOTE: The Original Code (as defined below) has been licensed to Sun
+** Microsystems, Inc. ("Sun") under the SGI Free Software License B
+** (Version 1.1), shown above ("SGI License"). Pursuant to Section
+** 3.2(3) of the SGI License, Sun is distributing the Covered Code to
+** you under an alternative license ("Alternative License"). This
+** Alternative License includes all of the provisions of the SGI License
+** except that Section 2.2 and 11 are omitted. Any differences between
+** the Alternative License and the SGI License are offered solely by Sun
+** and not by SGI.
+**
+** Original Code. The Original Code is: OpenGL Sample Implementation,
+** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
+** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
+** Copyright in any portions created by third parties is as indicated
+** elsewhere herein. All Rights Reserved.
+**
+** Additional Notice Provisions: The application programming interfaces
+** established by SGI in conjunction with the Original Code are The
+** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
+** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
+** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
+** Window System(R) (Version 1.3), released October 19, 1998. This software
+** was created using the OpenGL(R) version 1.2.1 Sample Implementation
+** published by SGI, but has not been independently verified as being
+** compliant with the OpenGL(R) version 1.2.1 Specification.
+**
+** Author: Eric Veach, July 1994
+** Java Port: Pepijn Van Eeckhoudt, July 2003
+** Java Port: Nathan Parker Burg, August 2003
+*/
+package org.lwjgl.util.glu.tessellation;
+
+class CachedVertex {
+ public double[] coords = new double[3];
+ public Object data;
+}
Added: trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/Dict.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/Dict.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/Dict.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,172 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+/*
+* Portions Copyright (C) 2003-2006 Sun Microsystems, Inc.
+* All rights reserved.
+*/
+
+/*
+** License Applicability. Except to the extent portions of this file are
+** made subject to an alternative license as permitted in the SGI Free
+** Software License B, Version 1.1 (the "License"), the contents of this
+** file are subject only to the provisions of the License. You may not use
+** this file except in compliance with the License. You may obtain a copy
+** of the License at Silicon Graphics, Inc., attn: Legal Services, 1600
+** Amphitheatre Parkway, Mountain View, CA 94043-1351, or at:
+**
+** http://oss.sgi.com/projects/FreeB
+**
+** Note that, as provided in the License, the Software is distributed on an
+** "AS IS" basis, with ALL EXPRESS AND IMPLIED WARRANTIES AND CONDITIONS
+** DISCLAIMED, INCLUDING, WITHOUT LIMITATION, ANY IMPLIED WARRANTIES AND
+** CONDITIONS OF MERCHANTABILITY, SATISFACTORY QUALITY, FITNESS FOR A
+** PARTICULAR PURPOSE, AND NON-INFRINGEMENT.
+**
+** NOTE: The Original Code (as defined below) has been licensed to Sun
+** Microsystems, Inc. ("Sun") under the SGI Free Software License B
+** (Version 1.1), shown above ("SGI License"). Pursuant to Section
+** 3.2(3) of the SGI License, Sun is distributing the Covered Code to
+** you under an alternative license ("Alternative License"). This
+** Alternative License includes all of the provisions of the SGI License
+** except that Section 2.2 and 11 are omitted. Any differences between
+** the Alternative License and the SGI License are offered solely by Sun
+** and not by SGI.
+**
+** Original Code. The Original Code is: OpenGL Sample Implementation,
+** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
+** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
+** Copyright in any portions created by third parties is as indicated
+** elsewhere herein. All Rights Reserved.
+**
+** Additional Notice Provisions: The application programming interfaces
+** established by SGI in conjunction with the Original Code are The
+** OpenGL(R) Graphics System: A Specification (Version 1.2.1), released
+** April 1, 1999; The OpenGL(R) Graphics System Utility Library (Version
+** 1.3), released November 4, 1998; and OpenGL(R) Graphics with the X
+** Window System(R) (Version 1.3), released October 19, 1998. This software
+** was created using the OpenGL(R) version 1.2.1 Sample Implementation
+** published by SGI, but has not been independently verified as being
+** compliant with the OpenGL(R) version 1.2.1 Specification.
+**
+** Author: Eric Veach, July 1994
+** Java Port: Pepijn Van Eeckhoudt, July 2003
+** Java Port: Nathan Parker Burg, August 2003
+*/
+package org.lwjgl.util.glu.tessellation;
+
+class Dict {
+ DictNode head;
+ Object frame;
+ DictLeq leq;
+
+ private Dict() {
+ }
+
+ static Dict dictNewDict(Object frame, DictLeq leq) {
+ Dict dict = new Dict();
+ dict.head = new DictNode();
+
+ dict.head.key = null;
+ dict.head.next = dict.head;
+ dict.head.prev = dict.head;
+
+ dict.frame = frame;
+ dict.leq = leq;
+
+ return dict;
+ }
+
+ static void dictDeleteDict(Dict dict) {
+ dict.head = null;
+ dict.frame = null;
+ dict.leq = null;
+ }
+
+ static DictNode dictInsert(Dict dict, Object key) {
+ return dictInsertBefore(dict, dict.head, key);
+ }
+
+ static DictNode dictInsertBefore(Dict dict, DictNode node, Object key) {
+ do {
+ node = node.prev;
+ } while (node.key != null && !dict.leq.leq(dict.frame, node.key, key));
+
+ DictNode newNode = new DictNode();
+ newNode.key = key;
+ newNode.next = node.next;
+ node.next.prev = newNode;
+ newNode.prev = node;
+ node.next = newNode;
+
+ return newNode;
+ }
+
+ static Object dictKey(DictNode aNode) {
+ return aNode.key;
+ }
+
+ static DictNode dictSucc(DictNode aNode) {
+ return aNode.next;
+ }
+
+ static DictNode dictPred(DictNode aNode) {
+ return aNode.prev;
+ }
+
+ static DictNode dictMin(Dict aDict) {
+ return aDict.head.next;
+ }
+
+ static DictNode dictMax(Dict aDict) {
+ return aDict.head.prev;
+ }
+
+ static void dictDelete(Dict dict, DictNode node) {
+ node.next.prev = node.prev;
+ node.prev.next = node.next;
+ }
+
+ static DictNode dictSearch(Dict dict, Object key) {
+ DictNode node = dict.head;
+
+ do {
+ node = node.next;
+ } while (node.key != null && !(dict.leq.leq(dict.frame, key, node.key)));
+
+ return node;
+ }
+
+ public interface DictLeq {
+ boolean leq(Object frame, Object key1, Object key2);
+ }
+}
Added: trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/DictNode.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/DictNode.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/util/glu/tessellation/DictNode.java 2009-04-05 22:07:46 UTC (rev 3195)
@@ -0,0 +1,91 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF TH...
[truncated message content] |
|
From: <sp...@us...> - 2009-04-04 19:19:47
|
Revision: 3194
http://java-game-lib.svn.sourceforge.net/java-game-lib/?rev=3194&view=rev
Author: spasi
Date: 2009-04-04 19:19:43 +0000 (Sat, 04 Apr 2009)
Log Message:
-----------
Fixed ContextAttribs version validation.
Added OpenGL version test.
Modified Paths:
--------------
trunk/LWJGL/src/java/org/lwjgl/opengl/ContextAttribs.java
Added Paths:
-----------
trunk/LWJGL/src/java/org/lwjgl/test/opengl/VersionTest.java
Modified: trunk/LWJGL/src/java/org/lwjgl/opengl/ContextAttribs.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/opengl/ContextAttribs.java 2009-03-27 12:56:14 UTC (rev 3193)
+++ trunk/LWJGL/src/java/org/lwjgl/opengl/ContextAttribs.java 2009-04-04 19:19:43 UTC (rev 3194)
@@ -72,7 +72,7 @@
if ( majorVersion < 0 ||
3 < majorVersion ||
minorVersion < 0 ||
- (majorVersion == 3 && 0 < minorVersion) ||
+ (majorVersion == 3 && 1 < minorVersion) ||
(majorVersion == 2 && 1 < minorVersion) ||
(majorVersion == 1 && 5 < minorVersion) )
throw new IllegalArgumentException("Invalid OpenGL version specified: " + majorVersion + '.' + minorVersion);
Added: trunk/LWJGL/src/java/org/lwjgl/test/opengl/VersionTest.java
===================================================================
--- trunk/LWJGL/src/java/org/lwjgl/test/opengl/VersionTest.java (rev 0)
+++ trunk/LWJGL/src/java/org/lwjgl/test/opengl/VersionTest.java 2009-04-04 19:19:43 UTC (rev 3194)
@@ -0,0 +1,185 @@
+/*
+ * Copyright (c) 2002-2008 LWJGL Project
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions are
+ * met:
+ *
+ * * Redistributions of source code must retain the above copyright
+ * notice, this list of conditions and the following disclaimer.
+ *
+ * * Redistributions in binary form must reproduce the above copyright
+ * notice, this list of conditions and the following disclaimer in the
+ * documentation and/or other materials provided with the distribution.
+ *
+ * * Neither the name of 'LWJGL' nor the names of
+ * its contributors may be used to endorse or promote products derived
+ * from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
+ * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+ * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
+ * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+ * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
+ * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
+ * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+ * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+/*
+ * Created by LWJGL.
+ * User: spasi
+ * Date: 2009-04-04
+ * Time: 21:20:24 pm
+ */
+
+package org.lwjgl.test.opengl;
+
+import org.lwjgl.LWJGLException;
+import org.lwjgl.opengl.*;
+
+import java.util.StringTokenizer;
+import java.util.regex.Pattern;
+
+public final class VersionTest {
+
+ private VersionTest() {
+ }
+
+ public static void main(String[] args) {
+ initialize(args);
+ cleanup();
+ System.exit(0);
+ }
+
+ private static void initialize(String[] args) {
+ if ( args.length < 2 )
+ argsError("Insufficient number of arguments");
+
+ int majorInput = 1;
+ int minorInput = 0;
+
+ try {
+ majorInput = Integer.parseInt(args[0]);
+ minorInput = Integer.parseInt(args[1]);
+ } catch (NumberFormatException e) {
+ argsError("Invalid number format");
+ }
+
+ ContextAttribs ca = new ContextAttribs(majorInput, minorInput);
+
+ if ( 2 < args.length ) {
+ for ( int i = 2; i < args.length; i++ ) {
+ if ( Pattern.matches("[0-9]+", args[i]) )
+ ca = ca.withLayer(Integer.parseInt(args[i]));
+ else if ( "debug".equalsIgnoreCase(args[i]) )
+ ca = ca.withDebug(true);
+ else if ( "fc".equalsIgnoreCase(args[i]) )
+ ca = ca.withForwardCompatible(true);
+ else
+ argsError("Unknown argument: \'" + args[i] + "\'");
+ }
+ }
+
+ try {
+ DisplayMode[] modes = Display.getAvailableDisplayModes();
+
+ DisplayMode displayMode;
+
+ displayMode = chooseMode(modes, 1024, 768);
+ if ( displayMode == null )
+ displayMode = chooseMode(modes, 800, 600);
+ if ( displayMode == null )
+ displayMode = chooseMode(modes, 640, 480);
+ if ( displayMode == null )
+ kill("Failed to set an appropriate display mode.");
+
+ System.out.println("Setting display mode to: " + displayMode);
+ Display.setDisplayMode(displayMode);
+ Display.create(new PixelFormat(8, 24, 0), ca);
+ } catch (LWJGLException e) {
+ kill(e.getMessage());
+ }
+
+ System.out.println("\n---------\n");
+
+ final String version = GL11.glGetString(GL11.GL_VERSION);
+
+ System.out.println("GL Version requested: " + majorInput + '.' + minorInput);
+ System.out.println("GL Version returned : " + version);
+
+ final StringTokenizer version_tokenizer = new StringTokenizer(version, ". ");
+
+ int majorVersion = Integer.parseInt(version_tokenizer.nextToken());
+ int minorVersion = Integer.parseInt(version_tokenizer.nextToken());
+
+ if ( majorVersion != majorInput || minorVersion != minorInput ) {
+ if ( majorInput == 1 && minorInput == 0 )
+ System.out.println("\tThe maximum supported version has been returned. The driver is well-behaved. :)");
+ else if ( majorInput < 3 && majorVersion < 3 )
+ System.out.println("\tThe maximum supported version pre-3.0 has been returned. The driver is well-behaved. :)");
+ else
+ System.out.println("\tThe requested version was not returned. The driver is buggy! :(");
+ } else
+ System.out.println("\tThe requested version was returned. :)");
+
+ System.out.println("\n---------\n");
+
+ System.out.println("Debug mode: " + ca.isDebug());
+ System.out.println("Forward compatible mode: " + ca.isForwardCompatible());
+ System.out.println("ARB_compatibility: " + GLContext.getCapabilities().GL_ARB_compatibility);
+ try {
+ GL11.glVertex3f(0.0f, 0.0f, 0.0f);
+ System.out.println("Deprecated functionality present: " + true);
+ } catch (Throwable t) {
+ System.out.println("Deprecated functionality present: " + false);
+ if ( GLContext.getCapabilities().GL_ARB_compatibility ) {
+ System.out.println("\tARB_compatibility is present, but LWJGL has enabled pseudo-forward compatible mode.");
+ }
+ }
+ }
+
+ private static DisplayMode chooseMode(DisplayMode[] modes, int width, int height) {
+ DisplayMode bestMode = null;
+
+ for ( int i = 0; i < modes.length; i++ ) {
+ DisplayMode mode = modes[i];
+ if ( mode.getWidth() == width && mode.getHeight() == height && mode.getFrequency() <= 85 ) {
+ if ( bestMode == null || (mode.getBitsPerPixel() >= bestMode.getBitsPerPixel() && mode.getFrequency() > bestMode.getFrequency()) )
+ bestMode = mode;
+ }
+ }
+
+ return bestMode;
+ }
+
+ private static void cleanup() {
+ if ( Display.isCreated() )
+ Display.destroy();
+ }
+
+ private static void argsError(final String msg) {
+ System.out.println("\nInvalid arguments error: " + msg);
+ System.out.println("\nUsage: VersionTest <majorVersion> <minorVersion> {<layer>, 'debug', 'fc'}:\n");
+ System.out.println("majorVersion\t- Major OpenGL version.");
+ System.out.println("majorVersion\t- Minor OpenGL version.");
+ System.out.println("layer\t- Layer plane (optional).");
+ System.out.println("debug\t- Enables debug mode (optional).");
+ System.out.println("fc\t- Enables forward compatibility mode (optional).");
+
+ cleanup();
+ System.exit(-1);
+ }
+
+ static void kill(String reason) {
+ System.out.println("The VersionTest program was terminated because an error occured.\n");
+ System.out.println("Reason: " + (reason == null ? "Unknown" : reason));
+
+ cleanup();
+ System.exit(-1);
+ }
+
+}
\ No newline at end of file
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|