Skip to content

Releases: ezavada/pdg

v1.2.0

Choose a tag to compare

@ezavada ezavada released this 09 Oct 14:48

PDG v1.2.0 release notes

PDG 1.2.0 adds independent scenes, animated cameras, reusable animation scripts,
live Bone controls, procedural FABRIK and jiggle, WebSocket and WebTransport
networking, and TypeScript declarations and MVC support. It also improves text
rendering and expands the browser bindings.

Version: 1.2.0. These notes describe the actual public repository diff from
v1.1.1, commit dc52a6d2370b3235c103f094482d0cd74c007a97, to merged
main, commit 92b25c6be7aba19ecf4fefb283a48e7665abaa4b.
Features already present in 1.1.1 are covered by the
1.1 and 1.1.1 release notes.

Scenes and cameras

  • Scene ownership and timing. A Scene owns layers, an isolated physics
    world, a default camera, logical timers, and subscriptions that disconnect on
    disposal. Pause simulation while continuing to draw, adjust time scale, select
    fixed steps with optional render interpolation, or advance a manual scene
    explicitly. Separate gameplay and HUD scenes can advance independently.
  • Scene collision queries. Raycasts, circle sweeps, nearest-point queries,
    and point/circle/box/capsule overlaps inspect attached Sprite, Part and Particle
    colliders, including bodyless colliders. Queries work before the first step
    and while paused. Filter by layers, query groups, categories, sensors,
    exclusions, or a predicate; choose closest-hit or bounded multiple-hit results.
  • Animated Camera. Ports have a built-in camera; layers can share an explicit
    camera with their own viewport and parallax. Follow targets with smoothing,
    look-ahead, deadzones and offsets; constrain visible world bounds, enable pixel
    snapping, and convert between world and view coordinates.
  • Camera effects and transitions. Animate zoom and opacity, flash the view,
    compose transient effects, and switch shots using cuts, subject-matched cuts
    and fades, crossfades, directional wipes, luminance fades, or whip pans.
    Composited transitions require compatible ports and viewports.
  • Camera-aware drawing and picking. Layer rendering and input use the
    effective camera. Ports also provide camera conversions and drawing controls
    for screen-space UI.

Animation and particles

  • Reusable animation scripts. Record named definitions with
    Animated.defineScript() and play independent instances with playScript().
    Batch and series groups, parallel placement, waits, conditional branches,
    until, repeats, yoyo, amplitude and speed envelopes, saved marks, and lifecycle
    events compose on the existing animation scheduler. Selected blocks have their
    own stop/restart/pause/resume controls.
  • Collective animation. Troupe applies commands to a collection of Animated
    targets using one script clock, including staggered starts. Members retain
    their normal rendering, physics and update ownership.
  • Live Bone controls. Sprite.getBone() exposes an animated handle to an
    authored bone. Override individual transform channels, add relative motion
    over fresh clip samples, adjust dimensions and attachment offsets, fade
    influence back to the clip, and apply local IK rotation limits. Handles become
    invalid when their owning rig is replaced.
  • Procedural FABRIK and jiggle. Solve longer IK chains with bounded iteration
    and diagnostics. Add chain springs or spring-filtered two-bone IK targets, with
    influence fades, kicks, enable/reset controls, and numerical state capture.
    Controllers support imported animation poses and independent Part chains;
    standalone pose solvers are available in C++. Jiggle itself does not create
    physics bodies or perform obstacle collision queries.
  • Particle trails. Particles and emitter templates can carry solid ribbon
    trails with configurable lifetime, width, color, opacity, sampling and point
    limits. Break a trail on teleportation; retired trails can finish fading after
    the particle disappears.
  • Snapshots. Supported snapshots now preserve animation script playback,
    saved marks and Troupe membership, Bone controls, built-in procedural
    controllers and state, and explicit layer camera/parallax settings. Callback
    evaluators, event handlers and custom easing remain runtime resources and are
    rejected by portable snapshots. Active camera transitions are not portable.

Networking

  • JavaScript WebSocket and WebTransport. The existing NetClient,
    NetServer and NetConnection interfaces gain web transports alongside native
    TCP/UDP. Desktop and Node can host web listeners; browsers use browser APIs;
    iOS exposes client networking through its native bridge.
  • Transport selection. Choose auto, native-only, websocket-only, or
    webtransport-required. Automatic web selection can fall back from unavailable,
    unsupported or timed-out WebTransport to WebSocket. Certificate,
    authentication and protocol failures do not trigger that fallback.
  • Messages and delivery. Send text, JSON, bytes, MemBlocks and supported
    serialized objects. Datagram sends use reliable delivery when the transport
    lacks datagrams or the payload exceeds its datagram limit. Configure TLS,
    certificate hashes, allowed origins, reservations, deadlines, connection
    limits and pending-byte limits.
  • Optional C++ networking. Enable PDG_BUILD_NATIVE_NETWORK to build the
    separate pdg-net API: an explicitly polled runtime, clients, servers,
    connections and owned messages interoperating with the JavaScript protocol.
    Desktop listeners and iOS clients are supported; this facade is not a WASM API.
  • Native WebTransport backend. The build integrates pinned QUIC/HTTP/3 and
    TLS dependencies, with desktop, Node and iOS build paths and accompanying
    third-party notices. Browser builds use browser WebTransport instead.

TypeScript and browser support

  • Generate engine declarations from the checked-in JavaScript IDL, including
    overloads, callback payloads, shared option records and fluent return types.
    Coverage metadata records the declaration inventory and construction rules.
  • Add a separate TypeScript MVC implementation, including views, controllers,
    observers, controls, dialogs, scrolling and touch support. It compiles to
    CommonJS modules for an initialized graphical PDG runtime; the headless Node
    addon cannot run the graphical MVC framework.
  • Add strict contract checks, examples, a relocatable build distribution and
    TypeDoc reference. make docs now packages the TypeScript site alongside the
    C++ and JavaScript references. See the TypeScript guide
    for setup and runtime constraints. Declarations are opt-in; this change does
    not publish a separate npm package or enable direct .ts execution.
  • Expand Emscripten bindings and adapters for the new APIs, typed byte arrays,
    fluent calls and exposed Chipmunk operations. Source-driven generation checks
    validate the binding inventory and manual adapters.

Rendering, fixes and builds

  • Editable Drawing text. Add UTF-8 text elements to Drawing artwork and edit
    them through ElementRef. Text participates in transforms, opacity, hit testing
    and supported artwork snapshots; fonts are referenced by name rather than
    embedded.
  • Text caching and batching. Replace linear text-cache lookup with hashed
    lookup, shared texture atlases and batched text drawing, with separate handling
    for changing labels. Browser text measurement and rasterization reuse Canvas2D
    resources. Improve native font fallback and release replaced font metrics.
  • Graphics lifetime and display scaling. Detach retained cached fonts when
    a graphics port is destroyed. Keep logical window/drawing/input coordinates
    separate from framebuffer pixels when resizing or moving between displays.
  • Correct the human animation demo's simulation clock and overlay drawing calls,
    and position the serialization demo with independent cameras.
  • Fix Linux JPEG dependency handling and ensure release builds produce all
    configured CTest executables before running CTest. Repair Windows release
    checksum generation and include WebSocket license notices in desktop packages.
  • Remove embedded-JavaScript empty-character warnings in the web build and align
    its scoped vendored Spriter warning suppression with native builds.
  • Expand unit, native C++, tooling and browser coverage for scenes, queries,
    cameras, animation scripts, Bone controls, procedural animation, binary data,
    network interoperability and TypeScript. Add camera, Bone, FABRIK and jiggle
    visual/demo checks. See the test guide for running them.

Compatibility and migration

This release contains breaking C++ and JavaScript API changes. Rebuild native
binaries and the Node addon, and review layer transforms, binary data and saved
snapshots before upgrading.

Previous usage 1.2.0 migration
SpriteLayer/TileLayer inherited Animated transforms, movement and animation helpers Layers no longer inherit Animated. Animate the Camera for view motion; animate Sprites/Parts for object motion. Use setWorldBounds() for layer bounds.
Layer setOrigin(), zoom, auto-center/fixed-axis controls, and moveWith() Configure a Camera, its viewport and attachment anchor; share it with setCamera() and select per-layer setCameraParallax(). Camera zoom() takes a multiplier.
Layer action_ZoomComplete Camera emits eventType_ZoomComplete, with CameraZoomInfo.
setGravity(gravity, keepItDownward) / setKeepGravityDownward() Use setGravity(gravity). Gravity belongs to simulation; rotating a camera does not rotate the physics world.
Binary JavaScript strings and MemBlock.toBuffer() Use Uint8Array (Node Buffer subclasses are accepted). MemBlock byte get...
Read more

v1.1.1

Choose a tag to compare

@edzavada-battlerd edzavada-battlerd released this 28 Sep 18:10
9aa7dd4

PDG v1.1.1 release notes

PDG 1.1.1 improves Linux GUI support, fixes Windows runtime and build issues,
repairs macOS native test launching, and simplifies the cross-platform test
workflow.

Version: 1.1.1. These notes compare against the public repository's
v1.1.0 tag, commit 1b0622ce6f1ba9aad7bd430ec309c430cba2358c.
They cover development changes through 439214475 and the 1.1.1 version updates.
The animation, physics, snapshots, benchmark optimizations and WebAssembly
Release packaging already shipped in v1.1.0 are described in the
previous release notes.

Runtime fixes

  • Spriter collision boxes: identify active boxes by their authored names and
    current entity objects. Bounds, counts, names, named/indexed lookups and point
    collision queries use the same active-box collection across runtime backends.
  • JavaScript fitting constants: export fit_FillKeepProportions as an alias
    of fit_Overflow in V8, matching the other interfaces.
  • Windows configuration: initialize resource-string buffers and retain the
    registry path after creating a configuration key.
  • Windows file paths: initialize the Node addon's application directory from
    its launch working directory, matching the other platforms.
  • Windows sound: initialize the DirectShow graph pointer and update the
    Sound object's load status instead of a shadowing local variable. The visual
    sound test also handles platform playback differences more reliably.
  • Windows compatibility: fix PNG size checks affected by Windows macros,
    correct an AnimatedAttributes transform override's return type, and read the
    uncapped-performance setting through the Windows environment API.
  • Initialize the counterpart Sprite before checking an existing serialized
    joint, and replace TileLayer destruction sentinels with null pointers.

Builds and packaging

  • Linux GUI: add the missing OpenGL platform implementation, improve graphics
    dependency setup, and fix GLFW Wayland compilation. Headless builds retain
    their separate configuration.
  • Node build caches: restore architecture-specific output links before using
    cached libraries and verify that the cached executable can initialize
    JavaScript. A matching version string alone no longer marks a broken runtime
    as usable. POSIX builds normalize CRLF embedded JavaScript inputs when needed.
  • WSL: reject builds from Windows-mounted checkouts with instructions to use
    WSL's Linux filesystem.
  • Windows tooling: improve Node output junctions, Python discovery, CMake
    process handling, static runtime consistency, and Debug/Release executable
    selection. Batch build entry points delegate to the PowerShell build driver.
  • macOS native launchers: point pdg and test/pdg at the actual executable
    inside the app bundle. This fixes test/unit reporting "No current PDG build"
    after a successful Debug build.
  • Respect requested build parallelism and avoid passing unusable GNU make
    jobserver settings into the npm/node-gyp subprocess. Install Node build tools
    in the architecture-specific workspace.
  • Reduce compiler and linker warnings across Linux, Windows and macOS. The
    addon symbol check recognizes zlib functions supplied by Node while retaining
    reports of unexpected symbols.
  • Build bcpp and the standalone performance-measurement test as C++20.
    bcpp's build copy uses bounded snprintf calls. Benchmark JSON includes are
    treated as third-party headers; their existing C++17 exception remains.
  • Synchronize release metadata across CMake, the native version header, the Node
    package template, Doxygen, macOS app bundles and iOS. The version-update helper
    also repairs stale version fields and works without a configured checkout.

Test workflow and upgrade notes

Use the shared unit runner in scripts and CI:

Previous entry point Current entry point
test/client test/unit
test/node test/unit --node
Browser test/client.html test/unit.html, normally launched by test/unit --web
test/ios --client test/ios --unit, or test/unit --ios

Windows uses the corresponding .ps1 wrappers. Runtime selection remains
explicit: plain test/unit runs the native PDG build; --node selects the
addon. Native unit runs also include configured CTest suites. Test lanes, release
scripts and debugger configurations use the consolidated entry points.

The Node dependency remains v24.21.0. C++ applications still require a C++20
compiler and standard library with std::format; iOS still requires 16.3 or
later
. Rebuild native binaries and the Node addon when upgrading. The v1.1.0
API migration guidance continues to apply; this patch does not repeat that API
reorganization or introduce a new snapshot format.

The benchmark helper's bundled JSON library remains isolated in a C++17 source
file. SCON/JSON animation loading, Spriter atlas loading and authored soundline
playback remain unsupported; the warning cleanup does not enable them.

Validation

Local macOS, Windows, and Linux checks included all 16 native CTest suites
and 1,437 JavaScript tests through native PDG, with zero failures. Both C++
benchmarks rebuilt without warnings., and the performance-measurement test passed.

v1.0.0

Choose a tag to compare

@edzavada-battlerd edzavada-battlerd released this 22 Aug 03:30
Update release.yml