[sdljava-users] Upcoming Features
Status: Beta
Brought to you by:
ivan_ganza
|
From: Ivan Z. G. <iva...@ya...> - 2005-01-06 05:07:16
|
Greetings,
I wanted to update you on features that will be in the next release.
I'm adding a set of methods to SDLImage, SDLMixer and SDLTTF so that
each module can load images, wav, music or ttf files like so:
SDLImage.load(byte[] data)
SDLImage.load(URL url)
SDLImage.load(ByteBuffer data)
SDLMixer.loadWAV(byte[] data)
SDLMixer.loadWAV(URL url)
SDLMixer.loadWAV(ByteBuffer data)
SDLMixer.loadMUS(byte[] data)
SDLMixer.loadMUS(URL url)
SDLMixer.loadMUS(ByteBuffer data)
SDLTTF.openFont(byte[] data)
SDLTTF.openFont(URL url)
SDLTTF.openFont(ByteBuffer data)
This should allow one to use these modules more naturally from java.
I've already got it working for loadWAV using SDL_RWops on the C side
and it works perfectly. Thanks to Robert Schuster for the suggestion.
I'm also planning to implement SDLSurface.updateRects(...) in a much
faster way using Direct buffers. Finally there will be a few new
methods added called queueBlit(...) and queueUpdateRect(...). What they
will do is basically allow one to "queue" blits or updates, then later
call either flushBlits() or flushUpdates() to send them to the native
layer and have ALL the blits or updates processed at one time in C. So
for example if you did 100 blits normally that would be 100 separate JNI
calls. In this case it will mean one JNI to do all 100 updates. I
believe this should produce performance near to that which can now be
achieved in C code.
Oh and I've been able to get a full OpenGL binding working via the
import of the opengl from the Lightweight Java Game Library --
http://www.lwjgl.org/. Actually needed to slightly hack the jar file to
make a few methods public, however, I am able to use their opengl
binding so far without any troubles. I'm not sure that I want to stick
with this forever due to certain aspects of its design, but, for now we
would have the capability to fully utilize opengl from sdljava. I'm not
sure that this will make it into next release but if anyone really needs
to use opengl in this way please let me know.
Next release should be in about one month.
Please let me know any suggestions, comments or questions.
Thanks,
-Ivan/
|