The GDK runs on major operating systems. Thanks to SDL3, it supports a wide variety of hardware accelerated rendering and low-latency audio drivers.
The installer places headers and libraries in standard system locations (e.g. /usr/local/include and /usr/local/lib).
Headers and libraries are installed into standard locations (e.g. /usr/local or /Library).
Ready to write code? Jump straight into development with the practical examples.
This is the classic "render-as-fast-as-possible" loop. Logic and Graphics updates occur sequentially in the same iteration. The "Main loop" will run at the maximum speed provided by the CPU.
In this mode, the Logic runs at a guaranteed deterministic rate (e.g., 20 Hz), while Rendering runs at the monitor's refresh rate (e.g., 144 Hz or VSync).
This is the gold standard for action games. Logic runs at a fixed, low frequency (e.g., 20 or 30 Hz) for stability, but the Engine renders at maximum framerate by interpolating positions between the previous and current logic states.
The internal Master XML defines the structure. You can not modify the element names, but you can override their attributes in your custom XML.
View Master Setup XML
<?xml version="1.0" encoding="UTF-8"?>
<c64_setup title="Setup" cursor="default" icon_img="default" font="default">
<main name="default" x="0" y="0">
<logo state="1" name="default" x="59" y="10"/>
<wgTabsGeneral name="default" x="28" y="98" text="General"/>
<wgTabsVideo state="1" name="default" x="94" y="98" text="Video"/>
<wgTabsAudio state="1" name="default" x="160" y="98" text="Audio"/>
<wgSave state="1" name="default" x="44" y="401" text="Save"/>
<wgOK state="1" name="default" x="178" y="401" text="OK"/>
<wgExit state="1" name="default" x="313" y="401" text="Exit"/>
<wgInfoCopyright state="1" x="70" y="439" text="Setup Tool - CRM64Pro GDK - MegaStorm Systems (c)"/>
</main>
<general name="default" x="28" y="115">
<wgInfoCPU state="1" x="43" y="37" text="Processor: "/>
<wgInfoMemory state="1" x="43" y="62" text="Memory: "/>
<wgInfoVideoCard state="1" x="43" y="87" text="Video card: "/>
<wgInfoAudioCard state="1" x="43" y="112" text="Audio card: "/>
<wgMTfriendly state="1" name="default" x="43" y="132" value="1" text=" Multitasking friendly"/>
<wgReadme state="1" name="default" x="73" y="209" text="Readme" action="readme.txt"/>
<wgWeb state="1" name="default" x="223" y="209" text="Website" action="http://www.megastormsystems.com"/>
</general>
<video name="default" x="28" y="115">
<wgScreenTitle text="CRM64Pro GDK Application"/>
<wgRendererSoftware state="1" name="default" x="70" y="15" value="1" text=" Software"/>
<wgRendererOpenGL state="1" name="default" x="142" y="15" value="0" text=" OpenGL"/>
<wgRendererVulkan state="1" name="default" x="214" y="15" value="0" text=" Vulkan"/>
<wgRendererGPU state="1" name="default" x="286" y="15" value="0" text=" GPU"/>
<wgRendererDirect3D9 state="1" name="default" x="70" y="35" value="0" text=" Direct3D9"/>
<wgRendererX11 state="1" name="default" x="70" y="35" value="0" text=" X11"/>
<wgRendererMetal state="1" name="default" x="70" y="35" value="0" text=" Metal"/>
<wgRendererDirect3D11 state="1" name="default" x="142" y="35" value="0" text=" Direct3D11"/>
<wgRendererDirect3D12 state="1" name="default" x="214" y="35" value="0" text=" Direct3D12"/>
<wgResolution1 state="1" name="default" x="30" y="100" value="1" width="800" height="600" text=" 800x600"/>
<wgResolution2 state="1" name="default" x="30" y="120" value="0" width="1280" height="720" text=" 1280x720"/>
<wgResolution3 state="1" name="default" x="30" y="140" value="0" width="1920" height="1080" text=" 1920x1080"/>
<wgResolution4 state="1" name="default" x="30" y="160" value="0" width="2560" height="1440" text=" 2560x1440"/>
<wgResolution5 state="1" name="default" x="30" y="180" value="0" width="3840" height="2160" text=" 3840x2160"/>
<wgResolution6 state="5" name="default" x="30" y="200" value="0" width="c1" height="c1" text=" CustomRes"/>
<wgModeWindow state="1" name="default" x="130" y="100" value="1" text=" Window"/>
<wgModeFullscreen state="1" name="default" x="130" y="120" value="0" text=" Fullscreen"/>
<wgModeFullscreenExclusive state="1" name="default" x="130" y="140" value="0" text=" Fullscreen exclusive"/>
<wgSpecialVSync state="1" name="default" x="255" y="100" value="0" text=" Vertical-Sync"/>
<wgSpecialBatching state="1" name="default" x="255" y="120" value="0" text=" Render-Batching"/>
</video>
<audio name="default" x="28" y="115">
<wgAudio state="1" name="default" x="100" y="11" value="1" text=" Enable audio"/>
<wgSample8bits state="1" name="default" x="30" y="70" value="0" text=" 8bits"/>
<wgSample16bits state="1" name="default" x="30" y="90" value="1" text=" 16bits"/>
<wgSample32bits state="1" name="default" x="30" y="110" value="0" text=" 32bits"/>
<wgFrequency22Hz state="1" name="default" x="125" y="70" value="0" text=" 22050Hz"/>
<wgFrequency44Hz state="1" name="default" x="125" y="90" value="1" text=" 44100Hz"/>
<wgFrequency48Hz state="1" name="default" x="125" y="110" value="0" text=" 48000Hz"/>
<wgModeStereo state="1" name="default" x="242" y="70" value="1" text=" Stereo"/>
<wgModeSurround state="1" name="default" x="242" y="90" value="0" text=" Surround 4ch"/>
<wgModeSurroundPlus state="1" name="default" x="242" y="110" value="0" text=" Surround 6ch"/>
<wgVolumeMaster state="1" name="default" x="100" y="140" value="1.0" text="Master volume:"/>
<wgVolumeMusic state="1" name="default" x="100" y="170" value="1.0" text="Music volume:"/>
<wgVolumeSFX state="1" name="default" x="100" y="200" value="1.0" text="SFX volume:"/>
<wgVolumeVoice state="1" name="default" x="100" y="230" value="1.0" text="Voice volume:"/>
<wgVolumeCustom state="5" name="default" x="100" y="260" value="1.0" text="Custom volume:"/>
</audio>
</c64_setup>
## 🚀 2026-03-25 – v0.16.0 – Network refactored and improved
### Added
- NetTCP:
- Added asynchronous outbound queueing for client and server traffic.
- Added configurable TX soft-brake / backpressure limits via `setTXSoftBrake()` / `getTXSoftBrake()`.
- Added richer `info()` diagnostics for RX/TX queues, buffered data, pending writes, throughput and errors.
- Added server pending-login handling to process new connections without blocking active clients.
- Added public `eNetResult` and `eNetTCPFeature` enums.
- Added challenge-response login with server nonce exchange.
- Added optional AES-CTR session payload encryption negotiated through `setFeatures()`.
- Added bounded string password support for NetTCP login/server creation.
- Added stricter per-message payload validation for login and control messages.
- Tool:
- New xxHash3() methods for XXH3 64-bit hashing.
### Changed
- NetTCP:
- Refactored socket ownership so actual I/O is performed only by the dedicated network thread.
- Converted outbound queues to ring buffers and updated the inbound receive queue to ring-buffer behavior.
- Improved server loop responsiveness under TX backlog by using shorter wait intervals when outbound data is pending.
- Improved `info()` output with cleaner RX/TX naming, feature reporting and clearer queue/buffer diagnostics.
- Upgraded packet integrity from folded 32-bit hashes to full 64-bit xxHash3 while keeping the DataNet wire header size unchanged.
- Tool:
- randSeedPCG() and randPCG() now support optional caller-managed state.
- Updated validation tests (BasicSystem, Config, ConfigSetup) with platform-aware native hardware renderers.
- Updated dependencies:
- SDL3_net 3.0.0 (Jan 2026)
### Fixed
- NetTCP:
- Fixed server login flow so slow connectors no longer stall active clients.
- Fixed login/session edge cases including leaked login payloads, failed `LOGIN_ACCEPTED` rollback, and mismatched negotiated feature reporting.
- Fixed multiple thread-safety issues by moving shared lifecycle/state flags to atomic usage where required.
- Fixed several queue, shutdown and diagnostic inconsistencies in client/server runtime paths.
- Fixed stale documentation/comments and protocol validation issues across the refactored network layer.
- Alpha transparency loss in software renderer during clipped scaling (SDL3 issue #15147).
### Breaking Changes
- NetTCP:
- Public NetTCP receive messages were renamed from `NETMSG_*` to `NM_*`.
- Public NetTCP result/error codes now use the new `eNetResult` enum with `NR_*` values.
- Replaced `features()` with:
- `setFeatures()`
- `getFeatures()`
- `sendData()`, `queryKillServer()`, `queryKillClient()`, `queryClientsInfo()` and related NetTCP methods now return `eNetResult`.
- `createServer()` and `connectTo()` now use `const string& sPassword` instead of the old integer password.
- Packet integrity now uses a 64-bit hash field internally while preserving the existing 24-byte DataNet serialized header.
- IP fields were upgraded from IPv4-only Uint32 values to `NetTCP::NetIPAddress`, `ClientInfo::iIP` became `ClientInfo::ipAddress` and `NetTCP::getIP()` now returns `NetIPAddress`.
## 🚀 2026-02-28 – v0.15.0 – Scene with Object support
`TileEngine` has been completely renamed to `Scene` across the entire codebase to better reflect its role as a robust advanced 2D game world management system.
### Added
- Scene:
- Object Layer support:
- Introduced native TMX object layers with support for rectangles, points, polygons and polylines.
- Added runtime access to object data (position, size, properties, type, name).
- Object factory system for creating custom game objects from TMX data.
- Added TMX template (.tx) load/save support.
- Object rotation: shape, tile rotation + rotated AABB supported.
- High-precision timing integration:
- Scene logic now fully supports the new Main fixed-timestep system.
- Deterministic update behavior regardless of frame rate.
- Sub-pixel camera movement:
- Floating-point world coordinates for camera and layer scrolling.
- Smooth pixel-perfect rendering without jitter during slow movement.
- Support for user-defined layers via class inheritance, the new `addLayer()` injection method, and custom type IDs (`TELT_USER_START`).
- Added camera methods, multiple modes, and configurable parameters for per-layer behavior (follow, bounds/clamp, smoothing, and axis controls).
- Implemented a suite of tutorials covering various game genres (RTS, RPG, Scrolling) to fully validate the TileEngine system.
- Added native TE_Object trigger zones with cross-layer + type-hash filtering + delayed one-shot STAY/EXIT cooldown flow.
- Physics:
- Implemented new Physics interface with frame-accurate pixel-perfect collision detection.
- Sprite:
- Added support for new animation types: `ST_ONESHOT_REVERSE` and `ST_RANDOM`.
- CMem:
- Added `MSL_DEBUG` level for detailed leak detection with unique Allocation IDs, memory dump previews, and
debugger breakpoint support via `setBreakOnAlloc()`.
- Tool:
- New PCG32 PRNG methods: `randSeedPCG()`, `randPCG()` and `randRealPCG()`.
- Image:
- Added getWidth() and getHeight() methods to Image objects for easy access to dimensions.
- Added loadFromSurface() method to create an Image directly from an existing SDL_Surface.
- Expanded custom STL memory allocator support to include queue, stack, priority_queue, multimap, list, and shared_ptr/stringbuf aliases.
- Implemented engine-wide memory allocation protection for critical PIMPL/Manager failures and graceful returns for resource allocations.
### Changed
- Scene:
- Internal architecture refactor:
- Major refactor of Scene core to separate logic, rendering and timing concerns.
- Simplified layer update/render flow aligned with Main canonical game loop.
- Logic / render synchronization:
- Scene `update()` now runs strictly on the fixed timestep.
- Interpolation moved to render phase using engine-provided delta helpers.
- Scrolling and parallax math:
- All scrolling, parallax and auto-scroll calculations now use floating-point precision.
- Code cleanup & optimization:
- Reduced redundant state, improved cache locality and simplified internal containers.
- Timer:
- `benchInfoEx()` method in throughput mode now perform unit conversion to thousands and millions for better readability.
- Refactored microbenchmark system to centralize statistical logic and implement consistent, unit-aware formatting (K/M scales) across console logs and HTML reports.
- Main:
- Canonical game loop: Refactored `update()` to use a high-precision accumulator system with nanosecond resolution, ensuring zero-drift timing and
deterministic simulation steps.
- Introduced `getDeltaTime()` and `getLogicTime()` to provide unified, high-precision timing across all engine modules.
- Spiral of death prevention: Implemented safety clamping on delta time to ensure engine stability during significant lag spikes or window interruptions.
- Implemented engine-wide restricted prefix policy (# and @): enforced on create/setName and loadFromFile, while allowed on loadFromBuffer and CDC load.
### Fixed
- Implemented over 70 stability fixes including memory safety, robust I/O validation, and null-pointer guards across all core modules.
- Scene:
- TMX loading issues:
- Fixed incorrect handling of transparent / colorkey tilesets.
- Layer update/render edge cases:
- Fixed inconsistencies when enabling/disabling layers at runtime.
- Sprite:
- Fixed visual glitches caused by desynchronized timing.
- Interpolation now relies on Main timing helpers.
- Fixed an issue with `Sprite::status()` when using one-shot animations.
- Image:
- Fixed a memory leak in `ImageMgr::load()` (CDC path).
### Breaking Changes
- Macros to enum migration:
- Scene:
- Replaced `TE_LAYERFLAG_*` macros with `eSceneLayerFeature` and `SLF__*`.
- Replaced `TE_TILESETTYPE_*` macros with `eSceneTileSetType` and `STST_*`.
- Log: Replaced `LM_*` macros with `eLogMode`. Added bitwise operator support via a reusable template.
- Memory Manager: Replaced `CMEM_MOD_*` macros with `eMemoryModule` and `CMM_*`.
- Updated `alloc()`, `calloc()`, `realloc()`, and `alloc_aligned()` methods.
- Tool: Replaced `TMBB_*` macros with `eMsgBoxButton`.
- C64 System Status: Replaced `C64_STATUS_*` macros with `eGeneralStatus` and `GS_*`.
- Sprite Types: Replaced `SPR_TYPE_*` macros with `eSpriteType` `ST_*`.
- Custom events: Replaced the legacy `#define C64_EVENT` macro with `eEventType` with values `ET_C64` replacing old `C64_EVENT`.
- Audio:
- `eAudioFreq` renamed to `eConfigAudioFreq`. Internal values renamed from `AF_*` to `CAF_*`.
- `eAudioSample` renamed to `eConfigAudioSample`. Internal values renamed from `AS_*` to `CAS_*`.
- `eAudioMode` renamed to `eConfigAudioMode`. Internal values renamed from `AM_*` to `CAM_*`.
- XML:
- Removed parameter-based `getAttribute()` and `setAttribute()` overloads.
- Replaced with explicit typed methods: `getAttribute[String|Int|Uint|Float|Bool]` and `setAttribute[String|Int|Uint|Float|Bool]`.
- API method updates:
- `Tool::messageBox()`: Now returns `eMsgBoxButton` instead of `Sint32`.
Internal failures now log a warning and return TMBB_NONE instead of negative error codes.
- `status()` methods: Updated return type from `Sint32` to `eGeneralStatus` across all classes (Log, Screen, Sprite, Widget, CursorMgr).
- Refactored `renderEx()` methods:
- Standardized the extended rendering API across all high-level graphics objects (Sprite, Tile, Font)
to support asymmetric scaling (X/Y) and improve parameter consistency.
- `Sprite::renderEx()`changed from (float fScale, ...) to (float fScaleX, float fScaleY, ...).
- `Font::renderEx()` changed from (..., float fScale, ...) to (..., float fScaleX, float fScaleY, ...).
- `Tile::renderEx()` changed from (Sint32 iTile, double dAngle, ...) to (Sint32 iTile, float fScaleX, float fScaleY, double dAngle, ...).
....