A few new things in libgdx

Had time to implement a few tiny new things.

  • ETC1 support, sorta. See the ETC1 class and the ETC1Test. I have yet to wire that one up to Texture which will support loading PKM files through the ETC1 class in OpenGL ES 2.0. Why only OpenGL ES 2.0? Cause ETC1 is guaranteed to work there. If you want ETC1 support on OpenGL ES 1.x you can still use the ETC1 class.
  • GWT-backend based on WebGL, sorta. Far away from being finished, but i was able to figure out all the necessities. The biggest hurdle is the asynchronous nature of loading resources in GWT. But i think i found a convenient way to solve that. Also, given the lack of JNI support, some features like Box2D will not be available. However, one can resort to JBox2D (as the guys of the foreplay project did).
  • Pixmap has a new constructor that lets you pass in a byte[] array that holds image data encoded as a JPEG, PNG or BMP. Might come in handy
  • Couple of small fixes here and there, see the SVN changelog

I’ll not be around over the weekend, moving to SF and all that jazz.

Not Dead Yet

I’m not dead, i’m just really busy spending time with the woman and arranging things for my move to San Francisco. In other news, Nate is back and is actively fixing things on the issue tracker (about time!). I started on a GWT backend based on WebGL via GWT-G3D, we’ll see how far that goes.

An iOS port via Monotouch is something Impaler looked into a little bit. There’re quite a few obstacles (a lot more as in the case of GWT, which should actually work out pretty well). We’ll see how far we get there.

Anyways, i’m still active on the forums and add the occasional bug to the SVN repo, just so you know 🙂

Fun Lunchbreak Experiment: libgdx + .NET (C#)

Today i spent my lunch break on trying out IKVM, which is a JVM ontop of .NET and a way to get interoperability between Java Bytecode & the CLI. I was interested in the later as i wanted to try out whether i could use libgdx from C#. Well, that wasn’t all that hard 🙂

Download the latest IKVM binaries, the latest libgdx nightlies and away you go with the following command line:

You’ll end up with an assembly called gdx-cli.dll. Create a new C# project in Visual Studio, reference the gdx-cli.dll as well as the IKVM and OpenJDK assemblies in the IKVM bin/ folder. Copy the ikvm-native-win32-x86.dll and ikvm-native-win32-x64.dll files to your project and make sure they are copied to the output folder on every build (or when they change). Here’s a screenshot

I only played around with this for 15 minutes, but all the things i tested work. Note that it uses LWJGL as the backend, so you can’t integrate it with a standard Windows Forms/WPF application. On the other hand you can now use libgdx in C# if you want to work with that instead. Compatibility with Android will be lost of course, but you can still stay cross-platform with Mono.

At some point i’ll probably also host .NET nightlies.

hint: if someone gives me a Mac i can try to make this work on IOS 😀