LibGDX

Last updated

libGDX
Original author(s) Mario Zechner
Initial release20 April 2014;9 years ago (2014-04-20) [1]
Stable release
1.12.0 / 2 July 2023;9 months ago (2023-07-02)
Repository
Written in Java, C, C++
Operating system Windows, Linux, Mac OS X , Android, BlackBerry OS , iOS, Java Applet , JavaScript/WebGL [2]
Platform Java platform
License Apache License 2.0 [2]
Website https://libgdx.com

libGDX is a free and open-source [3] game-development application framework [2] written in the Java programming language with some C and C++ components for performance dependent code. [4] It allows for the development of desktop and mobile games by using the same code base. [5] It is cross-platform, supporting Windows, Linux, Mac OS X, Android, iOS, BlackBerry and web browsers with WebGL support. [2] [6]

Contents

History

In the middle of 2009 Mario Zechner, the creator of libGDX, wanted to write Android games and started developing a framework called AFX (Android Effects) for this. When he found that deploying the changes from Desktop to Android device was cumbersome, he modified AFX to work on the Desktop as well, making it easier to test programs. This was the first step toward the game framework later known as libGDX. [1]

In March 2010 Zechner decided to open-source AFX, hosting it on Google Code under the GNU Lesser General Public License (LGPL). However, at the time he stated that "It's not the intention of the framework to be used for creating desktop games anyway", intending the framework to primarily target Android. In April, it got its first contributor. [1] [7]

When Zechner created a Box2D JNI wrapper, this attracted more users and contributors because physics games were popular at the time.[ better source needed ] Many of the issues with Android were resolved because of this. [1]

Because many users suggested switching to a different license due to LGPL not being suitable for Android, libGDX changed its license to the Apache License 2.0 in July 2010, making it possible to use the framework in closed-source commercial games. [1] [8] The same month its phpBB forum was launched. [1] [9]

Due to issues with Java Sound the audio desktop implementation switched to OpenAL in January 2011. [1] [10] Development of a small image manipulation library called Gdx2D was finished as well, which depends on the open source STB library. [1] [11]

The rest of 2011 was spent adding a UI library [12] and working on the basics of a 3D API. [1]

At the start of 2012 Zechner created a small helper library called gdx-jnigen for easing the development of JNI bindings. [1] [13] This made it possible for the gdx-audio [14] and gdx-freetype [15] extensions to be developed over the following months. [1]

Inspired by Google's PlayN cross-platform game development framework that used Google Web Toolkit (GWT) to compile Java to JavaScript code, Zechner wrote an HTML/JavaScript backend over the course of several weeks, which allowed libGDX applications to be run in any browser with WebGL support. [1] After Google abandoned PlayN, it was maintained by Michael Bayne, who added iOS support to it. libGDX used parts of this work for its own MonoTouch-based backend. [1] [16] [17]

In August 2012 the project switched its version control system from Subversion to Git, moving from Google Code to GitHub. However, the issue tracker and wiki remained on Google Code for another year. The main build system was also changed to Maven, making it easier for developers with different IDEs to work together. [1] [18] [19]

Because of issues with the MonoTouch iOS backend Niklas Thernig wrote a RoboVM backend for libGDX in March 2013, which was integrated into the project in September. [1] [20] [21] From March to May 2013 a new 3D API was developed as well and integrated into the library. [1] [22] [23]

In June 2013 the project's website was redone, now featuring a gallery where users can submit their games created with libGDX. [1] [24] As of January 2016 more than 3000 games have been submitted. [25]

After the source code migration to GitHub the year before, in September 2013 the issue tracker and wiki were also moved there from Google Code. [1] [26] The same month the build and dependency management system was switched from Maven to Gradle. [1] [27]

After a cleanup phase in the first months of 2014 libGDX version 1.0 was released on 20 April, more than four years after the start of the project. [1]

In 2014 libGDX was one of the annual Duke's Choice Award winners, being chosen for its focus on platform-independence. [28] [29]

From a diverse team of open source enthusiasts comes libGDX, a cross-platform game development framework that allows programmers to write, test, and debug Java games on a desktop PC running Windows, Linux, or Mac OS X and deploy that same code to Android, iOS and WebGL-enabled browserssomething not widely available right now. The goal of libGDX, says creator Mario Zechner, "is to fulfill the 'write once, run anywhere' promise of the Java platform specifically for game development."

Java Magazine September/October 2014 [30]

In April 2016 it was announced that libGDX would switch to Intel's Multi-OS Engine on the iOS backend after the discontinuation of RoboVM. [31] [32] With the release of libGDX 1.9.3 on 16 May 2016 Multi-OS is provided as an alternative, while by default the library uses its own fork of the open source version of RoboVM. [33] [34]

libGDX Jam

From 18 December 2015 to 18 January 2016 a libGDX game jam was organized together with RoboVM, itch.io and Robotality. From initially 180 theme suggestions "Life in space" was chosen as the jam's main theme, and 83 games were created over the course of the competition. [35] [36]

Release versions

VersionRelease date
Old version, no longer maintained: 1.020 April 2014 [1]
Old version, no longer maintained: 1.123 May 2014 [37]
Old version, no longer maintained: 1.222 June 2014 [38]
Old version, no longer maintained: 1.39 August 2014 [39]
Old version, no longer maintained: 1.410 October 2014 [40]
Old version, no longer maintained: 1.58 December 2014 [41]
Old version, no longer maintained: 1.66 May 2015 [42]
Old version, no longer maintained: 1.721 September 2015 [43]
Old version, no longer maintained: 1.85 January 2016 [44]
Old version, no longer maintained: 1.924 January 2016 [45]
Old version, no longer maintained: 1.1018 April 2021 [46]
Old version, no longer maintained: 1.1111 May 2022 [47]
Current stable version:1.122 July 2023 [48]
Legend:Old version, not maintainedOlder version, still maintainedCurrent stable versionLatest preview versionFuture release

Architecture

libGDX allows the developer to write, test, and debug their application on their own desktop PC and use the same code on Android. It abstracts away the differences between a common Windows/Linux application and an Android application. The usual development cycle consists of staying on the desktop PC as much as possible while periodically verifying that the project still works on Android. Its main goal is to provide total compatibility between desktop and mobile devices, the main difference being speed and processing power. [5]

Backends

The library transparently uses platform-specific code through various backends to access the capabilities of the host platform. Most of the time the developer does not have to write platform-specific code, except for starter classes (also called launchers) that require different setup depending on the backend. [49]

Other JVM languages

While libGDX is written primarily in Java, the compiled bytecode is language-independent, allowing many other JVM languages to directly use the library. The documentation specifically states the interoperability with Ceylon, Clojure, Kotlin, Jython, JRuby and Scala. [54]

Extensions

Several official and third-party extensions exist that add additional functionality to the library.

gdxAI

An artificial intelligence (AI) framework that was split from the main library with version 1.4.1 in October 2014 and moved into its own repository. While it was initially made for libGDX, it can be used with other frameworks as well. The project focuses on AI useful for games, among them pathfinding, decision making and movement. [55] [56]

gdx freetype

Can be used to render FreeType fonts at run time instead of using static bitmap images, which do not scale as well. [57]

Box2D

A wrapper for the Box2D physics library was introduced in 2010 and moved to an extension with the 1.0 release. [1] [58]

packr

A helper tool that bundles a custom JRE with the application so end users do not have to have their own one installed. [59] [60]

Notable games

See also

Related Research Articles

In computing, cross-platform software is computer software that is designed to work in several computing platforms. Some cross-platform software requires a separate build for each platform, but some can be directly run on any platform without special preparation, being written in an interpreted language or compiled to portable bytecode for which the interpreters or run-time packages are common or standard components of all supported platforms.

<span class="mw-page-title-main">LWJGL</span> Open-source Java software game library

The Lightweight Java Game Library (LWJGL) is an open-source software library that provides bindings to a variety of C libraries for video game developers to Java. It exposes cross-platform libraries commonly used in developing video games and multimedia titles, such as Vulkan, OpenGL, OpenAL and OpenCL.

<span class="mw-page-title-main">Adobe AIR</span> Cross-platform runtime system for building rich web applications

Adobe AIR is a cross-platform runtime system currently developed by Harman International, in collaboration with Adobe Inc., for building desktop applications and mobile applications, programmed using Adobe Animate, ActionScript, and optionally Apache Flex. It was originally released in 2008. The runtime supports installable applications on Windows, macOS, and mobile operating systems, including Android, iOS, and BlackBerry Tablet OS.

<span class="mw-page-title-main">JUCE</span> C++ Cross-Platform Application Development Framework

JUCE is an open-source cross-platform C++ application framework, used for the development of desktop and mobile applications. JUCE is used in particular for its GUI and plug-ins libraries. It is dual licensed under the GPLv3 and a commercial license.

<span class="mw-page-title-main">Box2D</span>

Box2D is a free open source 2-dimensional physics simulator engine written in C++ by Erin Catto and published under the MIT license. It has been used in Crayon Physics Deluxe, Limbo, Rolando, Incredibots, Angry Birds, Tiny Wings, Shovel Knight, Transformice, Happy Wheels, and many online Flash games, as well as iPhone, iPad and Android games using the Cocos2d or Moscrif game engine and Corona framework.

This is a comparison of web frameworks for front-end web development that are heavily reliant on JavaScript code for their behavior.

Google App Engine is a cloud computing platform as a service for developing and hosting web applications in Google-managed data centers. Applications are sandboxed and run across multiple servers. App Engine offers automatic scaling for web applications—as the number of requests increases for an application, App Engine automatically allocates more resources for the web application to handle the additional demand.

<span class="mw-page-title-main">WebGL</span> JavaScript bindings for OpenGL in web browsers

WebGL is a JavaScript API for rendering interactive 2D and 3D graphics within any compatible web browser without the use of plug-ins. WebGL is fully integrated with other web standards, allowing GPU-accelerated usage of physics, image processing, and effects in the HTML canvas. WebGL elements can be mixed with other HTML elements and composited with other parts of the page or page background.

Titanium SDK is an open-source framework that allows the creation of native mobile applications on platforms iOS and Android from a single JavaScript codebase. It is presently developed by non-profit software foundation TiDev, Inc.

RemObjects Software is an American software company founded in 2002 by Alessandro Federici and Marc Hoffman. It develops and offers tools and libraries for software developers on a variety of development platforms, including Embarcadero Delphi, Microsoft .NET, Mono, and Apple's Xcode.

<span class="mw-page-title-main">Xamarin</span> American software company

Xamarin is a Microsoft-owned San Francisco-based software company founded in May 2011 by the engineers that created Mono, Xamarin.Android and Xamarin.iOS, which are cross-platform implementations of the Common Language Infrastructure (CLI) and Common Language Specifications.

Dart is a programming language designed by Lars Bak and Kasper Lund and developed by Google. It can be used to develop web and mobile apps as well as server and desktop applications.

<span class="mw-page-title-main">Mono (software)</span> Computer software project

Mono is a free and open-source .NET Framework-compatible software framework. Originally by Ximian, it was later acquired by Novell, and is now being led by Xamarin, a subsidiary of Microsoft and the .NET Foundation. Mono can be run on many software systems.

<span class="mw-page-title-main">Kivy (framework)</span> Free and multi-platform graphical library for Python

Kivy is a free and open source Python framework for developing mobile apps and other multitouch application software with a natural user interface (NUI). It is distributed under the terms of the MIT License, and can run on Android, iOS, Linux, macOS, and Windows.

PlayN is an open source Java software framework and set of libraries intended to create multi-platform games and distributed under the Apache License 2.0. It was started on January 19, 2011 as a game abstraction library built over GWT and was previously named Forplay. As of January 2024, its current version is 2.0.8.

<span class="mw-page-title-main">GraalVM</span> Virtual machine software

GraalVM is a Java Development Kit (JDK) written in Java. The open-source distribution of GraalVM is based on OpenJDK, and the enterprise distribution is based on Oracle JDK. As well as just-in-time (JIT) compilation, GraalVM can compile a Java application ahead of time. This allows for faster initialization, greater runtime performance, and decreased resource consumption, but the resulting executable can only run on the platform it was compiled for. It provides additional programming languages and execution modes. The first production-ready release, GraalVM 19.0, was distributed in May 2019. The most recent release is GraalVM for JDK 22, made available in March 2024.

<span class="mw-page-title-main">OpenFL</span> Software framework for video games

OpenFL is a free and open-source software framework and platform for the creation of multi-platform applications and video games. OpenFL applications can be written in Haxe, JavaScript, or TypeScript, and may be published as standalone applications for several targets including iOS, Android, HTML5, Windows, macOS, Linux, WebAssembly, Flash, AIR, PlayStation 4, PlayStation 3, PlayStation Vita, Xbox One, Wii U, TiVo, Raspberry Pi, and Node.js.

NativeScript is an open-source framework to develop mobile apps on the iOS and Android platforms. It was originally conceived and developed by Progress. At the end of 2019 responsibility for the NativeScript project was taken over by long-time Progress partner, nStudio. In December 2020 nStudio also oversaw the induction of NativeScript into OpenJS Foundation as an Incubating Project. NativeScript apps are built using JavaScript, or by using any programming language that transpiles to JavaScript, such as TypeScript. NativeScript supports the Angular and Vue JavaScript frameworks. Mobile applications built with NativeScript result in fully native apps, which use the same APIs as if they were developed in Xcode or Android Studio. Additionally, software developers can re-purpose third-party libraries from CocoaPods, Maven, and npm.js in their mobile applications without the need for wrappers.

raylib Game programming library

Raylib is a cross-platform open-source software development library. The library was made to create graphical applications and games.

References

  1. 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 Zechner, Mario (20 April 2014). "libGDX 1.0 released". badlogicgames.com. Archived from the original on 13 February 2021. Retrieved 31 December 2015.
  2. 1 2 3 4 "Goals and Features". libgdx.badlogicgames.com. Archived from the original on 6 June 2012. Retrieved 16 December 2015.
  3. "Official website". libgdx.badlogicgames.com. Archived from the original on 27 May 2011. Retrieved 2 January 2016.
  4. "mobilegameengines.com/game_engines/32-libgdx". Archived from the original on 18 January 2015.
  5. 1 2 "Home - libGDX". libgdx.com.
  6. "libgdx/README.md at master". github.com .
  7. Zechner, Mario (6 March 2010). "The Future..." badlogicgames.com. Retrieved 31 December 2015.
  8. Zechner, Mario (13 July 2010). "libgdx changes its license". badlogicgames.com. Retrieved 31 December 2015.
  9. Zechner, Mario (10 July 2010). "Forums!". badlogicgames.com. Retrieved 3 January 2016.
  10. Zechner, Mario (21 January 2011). "OpenAL & Natives Loading in Libgdx". badlogicgames.com. Retrieved 3 January 2016.
  11. Zechner, Mario (26 January 2011). "Gdx2D and Super Jumper". badlogicgames.com. Retrieved 3 January 2016.
  12. Zechner, Mario (25 June 2011). "UI Fun on Android with libgdx". badlogicgames.com. Retrieved 3 January 2016.
  13. Zechner, Mario (3 January 2012). "gdx-jnigen: a stupid idea that might just work". badlogicgames.com. Retrieved 3 January 2016.
  14. Zechner, Mario (8 January 2012). "gdx-audio". badlogicgames.com. Retrieved 3 January 2016.
  15. Zechner, Mario (6 March 2012). "Create BitmapsFonts on the fly with gdx-freetype". badlogicgames.com. Retrieved 3 January 2016.
  16. Zechner, Mario (8 June 2012). "Libgdx on iOS, days 1–2". badlogicgames.com. Retrieved 3 January 2016.
  17. Zechner, Mario (13 June 2012). "Libgdx on iOS, day 5". badlogicgames.com. Retrieved 3 January 2016.
  18. Zechner, Mario (8 August 2012). "Git & Maven". badlogicgames.com. Retrieved 4 January 2016.
  19. Zechner, Mario (10 August 2012). "Libgdx is now on Github (sorta)". badlogicgames.com. Retrieved 4 January 2016.
  20. Zechner, Mario (9 March 2013). "Early stage RoboVM libgdx backend". badlogicgames.com. Retrieved 6 January 2016.
  21. Zechner, Mario (10 September 2013). "RoboVM backend in libgdx nightlies and first performance figures!". badlogicgames.com. Retrieved 6 January 2016.
  22. Zechner, Mario (28 March 2013). "Brace yourselfs, new 3D API incoming". badlogicgames.com. Retrieved 6 January 2016.
  23. Zechner, Mario (20 May 2013). "New 3D API in master". badlogicgames.com. Retrieved 6 January 2016.
  24. Zechner, Mario (29 June 2013). "New libgdx site live!". badlogicgames.com. Retrieved 6 January 2016.
  25. "Gallery". libgdx.badlogicgames.com. Retrieved 6 January 2016.
  26. Zechner, Mario (14 September 2013). "The great libgdx Issue Tracker & Wiki Github Migration". badlogicgames.com. Retrieved 6 January 2016.
  27. Zechner, Mario (22 September 2013). "Welcome your new overlord: Gradle". badlogicgames.com. Retrieved 6 January 2016.
  28. Kvitkar, Caroline (28 September 2014). "2014 Duke's Choice Award Winners". blogs.oracle.com. Retrieved 30 December 2015. Programmers can use this cross-platform game development framework to write, test, and debug Java games.
  29. Zechner, Mario (29 September 2014). "libgdx wins Duke's Choice Award". badlogicgames.com. Retrieved 30 December 2015.
  30. Gill, Philip J. "2014 Duke's Choice Awards". Java Magazine. p. 8. Retrieved 31 December 2015.
  31. 1 2 Zechner, Mario (15 April 2016). "RoboVM is no more, what now?". Archived from the original on 8 November 2020. Retrieved 15 April 2016.
  32. Müller, Henric (15 April 2016). "RoboVM Winding Down". Archived from the original on 15 April 2016. Retrieved 16 April 2016.
  33. 1 2 Zechner, Mario (16 May 2016). "libGDX 1.9.3 released – New iOS backends" . Retrieved 17 May 2016.
  34. "MobiDevelop's RoboVM fork" . Retrieved 17 May 2016.
  35. Zechner, Mario (22 November 2015). "libGDX Jam is on! – Theme Voting Round #1". badlogicgames.com. Retrieved 13 February 2016.
  36. Zechner, Mario (6 February 2016). "libGDX Jam – And the winner is…". badlogicgames.com. Retrieved 13 February 2016.
  37. Zechner, Mario (23 May 2014). "libGDX 1.1.0 released". badlogicgames.com. Retrieved 13 February 2016.
  38. Zechner, Mario (22 June 2014). "libGDX 1.2.0 released". badlogicgames.com. Retrieved 13 February 2016.
  39. Zechner, Mario (9 August 2014). "libGDX 1.3.0 released". badlogicgames.com. Retrieved 13 February 2016.
  40. Zechner, Mario (10 October 2014). "libGDX 1.4.1 released". badlogicgames.com. Retrieved 13 February 2016.
  41. Zechner, Mario (8 December 2014). "libGDX 1.5.0 released". badlogicgames.com. Retrieved 13 February 2016.
  42. Zechner, Mario (6 May 2015). "libGDX 1.6.0 released". badlogicgames.com. Retrieved 13 February 2016.
  43. Zechner, Mario (21 September 2015). "libGDX 1.7.0 released". badlogicgames.com. Retrieved 13 February 2016.
  44. Zechner, Mario (5 January 2016). "libGDX 1.8.0 released". badlogicgames.com. Retrieved 13 February 2016.
  45. Zechner, Mario (24 January 2016). "libGDX 1.9.0 released". badlogicgames.com. Retrieved 13 February 2016.
  46. damios (18 April 2021). "libGDX 1.10.0". libgdx.com. Retrieved 19 April 2021.
  47. damios (11 May 2022). "libGDX 1.11.0". libgdx.com. Retrieved 12 May 2022.
  48. damios (2 July 2023). "libGDX 1.12.0". libgdx.com. Retrieved 24 July 2023.
  49. "Starter classes & configuration - libGDX". libgdx.com. Retrieved 18 January 2022.
  50. Zechner, Mario (5 January 2016). "libGDX 1.8.0". badlogicgames.com. Retrieved 11 January 2016.
  51. Zechner, Mario (12 March 2012). "Libgdx goes HTML5". badlogicgames.com. Retrieved 17 May 2016.
  52. Zechner, Mario (19 January 2013). "Reflection in libgdx's GWT backend". badlogicgames.com. Retrieved 17 May 2016.
  53. Zechner, Mario (17 June 2013). "Reflection API with GWT support!". badlogicgames.com. Retrieved 17 May 2016.
  54. "Using libgdx with other jvm languages". libgdx.com. Retrieved 18 January 2022.
  55. "gdx-ai/README.md". github.com . 12 October 2015. Retrieved 16 January 2016.
  56. "Artificial Intelligence". libgdx.com. Retrieved 18 January 2022.
  57. "Gdx freetype". libgdx.com. Retrieved 18 January 2022.
  58. "Box2d". libgdx.com. Retrieved 18 January 2022.
  59. "libgdx/packr: Packages your JAR, assets and a JVM for distribution on Windows, Linux and Mac OS X". github.com . Retrieved 6 February 2016.
  60. Zechner, Mario (4 May 2014). "Packr – pack your libGDX app for Windows, Linux, Mac OS X". badlogicgames.com. Archived from the original on 27 April 2020. Retrieved 6 February 2016.
  61. Couture, Joel (22 January 2020). "Road to the IGF: Mega Crit Games' Slay the Spire". www.gamasutra.com. Retrieved 22 January 2020.
  62. "Patch notes - Wildermyth Wiki". wildermyth.com. Retrieved 23 August 2022.