Subject: Java interface with OpenInventor graphics

From: Adam Gaither <[email-masked]>
Date: Tue, 12 Jan 1999 09:45:54 -0600

Is there anyone out there who has built a Java based interface with
OpenInventor graphics?  We would like to re-write our X/Motif interface
using Java/Swing.  And if you did, could you give us a quick primer
how you implemented it?

Adam

    _______
   /       |
  /        |===================================================================
 /Starkville Adam Gaither                        Mississippi State University |
 /       * | Senior Systems Integration Analyst  Engineering Research Center  |
 \         | Fax: (601)325-7692                  2 Research Blvd.             |
  |        | Phone: (601)325-2067                Starkville, MS               |
  /        | [email-masked]                39759                        |
 /         |===================================================================
|______    |
      /    |
      \____|

Favorite quote:  "I can explain it for you, but I can't understand it for you."

---

From: Paul Houle <[email-masked]>
Date: Thu, 14 Jan 1999 17:31:09 +0100

I've just gotten over the hump in porting a mixed language Java/C application
from AIX to Digital Unix.  Along the way I've (a) modified CLAPACK so it compiles
a shared library using GNU tools (autoconf,  libtool,  etc.) and (b) found out
(once again) that programming C w/o header files is like playing Russian Roulette
with six bullets in the gun and used cproto to make header files for
LAPACK.

    My current application uses two subroutines from LAPACK/ESSL and has a poorly
designed interface.  But I've been thinking about it,  and it seems to me that it
shouldn't be very hard to make a very low-level interface between Java and
CLAPACK.  The idea would be to provide some huge
class full of static methods,  each of which is a LAPACK subroutine.  (Prehaps in
a perfect world,  this
class would be factored into single,  double,  complex and double complex
subclasses)  Each static method would have the same FORTRAN style calling
conventions as the existing routines:  that is,  arrays of singles and doubles get
passed in and out,  even when passing single floats and doubles get
passed in and out.  (This,  really,  is the only simple way to maintain the
FORTRAN semantics that LAPACK is based on)

    Since the calling conventions are sterotypical,  turning the C prototypes into
Java/JNI glue shouldn't be that hard.  As for dealing with the FORTRAN style
arrays,  I've already got (fairly well designed) wrapper classes that let Java
programs manipulate real and complex FORTRAN arrays,  so this isn't hard.  Another
set of wrapper classes can always be written in Java (probably automatically
generated from the FORTRAN subroutine definitions, which are more descriptive than
the C headers) which provide a more programmer-friendly face.

    So,  I'd like a couple of kinds of feedback.

    (i) In theory,  my dynamically linkable LAPACK (call it LAPACK-D for now)
should compile on any Unix platform out of the box.  In practice it won't.  Is
anybody interested in alpha testing it?

    (ii) Does anybody want/need a set of Java LAPACK bindings,  and would be
interested,  again,  in
testing them?

    (iii) Has this already been done?  and

    (iv) Any other thoughts about my proposal.