So I looked up sdljava, which is a port of SDL to Java. They pretty much just wrap up the C calls using JNI, and put some nice little objects everywhere. It's a bit cleaner than regular SDL using C.
However after trying it out, I found that it crashed all the time. Which was pretty lame. So I decided to roll up my sleeves and make it work. After a little while, I realized that what was causing it to crash was some pointer tricks generated by SWIG, which is an interface generator for C/C++ code. I fixed up some of these pointer tricks and voila! It works again.
I was initially excited and was planning on notifying the maintainer of sdljava, however since there haven't been any commits to the repo for about 4 years, I figured that it has been abandoned.
Update: At some point I removed the sdljava repo, forgetting about this link. Sorry about the inconvenience.
2 comments:
If you have time, could I put it upon you to apply it in the few GUI-related tasks we have?
(It's also be sweet if you could add a few more tasks, as our selection is a bit thin, but that might be asking a bit much of your time.)
Hmm, SDL isn't really a GUI library, it's more of a cross-platform DirectX with less features. I mainly use it for rendering basic primitives like dots or circles really quickly.
Post a Comment