Date: Mon, 30 Aug 2004 12:45:48 -0600 From: Greg Lewis <glewis@eyesbeyond.com> To: freebsd-java@freebsd.org Subject: Native Java3D Message-ID: <20040830184548.GA51796@misty.eyesbeyond.com>
next in thread | raw e-mail | index | archive | help
--45Z9DzgjV8m4Oswq Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Hi all, As the Java3D source code is now available <https://java3d.dev.java.net/> we can produce a native version of it. To this end, I worked up some fairly simple patches a while ago to do this. I tested them last night and the examples appear to work (or at least the ones I tried did). If anyone is interested, please grab the source code and apply the attached patch to the j3d-core sub-project. Then just follow the build and use instructions as normal. It would be useful for someone else to try this out, particularly if you have a big Java3D application you can try it with. I aim to contribute the patch to the project so we'll get a native Java3D 1.3.2. I'd prefer to get a few "works for me" first :). -- Greg Lewis Email : glewis@eyesbeyond.com Eyes Beyond Web : http://www.eyesbeyond.com Information Technology FreeBSD : glewis@FreeBSD.org --45Z9DzgjV8m4Oswq Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename="j3d-core.diff" ? build ? java3d.diff ? src/classes/freebsd ? src/native/ogl/build-freebsd-i586.xml ? src/native/share/build-freebsd-i586.xml Index: build.xml =================================================================== RCS file: /cvs/j3d-core/build.xml,v retrieving revision 1.1 diff -u -r1.1 build.xml --- build.xml 9 Jun 2004 04:21:10 -0000 1.1 +++ build.xml 30 Aug 2004 06:24:55 -0000 @@ -56,13 +56,18 @@ <property name="platform" value="linux-i586"/> </target> + <target name="setupFreeBSD" depends="init" if="isFreeBSDOnX86"> + <property name="ostype" value="freebsd"/> + <property name="platform" value="freebsd-i586"/> + </target> + <!-- win32 should be rename as windows --> <target name="setupWindows" depends="init" if="isWindowsOnX86"> <property name="ostype" value="win32"/> <property name="platform" value="windows-i586-${build.comp}"/> </target> - <target name="setupPlatform" depends="setupSolaris, setupLinux, setupWindows"> + <target name="setupPlatform" depends="setupSolaris, setupLinux, setupFreeBSD, setupWindows"> </target> @@ -85,6 +90,10 @@ <condition property="isLinuxOnX86"> <os name="linux" arch="i386"/> + </condition> + + <condition property="isFreeBSDOnX86"> + <os name="FreeBSD" arch="i386"/> </condition> <condition property="isSolarisOnSparc"> Index: src/classes/share/javax/media/j3d/MasterControl.java =================================================================== RCS file: /cvs/j3d-core/src/classes/share/javax/media/j3d/MasterControl.java,v retrieving revision 1.4 diff -u -r1.4 MasterControl.java --- src/classes/share/javax/media/j3d/MasterControl.java 12 Aug 2004 16:55:17 -0000 1.4 +++ src/classes/share/javax/media/j3d/MasterControl.java 30 Aug 2004 06:24:56 -0000 @@ -48,6 +48,7 @@ static final int RENDER_OPENGL_WIN32 = 1; static final int RENDER_DIRECT3D = 2; static final int RENDER_OPENGL_LINUX = 3; + static final int RENDER_OPENGL_FREEBSD = 4; // Constants used in renderer thread argument static final Integer REQUESTRENDER = new Integer(Renderer.REQUESTRENDER); Index: src/native/build.xml =================================================================== RCS file: /cvs/j3d-core/src/native/build.xml,v retrieving revision 1.1 diff -u -r1.1 build.xml --- src/native/build.xml 9 Jun 2004 04:24:57 -0000 1.1 +++ src/native/build.xml 30 Aug 2004 06:24:57 -0000 @@ -29,6 +29,12 @@ <property name="coreUtilsLibDependency" value="lib/i386/libj3dutils.so"/> </target> + <target name="nativeSetup-debug-freebsd" if="isFreeBSDOnX86"> + <property name="bldFlag" value="g"/> + <property name="coreLibDependency" value="lib/i386/libj3dcore-ogl.so"/> + <property name="coreUtilsLibDependency" value="lib/i386/libj3dutils.so"/> + </target> + <target name="nativeSetup-debug-win32" if="isWindowsOnX86"> <property name="bldFlag" value="-DWIN32 -DDEBUG -D_WINDOWS"/> @@ -37,7 +43,7 @@ </target> - <target name="nativeSetup-debug" depends="nativeSetup-debug-solaris, nativeSetup-debug-linux, nativeSetup-debug-win32"> + <target name="nativeSetup-debug" depends="nativeSetup-debug-solaris, nativeSetup-debug-linux, nativeSetup-debug-freebsd, nativeSetup-debug-win32"> <property name="bldType" value="debug"/> <property name="javahCoreSrc" location="${src}/classes/share/javax/media/j3d"/> @@ -61,6 +67,12 @@ <property name="coreUtilsLibDependency" value="lib/i386/libj3dutils.so"/> </target> + <target name="nativeSetup-opt-freebsd" if="isFreeBSDOnX86"> + <property name="bldFlag" value="O"/> + <property name="coreLibDependency" value="lib/i386/libj3dcore-ogl.so"/> + <property name="coreUtilsLibDependency" value="lib/i386/libj3dutils.so"/> + </target> + <target name="nativeSetup-opt-win32" if="isWindowsOnX86"> <property name="bldFlag" value="-DWIN32 -DNDEBUG -D_WINDOWS"/> @@ -68,7 +80,7 @@ <property name="coreUtilsLibDependency" value="bin/j3dutils.dll"/> </target> - <target name="nativeSetup-opt" depends="nativeSetup-opt-solaris, nativeSetup-opt-linux, nativeSetup-opt-win32"> + <target name="nativeSetup-opt" depends="nativeSetup-opt-solaris, nativeSetup-opt-linux, nativeSetup-opt-freebsd, nativeSetup-opt-win32"> <property name="bldType" value="opt"/> <property name="javahCoreSrc" location="${src}/classes/share/javax/media/j3d"/> Index: src/native/ogl/Canvas3D.c =================================================================== RCS file: /cvs/j3d-core/src/native/ogl/Canvas3D.c,v retrieving revision 1.3 diff -u -r1.3 Canvas3D.c --- src/native/ogl/Canvas3D.c 26 Jul 2004 23:12:55 -0000 1.3 +++ src/native/ogl/Canvas3D.c 30 Aug 2004 06:24:58 -0000 @@ -174,7 +174,7 @@ if(isExtensionSupported(tmpExtensionStr,"GL_NV_register_combiners" )) { ctxInfo->textureRegisterCombinersAvailable = JNI_TRUE; ctxInfo->textureExtMask |= javax_media_j3d_Canvas3D_TEXTURE_REGISTER_COMBINERS; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxInfo->glCombinerInputNV = (MYPFNGLCOMBINERINPUTNV) glCombinerInputNV; ctxInfo->glFinalCombinerInputNV = @@ -285,7 +285,7 @@ ctxInfo->linear_sharpen_rgb_enum = GL_LINEAR_SHARPEN_COLOR_SGIS; ctxInfo->linear_sharpen_alpha_enum = GL_LINEAR_SHARPEN_ALPHA_SGIS; ctxInfo->textureExtMask |= javax_media_j3d_Canvas3D_TEXTURE_SHARPEN; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxInfo->glSharpenTexFuncSGIS = (MYPFNGLSHARPENTEXFUNCSGI) glSharpenTexFuncSGIS; #endif @@ -309,7 +309,7 @@ ctxInfo->texture_detail_mode_enum = GL_DETAIL_TEXTURE_MODE_SGIS; ctxInfo->texture_detail_level_enum = GL_DETAIL_TEXTURE_LEVEL_SGIS; ctxInfo->textureExtMask |= javax_media_j3d_Canvas3D_TEXTURE_DETAIL; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxInfo->glDetailTexFuncSGIS = (MYPFNGLDETAILTEXFUNCSGI) glDetailTexFuncSGIS; #endif @@ -328,7 +328,7 @@ ctxInfo->textureFilter4Available = JNI_TRUE; ctxInfo->filter4_enum = GL_FILTER4_SGIS; ctxInfo->textureExtMask |= javax_media_j3d_Canvas3D_TEXTURE_FILTER4; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxInfo->glTexFilterFuncSGIS = (MYPFNGLTEXFILTERFUNCSGI) glTexFilterFuncSGIS; #endif @@ -481,7 +481,7 @@ ctxInfo->bgr_ext_enum = GL_BGR; ctxInfo->texture3DAvailable = JNI_TRUE; ctxInfo->textureExtMask |= javax_media_j3d_Canvas3D_TEXTURE_3D; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxInfo->glTexImage3DEXT = (MYPFNGLTEXIMAGE3DPROC )glTexImage3D; ctxInfo->glTexSubImage3DEXT = (MYPFNGLTEXSUBIMAGE3DPROC )glTexSubImage3D; #endif @@ -500,7 +500,7 @@ if(isExtensionSupported(tmpExtensionStr, "GL_ARB_imaging")){ ctxInfo->blend_color_ext = JNI_TRUE; ctxInfo->blendFunctionTable[7] = GL_CONSTANT_COLOR; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxInfo->glBlendColor = (MYPFNGLBLENDCOLORPROC )glBlendColor; #endif #ifdef WIN32 @@ -540,7 +540,7 @@ ctxInfo->textureExtMask |= javax_media_j3d_Canvas3D_TEXTURE_3D; ctxInfo->texture_3D_ext_enum = GL_TEXTURE_3D_EXT; ctxInfo->texture_wrap_r_ext_enum = GL_TEXTURE_WRAP_R_EXT; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxInfo->glTexImage3DEXT = (MYPFNGLTEXIMAGE3DPROC )glTexImage3DEXT; ctxInfo->glTexSubImage3DEXT = (MYPFNGLTEXSUBIMAGE3DPROC )glTexSubImage3DEXT; /* Fallback to non-EXT variants, needed for older @@ -587,7 +587,7 @@ if(isExtensionSupported(tmpExtensionStr, "GL_EXT_blend_color")){ ctxInfo->blend_color_ext = JNI_TRUE; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxInfo->glBlendColor = (MYPFNGLBLENDCOLOREXTPROC )glBlendColorEXT; #endif #ifdef WIN32 @@ -661,7 +661,7 @@ ctxInfo->geometry_compression_sunx = JNI_TRUE ; } -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) /* * setup ARB_multisample, under windows this is setup in * NativeConfigTemplate when pixel format is choose @@ -888,7 +888,7 @@ stencilSize = pfd.cStencilBits; #endif -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) if(ctxInfo->multi_draw_arrays_ext) { ctxInfo->glMultiDrawArraysEXT = glMultiDrawArraysEXT; ctxInfo->glMultiDrawElementsEXT = glMultiDrawElementsEXT; @@ -1041,7 +1041,7 @@ wglDeleteContext((HGLRC)context); #endif /* WIN32 */ -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) /* glXMakeCurrent((Display *)display, (GLXDrawable)window, NULL); */ @@ -1094,7 +1094,7 @@ GraphicsContextPropertiesInfo *sharedCtxStructure; int PixelFormatID=0; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) GLXContext ctx; jlong hdc; @@ -1296,7 +1296,7 @@ { GraphicsContextPropertiesInfo *ctxProperties = (GraphicsContextPropertiesInfo *)ctxInfo; jlong ctx = ctxProperties->context; -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) glXMakeCurrent((Display *)display, (GLXDrawable)window, (GLXContext)ctx); #endif @@ -2327,7 +2327,7 @@ jint win) { -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) glXSwapBuffers((Display *)display, (Window)win); #endif @@ -2503,7 +2503,7 @@ ctxProperties->glGetColorTableParameteriv = (MYPFNGLGETCOLORTABLEPARAMETERIVPROC)wglGetProcAddress("glGetColorTableParameteriv"); #endif -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxProperties->glColorTable = glColorTable; ctxProperties->glGetColorTableParameteriv = glGetColorTableParameteriv; #endif @@ -2514,7 +2514,7 @@ ctxProperties->glGetColorTableParameteriv = (MYPFNGLGETCOLORTABLEPARAMETERIVPROC)wglGetProcAddress("glGetColorTableParameterivSGI"); #endif -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) ctxProperties->glColorTable = glColorTableSGI; ctxProperties->glGetColorTableParameteriv = glGetColorTableParameterivSGI; #endif @@ -2540,7 +2540,7 @@ #ifndef GLX_VERSION_1_3 #ifdef GLX_SGIX_pbuffer -#ifdef __linux__ +#if defined(__linux__) || defined(__FreeBSD__) typedef XID GLXPbuffer; typedef struct __GLXFBConfigRec *GLXFBConfig; typedef struct __GLXFBConfigRec *GLXFBConfigSGIX; @@ -2575,7 +2575,7 @@ #endif /* __linux__ */ #endif /* GLX_VERSION_1_3 */ -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) #pragma weak glXChooseFBConfig #pragma weak glXCreatePbuffer #pragma weak glXDestroyPbuffer @@ -2597,7 +2597,7 @@ jfloat dvrFactor) { -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) /* Not need to do ext. supported checking. This check is done in java. */ /* fprintf(stderr, "Canvas3D.c -- glXVideoResize -- %d %f\n", win, dvrFactor); */ @@ -2614,7 +2614,7 @@ jboolean enable) { -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) GraphicsContextPropertiesInfo *ctxProperties = (GraphicsContextPropertiesInfo *)ctxInfo; @@ -2644,7 +2644,7 @@ jint height) { -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) XVisualInfo *vinfo, template; int nitems, depth, redSize; Display *dpy; @@ -2848,7 +2848,7 @@ jlong display, jint window) { -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) Display *dpy = (Display*)display; GLboolean pbufferSupported = GL_FALSE; @@ -3158,7 +3158,7 @@ int PixelFormatID=0; GraphicsContextPropertiesInfo* ctxInfo = (GraphicsContextPropertiesInfo *)malloc(sizeof(GraphicsContextPropertiesInfo)); -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) XVisualInfo *vinfo, template; int nitems; GLXContext ctx; @@ -3326,7 +3326,7 @@ /* clear up the context , colormap and window if appropriate */ if(window == 0 && !offScreen){ -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) Java_javax_media_j3d_Canvas3D_destroyContext(env, obj, display, newWin, (jlong)ctxInfo); XDestroyWindow((Display *)display, glWin); XFreeColormap((Display *)display, cmap); @@ -3408,7 +3408,7 @@ return (devMode.dmBitsPerPel > 8); #endif -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) return TRUE; #endif } Index: src/native/ogl/DrawingSurfaceObjectAWT.c =================================================================== RCS file: /cvs/j3d-core/src/native/ogl/DrawingSurfaceObjectAWT.c,v retrieving revision 1.1 diff -u -r1.1 DrawingSurfaceObjectAWT.c --- src/native/ogl/DrawingSurfaceObjectAWT.c 9 Jun 2004 04:25:21 -0000 1.1 +++ src/native/ogl/DrawingSurfaceObjectAWT.c 30 Aug 2004 06:24:58 -0000 @@ -28,7 +28,7 @@ #endif /* DEBUG */ -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) #pragma weak JAWT_GetAWT #endif @@ -145,7 +145,7 @@ } #endif /* SOLARIS */ -#ifdef __linux__ +#if defined(__linux__) || defined(__FreeBSD__) JAWT_X11DrawingSurfaceInfo *xds = (JAWT_X11DrawingSurfaceInfo*) dsi->platformInfo; window = (jint)xds->drawable; Index: src/native/ogl/MasterControl.c =================================================================== RCS file: /cvs/j3d-core/src/native/ogl/MasterControl.c,v retrieving revision 1.1 diff -u -r1.1 MasterControl.c --- src/native/ogl/MasterControl.c 9 Jun 2004 04:25:23 -0000 1.1 +++ src/native/ogl/MasterControl.c 30 Aug 2004 06:24:58 -0000 @@ -32,13 +32,16 @@ #include <winbase.h> #endif /* WIN32 */ -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) #include <unistd.h> #ifdef SOLARIS #include <thread.h> #else #include <pthread.h> #endif +#ifdef __FreeBSD__ +#include <sys/sysctl.h> +#endif #include <dlfcn.h> #include <X11/X.h> #include <X11/Xlib.h> @@ -81,7 +84,7 @@ return glIsMTSafe; #endif /* WIN32 */ -#ifdef __linux__ +#if defined(__linux__) || defined(__FreeBSD__) glIsMTSafe = JNI_TRUE; return glIsMTSafe; #endif /* __linux__ */ @@ -183,6 +186,16 @@ return sysconf(_SC_NPROCESSORS_ONLN); #endif /* SOLARIS || __linux__ */ +#ifdef __FreeBSD__ + int cpus = 1; + size_t len = sizeof(cpus); + int mib[2]; + mib[0] = CTL_HW; + mib[1] = HW_NCPU; + sysctl(mib, 2, &cpus, &len, NULL, 0); + return cpus; +#endif + #ifdef WIN32 SYSTEM_INFO sysInfo; @@ -237,6 +250,10 @@ #ifdef __linux__ /* No-op on linux */ #endif /* __linux__ */ + +#ifdef __FreeBSD__ + /* No-op on FreeBSD */ +#endif /* __FreeBSD__ */ } @@ -258,4 +275,8 @@ #ifdef __linux__ return 8; #endif /* __linux__ */ + +#ifdef __FreeBSD__ + return 8; +#endif /* __FreeBSD__ */ } Index: src/native/ogl/NativeAPIInfo.c =================================================================== RCS file: /cvs/j3d-core/src/native/ogl/NativeAPIInfo.c,v retrieving revision 1.1 diff -u -r1.1 NativeAPIInfo.c --- src/native/ogl/NativeAPIInfo.c 9 Jun 2004 04:25:23 -0000 1.1 +++ src/native/ogl/NativeAPIInfo.c 30 Aug 2004 06:24:58 -0000 @@ -35,4 +35,8 @@ #ifdef __linux__ return (jint)javax_media_j3d_MasterControl_RENDER_OPENGL_LINUX; #endif /* __linux__ */ + +#ifdef __FreeBSD__ + return (jint)javax_media_j3d_MasterControl_RENDER_OPENGL_FREEBSD; +#endif /* __FreeBSD__ */ } Index: src/native/ogl/NativeConfigTemplate3D.c =================================================================== RCS file: /cvs/j3d-core/src/native/ogl/NativeConfigTemplate3D.c,v retrieving revision 1.2 diff -u -r1.2 NativeConfigTemplate3D.c --- src/native/ogl/NativeConfigTemplate3D.c 4 Aug 2004 05:36:53 -0000 1.2 +++ src/native/ogl/NativeConfigTemplate3D.c 30 Aug 2004 06:24:59 -0000 @@ -22,7 +22,7 @@ #include "gldefs.h" -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) #include <X11/X.h> #include <X11/Xlib.h> #include <X11/Xutil.h> @@ -35,7 +35,7 @@ /* check if the extension is supported */ extern int isExtensionSupported(const char *allExtensions, const char *extension); -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) XVisualInfo *findVisualInfoSwitchDoubleBufferAndStereo(jlong display, jint screen, Index: src/native/ogl/NativeScreenInfo.c =================================================================== RCS file: /cvs/j3d-core/src/native/ogl/NativeScreenInfo.c,v retrieving revision 1.1 diff -u -r1.1 NativeScreenInfo.c --- src/native/ogl/NativeScreenInfo.c 9 Jun 2004 04:25:24 -0000 1.1 +++ src/native/ogl/NativeScreenInfo.c 30 Aug 2004 06:24:59 -0000 @@ -21,7 +21,7 @@ #include "gldefs.h" -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) #include <X11/X.h> #include <X11/Xlib.h> #include <X11/Xutil.h> @@ -31,7 +31,7 @@ #include <windows.h> #endif -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) /* * Class: javax_media_j3d_NativeScreenInfo * Method: openDisplay Index: src/native/ogl/NativeWSInfo.c =================================================================== RCS file: /cvs/j3d-core/src/native/ogl/NativeWSInfo.c,v retrieving revision 1.1 diff -u -r1.1 NativeWSInfo.c --- src/native/ogl/NativeWSInfo.c 9 Jun 2004 04:25:25 -0000 1.1 +++ src/native/ogl/NativeWSInfo.c 30 Aug 2004 06:24:59 -0000 @@ -21,7 +21,7 @@ #include "gldefs.h" -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) #include <X11/X.h> #include <X11/Xlib.h> #include <X11/Xutil.h> Index: src/native/ogl/gl_1_2.h =================================================================== RCS file: /cvs/j3d-core/src/native/ogl/gl_1_2.h,v retrieving revision 1.1 diff -u -r1.1 gl_1_2.h --- src/native/ogl/gl_1_2.h 9 Jun 2004 04:25:30 -0000 1.1 +++ src/native/ogl/gl_1_2.h 30 Aug 2004 06:24:59 -0000 @@ -95,7 +95,7 @@ #endif #ifndef GL_ARB_multisample -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) #define GLX_SAMPLE_BUFFERS_ARB 100000 #define GLX_SAMPLES_ARB 100001 #endif Index: src/native/ogl/gldefs.h =================================================================== RCS file: /cvs/j3d-core/src/native/ogl/gldefs.h,v retrieving revision 1.1 diff -u -r1.1 gldefs.h --- src/native/ogl/gldefs.h 9 Jun 2004 04:25:31 -0000 1.1 +++ src/native/ogl/gldefs.h 30 Aug 2004 06:24:59 -0000 @@ -23,7 +23,7 @@ #include <stdlib.h> #include <string.h> -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) #define GLX_GLEXT_PROTOTYPES #define GLX_GLXEXT_PROTOTYPES #include <limits.h> @@ -302,7 +302,7 @@ #define J3D_RGBA javax_media_j3d_Texture_RGBA #ifndef D3D -#if defined(SOLARIS) || defined(__linux__) +#if defined(SOLARIS) || defined(__linux__) || defined(__FreeBSD__) extern void APIENTRY glBlendColor (GLclampf, GLclampf, GLclampf, GLclampf); extern void APIENTRY glBlendColorEXT (GLclampf, GLclampf, GLclampf, GLclampf); extern void APIENTRY glColorTable (GLenum, GLenum, GLsizei, GLenum, GLenum, const GLvoid *); --45Z9DzgjV8m4Oswq--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040830184548.GA51796>