aboutsummaryrefslogtreecommitdiffstats
path: root/src/net/java/games/jogl/impl/nurbs/README-PORTING.txt
diff options
context:
space:
mode:
authorKenneth Russel <[email protected]>2004-12-20 20:04:27 +0000
committerKenneth Russel <[email protected]>2004-12-20 20:04:27 +0000
commit167641d406619ba710e2d50005b6886d2874a251 (patch)
treed080e059fa1d034f63946ae68937dd3f97f6943c /src/net/java/games/jogl/impl/nurbs/README-PORTING.txt
parent494740e563ead19828cc44a03230eb066bf84a02 (diff)
Initial incomplete GLU NURBS port under net.java.games.jogl.impl.nurbs
and a small README about the procedures being used during the port git-svn-id: file:///usr/local/projects/SUN/JOGL/git-svn/svn-server-sync/jogl/trunk@180 232f8b59-042b-4e1e-8c03-345bb8c30851
Diffstat (limited to 'src/net/java/games/jogl/impl/nurbs/README-PORTING.txt')
-rwxr-xr-xsrc/net/java/games/jogl/impl/nurbs/README-PORTING.txt40
1 files changed, 40 insertions, 0 deletions
diff --git a/src/net/java/games/jogl/impl/nurbs/README-PORTING.txt b/src/net/java/games/jogl/impl/nurbs/README-PORTING.txt
new file mode 100755
index 000000000..df5f41782
--- /dev/null
+++ b/src/net/java/games/jogl/impl/nurbs/README-PORTING.txt
@@ -0,0 +1,40 @@
+This is a currently incomplete port of SGI's GLU NURBS library from
+C++ to Java. There are a few reasons for doing such a port:
+
+ - The C interface is structured around function pointers. It is
+ generally difficult to bind such interfaces up to Java.
+
+ - Some people have reported crashes on certain Linux distributions
+ when trying to use any routines out of the C GLU library. To date
+ we have not been able to diagnose the root cause of these failures.
+ Porting the code involved from C++ to Java has solved these
+ problems.
+
+The port so far has been started in the internals/ directory. The C++
+sources have been gone through roughly alphabetically and
+transliterated into the appropriate files. The large Subdivider class
+was the current focus of attention at the time of this writing, and a
+closer look indicates that at least a few classes were skipped on the
+way down to some of the Subdivider's sources like intersect.cc. It may
+be a good idea to continue the port in this directory first, since it
+looks like the other directories' sources are built on top of these
+and it would be good to firm up the Java interfaces for the internals
+(and perhaps get the sources to compile) before porting lots of code
+built on top of them.
+
+A couple of notes on the translation:
+
+ - All object pool classes have been removed. The intention is to have
+ a static allocate() method on the appropriate classes which will
+ instantiate populated arrays of these types (not just arrays of
+ null references). See uses of TrimVertex.allocate().
+
+ - There are a significant number of places in the original C++ code
+ where pointer arithmetic is used. Some of these are not obvious
+ until the code has been ported and examined. Bin.java was a good
+ example of this where the algorithms needed some restructuring. At
+ the time of this writing intersect.cc was in the process of being
+ ported and it wasn't clear whether we would need to change some of
+ the APIs or add more utility routines to be able to do pointer
+ arithmetic on, for example, the TrimVertex arrays returned from the
+ allocate() routine.