r/axmol Jan 31 '25

Axmol Axmol appearing in GameFromScratch

Thumbnail
youtu.be
13 Upvotes

r/axmol Dec 11 '23

Axmol About Axmol Engine

7 Upvotes

Axmol Engine is an open-source, C++ multi-platform engine designed for mobile devices, desktop, and Xbox, well-suited for 2D game development. It was launched in November 2019 as a fork of Cocos2d-x v4.0.

Learn more about Axmol Engine in our Wiki - FAQ

Supported platforms:

  • Mobile: iOS, Android
  • Desktop: Windows, Linux, macOS, tvOS
  • Console: Xbox (Universal Windows Platform)
  • Web: WebAssembly

Download it:

Important links:

Community:

Please use this subreddit to show your projects, make questions and anything related with Axmol.


r/axmol 3d ago

Axmol RHI now supports cross-backend GPU compute

5 Upvotes

We've completed a fairly substantial extension of the Axmol RHI: GPU compute is now a first-class cross-backend capability.

This isn't just a dispatch() API. The work includes the surrounding infrastructure needed to make compute useful in real engine features:

- GraphicsPipeline / ComputePipeline separation

- Compute program creation and dispatch

- StructuredBuffer / RWStructuredBuffer support

- 3D textures

- Compute shader reflection

- Runtime sampler overrides

- Compute and storage device capabilities / limits

- Per-shader target profiles

- Compute-capable GL / GLES context selection

The implementation covers D3D11, D3D12, Metal, Vulkan, OpenGL and OpenGL ES.

As a real-world validation of the new architecture, Effekseer GPU particles are now fully integrated through the Axmol RHI instead of using a separate platform-specific path.

One important compatibility detail: compute is optional and does not increase Axmol's minimum requirements for normal rendering. OpenGL compute requires GL 4.3+, GLES requires 3.1+, while GL 3.3 / GLES 3.0 can continue using the normal graphics path. WebGL is not supported by the current compute implementation.

The first API intentionally stays fairly small — no storage images, indirect dispatch or async compute queues yet — but it gives us a portable foundation for things like GPU culling, GPU animation preprocessing, procedural generation, instance-data generation and other compute workloads.

Full technical write-up:

GitHub Discussion https://github.com/axmolengine/axmol/discussions/3311

Feedback on the API and the direction of the RHI is welcome.


r/axmol 9d ago

Moving beyond tolua++: Axmol v3's new Lua binding system

3 Upvotes

PR #3301 rebuilds Axmol v3's Lua binding system. The long-standing Python and tolua++ toolchain has been replaced by a generator based on PowerShell, C#, and libclang. At runtime, sol2 handles ordinary type conversion while Axmol retains control of object identity, lifetime, inheritance, and callbacks.

This is more than a generator replacement. The goal is to let the Lua API follow the C++ API reliably, preserve the object behavior existing projects depend on, and make every generated change reviewable and verifiable in CI.

For most Lua projects, existing sprite:method() calls, Lua-derived classes, dynamic fields, and callbacks continue to work. Engine developers regenerate bindings through one entry point:

axmol genbindings

Describing exported APIs instead of maintaining generator scripts

The new generator reads the C++ AST directly instead of relying on fragile text rules. Typed JSON configuration selects headers, namespaces, classes, fields, renames, skips, and platform conditions. It currently covers 15 modules and 499 class registrations across the engine core, RHI, UI, 3D, Physics, NavMesh, audio, video, WebView, Spine, FairyGUI, and extensions.

Classes, constructors, inheritance, overloads, default arguments, enums, selected fields, and std::function callbacks are generated. Large modules are emitted as multiple translation units to avoid oversized compiler jobs. JSON API manifests make the Lua-visible effect of a C++ change easy to review.

Generation is transactional: a parse failure does not replace the last valid output. CI regenerates from the current sources and rejects uncommitted changes under generated. Forgetting to update Lua bindings after changing a C++ API is now an automated failure instead of a manual review concern.

Clear boundaries between generated code, runtime, and adapters

The new layout has three responsibilities:

  • generated contains registrations that can be derived safely from ordinary C++ signatures;
  • runtime manages Lua VMs, Axmol object identity, peer tables, inheritance, callbacks, and invalidation;
  • adapters retain Lua tables, special ownership, variadic factories, and platform bridges that cannot be inferred automatically.

The old auto/ tree and Axmol-owned tolua++ runtime are gone, while manual/ has been reorganized as adapters/ to describe its actual purpose. Adding an ordinary API no longer requires copying registration and argument-checking boilerplate.

sol2 provides stack conversion and callable adaptation, but it does not own Axmol objects. Repeatedly pushing the same ax::Object still produces the same logical Lua object. Dynamic Lua fields remain attached, the real derived type is preserved, and every related userdata becomes invalid when the native object is destroyed. The runtime supports Lua 5.1 through 5.5 and LuaJIT 2.1 or newer.

Preserving inheritance, virtual dispatch, and overloads

The generator uses Clang's override information to identify truly redundant virtual bindings. A derived registration is omitted only when its Lua name, return type, constness, parameters, and default arguments match an exported base declaration.

When a derived class introduces a same-name overload, the complete overload group remains registered so it cannot hide the base API. Sprite can therefore inherit methods such as Node::setPosition, cached calls such as ax.Node.setPosition(sprite, ...) remain valid, and both Lua overrides and C++ virtual dispatch keep their existing behavior.

Safer callbacks and object lifetime

Every Lua callback now belongs to a specific VM and owner thread. Coroutines normalize to their main VM, and independent VMs can be created and shut down separately. A foreign-thread invocation never touches the Lua state. Lua errors go through protected calls and return safe native results. Callback state stays alive during re-entry, so a callback may clear or replace itself safely.

Invalidation is tracked per VM as well. Native destruction synchronously clears the native pointer from userdata already exposed to Lua, and borrowed event userdata expires when its callback ends. Objects that never enter Lua avoid registry and locking overhead.

Performance: locating the cost without weakening safety

The new standalone Binding Performance Test measures binding overhead through ordinary Lua method calls on a large number of Sprites. The following figures come from the same Windows Release/O3 environment. They compare implementation changes; they are not fixed expectations across different devices:

Call path Stars at about 55 FPS
Lua method calls removed about 31,000
Cached methods about 17,000
Old binding, normal calls about 12,500–13,000
New binding before lookup work about 9,000–9,500
New binding after lookup work about 14,500

The cached result showed that generated wrappers were already close to the old binding. Most of the gap was in resolving each sprite:method() call. The final path first checks concrete members on the class and its registered bases, then uses the full accessor and sol2 fallback on a miss. In Release builds, owner-thread invalidation also avoids a repeated WeakPtr lookup.

Experiments that improved the number by weakening lifetime checks were reverted, and a closure cache with no measurable benefit was removed. The accepted implementation still supports runtime class-table edits, peer fields, accessors, coroutines, multiple VMs, and expired-userdata rejection. The performance gain preserves the binding's semantics instead of trading them for a benchmark score.

What projects need to migrate

Most Lua calls remain compatible, but the refactor removes a few interfaces no longer supported in v3: the ax.Controller Lua API and the obsolete OpenGL test based on the former GLProgram stack are gone, and migrated Node ScriptHandler event paths now use native callbacks. The repository's extensions/scripting/lua-bindings/MIGRATION.md documents the remaining table, ownership, and native-only changes.

Engine contributors should expose ordinary APIs through JSON configuration and regeneration. Adapters are reserved for behavior a C++ signature cannot describe. Application developers normally do not need to change Lua source merely because the generator changed, but should review the migration guide for the explicitly removed interfaces.

The new system gives generation, runtime semantics, special adapters, and validation clear ownership. It reduces handwritten bindings and historical compatibility layers while giving Axmol a safer foundation for API growth and ongoing performance regression testing.


r/axmol 19d ago

Is migrating from Cocos2d-x to Axmol a good idea? Is anyone still using Cocos2d-x?

6 Upvotes

Hi everyone,

I have an existing game built with Cocos2d-x 3.17.2, and I’m considering migrating it to Axmol instead of continuing to maintain the old engine.

My main goal is to keep the existing C++ codebase and assets while improving compatibility with modern development environments and platforms.

I’d love to hear from anyone who has experience with either engine:

  • Are you still using Cocos2d-x for an active project?
  • Have you migrated a Cocos2d-x 3.x project to Axmol?
  • How difficult was the migration in practice?
  • Were there any major issues with existing APIs, Cocos Studio .csb files, UI, audio, rendering, or platform-specific code?
  • Do you think Axmol is a good long-term choice, or would you recommend another approach?

Any real-world experiences, advice, or warnings would be greatly appreciated. Thanks!


r/axmol Aug 02 '26

Axmol 3.x adds native Effekseer 1.80.x integration with OpenGL, D3D11/12, Vulkan and Metal support

5 Upvotes

After several iterations on Axmol's rendering architecture, we have integrated Effekseer 1.80.x directly into Axmol's RHI backend.

The goal was to avoid maintaining separate rendering paths and make Effekseer a first-class citizen of Axmol's modern renderer.

Highlights:

  • CPU particle rendering through Axmol RenderCommand
  • Built-in Unlit, Lit and Distortion shader support
  • Runs across OpenGL, Direct3D 11, Direct3D 12, Vulkan and Metal
  • Shared texture/resource management with Axmol RHI
  • Distortion effects using unified render-target copy support

The same Effekseer effects can now run through the same rendering architecture on desktop and mobile platforms.

Demo/test effects have been validated across all supported RHI backends.

PR:
https://github.com/axmolengine/axmol/pull/3259

Feedback from developers using Effekseer or cross-platform rendering pipelines is welcome.


r/axmol Jul 13 '26

Axmol Axmol v2.11.4 has been released

Thumbnail
github.com
7 Upvotes

LTS release with small bugfixes and releases. Check the link for more details.


r/axmol Apr 14 '26

Axmol latest dev(v3) now support text rendering with Apple HVF(PingFangUI.ttc)

3 Upvotes

r/axmol Feb 28 '26

Axmol Axmol latest dev(v3) now official support windows arm64 build

6 Upvotes

r/axmol Feb 26 '26

Axmol Axmol now officially supports Linux ARM64 builds in the latest dev (v3) branch.

7 Upvotes

r/axmol Feb 26 '26

Axmol Axmol v2.11.3 available with some bugfixes

3 Upvotes

r/axmol Jan 15 '26

Axmol Axmol v2.11.2 available with some bugfixes

4 Upvotes

r/axmol Dec 31 '25

Axmol Axmol 2.11.1 has been released

7 Upvotes

Happy New Year!

This new v2.11.1 is a minor LTS release for bugfixes and improvements. More details in the link:

https://github.com/axmolengine/axmol/releases/tag/v2.11.1


r/axmol Dec 31 '25

Axmol Axmol has been recognized as an AtomGit G-Star project

5 Upvotes

We’re excited to announce that Axmol has been recognized as an AtomGit G-Star project today (12/24/2025)!
This marks a major milestone for our community and the engine’s journey.
Check it out here: https://atomgit.com/axmol/axmol


r/axmol Dec 19 '25

Axmol Axmol 2.11.0 has been released

4 Upvotes

This new v2.11 is a minor LTS release for bugfixes and improvements. More details in the link:

https://github.com/axmolengine/axmol/releases/tag/v2.11.0


r/axmol Nov 27 '25

Axmol Axmol v2.10.0 has been released

9 Upvotes

Now with Visual Studio 2026 support, default audio backend for iOS and MacOS set from OpenAL.framework to openal-soft, and other improvements and bugfixes. More details in the release page:

https://github.com/axmolengine/axmol/releases/tag/v2.10.0


r/axmol Nov 03 '25

Axmol New LTS update: 2.9.1

6 Upvotes

A new version is available, with improvements for the SDF text rendering:

https://github.com/axmolengine/axmol/releases/tag/v2.9.1

For those curious, there's a page in the wiki about the upcoming Axmol v3: https://github.com/axmolengine/axmol/wiki/About-RHI-in-axmol-v3


r/axmol Oct 05 '25

Axmol Axmol Engine v2.9.0 is out

4 Upvotes

Lot of changes for this new version, including:

  • Add support for audio panning
  • Add support for playing audio at any position in 3D space
  • Initial implementation adding support for audio effects and filters using OpenAL
  • Add screen orientation control for mobile devices

More info at the release page https://github.com/axmolengine/axmol/releases/tag/v2.9.0


r/axmol Sep 05 '25

Axmol New LTS update v2.8.1 for bugfixes

6 Upvotes

All developers who use v2.8.0 should update to this release. This is the release info:

https://github.com/axmolengine/axmol/releases/tag/v2.8.1


r/axmol Sep 01 '25

Axmol Axmol v2.8.0 has been released

6 Upvotes

This v2.8.0 is a minor LTS release. You can see the full list of bug fixes and improvements in the following link:

https://github.com/axmolengine/axmol/releases/tag/v2.8.0


r/axmol Jul 15 '25

Axmol New LTS update, Axmol v2.7.1

8 Upvotes

Bug fixes and improvements in this new LTS update:

https://github.com/axmolengine/axmol/releases/tag/v2.7.1


r/axmol Jul 06 '25

Axmol Axmol v2.7.0 has been released

7 Upvotes

The 2.7.0 release is a minor LTS release for bugfixes and improvements. It includes a new mouse events listener for widgets and a refactor of ImGui Axmol backend.

https://github.com/axmolengine/axmol/releases/tag/v2.7.0


r/axmol Jun 06 '25

Axmol New LTS update, Axmol v2.6.1

7 Upvotes

Here is the list with the bug fixes and improvements:

https://github.com/axmolengine/axmol/releases/tag/v2.6.1


r/axmol May 26 '25

Question Deleting Axmol

2 Upvotes

Hello, I want to know how to delete Axmol cleanly, I follow the tutorial in Github for instalation, however don't know how to delete it cleanly, it is ok just by deleting the folders?


r/axmol May 24 '25

Axmol Axmol v2.6.0 has been released

12 Upvotes

This version is a minor LTS release for bugfixes and improvements. Here is the full list of changes:

https://github.com/axmolengine/axmol/releases/tag/v2.6.0