octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [OctDev] Java/OpenGL-based graphics package for octave


From: David Bateman
Subject: Re: [OctDev] Java/OpenGL-based graphics package for octave
Date: Mon, 23 Apr 2007 13:38:35 +0200
User-agent: Thunderbird 1.5.0.7 (X11/20060921)

Michael Goffioul wrote:
> Hi,
>
> People interested may have a look at the code I'm working on. It's a
> graphics
> package for octave, based on Java for the windowing environment and
> OpenGL
> for the 3D rendering. The package is available at
>
> http://www.geocities.com/sw286000/oplot-gl/
>
> The package is aimed to be fully compatible with the handle-based
> graphics
> system of Matlab. Up to now, I focused on the graphics core object
> (line, patch,
> surface, image and light) and the 3D visualization (2D is just a
> special case).
> It's still in early stage, but you can already do interesting or
> advanced things
> with it (see the attachment for an example of surface with lighting and
> transparency).
>
> The current features are (non-exhaustive):
> - all core objects: line, patch, surface, image, text and light
> - lighting and transparency
> - full camera-based 3D visualization like in Matlab
> - basic support for legends and stem series
> - mouse-based zoom and 3D rotation (use middle button to switch
> between 2 modes, no GUI yet)
>
> As requirements, you need Java, JOGL (Java interface to OpenGL) and
> the java interface package from octave-forge. The README file of the
> package contains a few hints for installation (especially for JOGL).
> I only tested it under Windows, so it's highly probably that it won't
> work out-of-the-box under UNIX systems.
>
> My goal is to go one step further and also support GUI elements
> (buttons, comboboxes...) as well as other higher-level objects used
> in Matlab (bar series, contour series...)
>
> If you give it a try, could you report your experience to me? I'd be
> glad to
> hear from you.
>
> Michael.

Just a comment on the src/Makefile, which contains

<quote>
CLASSPATH = jogl.jar:/usr/local/octave-vc8-debug/forge/java/octave.jar

all: oplot-gl.jar

oplot-gl.jar:
        javac -cp $(CLASSPATH) -source 1.2 -target 1.2
org/octave/graphics/*.java
        jar cf oplot-gl.jar org/octave/graphics/*.class
</quote>

You can't hard-code the CLASSPATH in that manner. Maybe you need a
configure script to probe what this value should be. Furthermore I'd
suggest modifying the all target to be
/
all: oplot-gl.jar
    @if [ -d ../bin ]; then rm -rf ../bin; fi; \
    mkdir ../bin; \
    $(CP) oplot-gl.jar ../bin

/And then have a clean target that looked like

/clean:
    $(RM) ../bin oplot-gl.jar org/octave/graphics/*.class
/
In this way the jar will be on the execpath of octave when the package
is loaded. I also don't think the high level plotting functions such as
stem, surf, image, legend, etc should be touched (though surf isn't in
octave yet), but rather only the code that is called after a drawnow, to
have a simple separation between the graphics front-end and back-end.
This might mean that there are some frontend changes you need, but the
front-end code definitely shouldn't have java specific code in it. This
goes equally for patch and light which should be in the front-end with
appropriate objects in
src/graphics.cc and then only rendered into java in the backend.

In any case Michael, this is great and I even if it is only Windows,
intgerate it with your MSVC build and it might well become the most used
octave graphics backend of all..

Cheers
David




> ------------------------------------------------------------------------
>
> -------------------------------------------------------------------------
> This SF.net email is sponsored by DB2 Express
> Download DB2 Express C - the FREE version of DB2 express and take
> control of your XML. No limits. Just data. Click to get it now.
> http://sourceforge.net/powerbar/db2/
> ------------------------------------------------------------------------
>
> _______________________________________________
> Octave-dev mailing list
> address@hidden
> https://lists.sourceforge.net/lists/listinfo/octave-dev
>   


-- 
David Bateman                                address@hidden
Motorola Labs - Paris                        +33 1 69 35 48 04 (Ph) 
Parc Les Algorithmes, Commune de St Aubin    +33 6 72 01 06 33 (Mob) 
91193 Gif-Sur-Yvette FRANCE                  +33 1 69 35 77 01 (Fax) 

The information contained in this communication has been classified as: 

[x] General Business Information 
[ ] Motorola Internal Use Only 
[ ] Motorola Confidential Proprietary



reply via email to

[Prev in Thread] Current Thread [Next in Thread]