libretroadmin 0d83575d92 engine: restore the 60Hz gate in Outrun_vint for 120 FPS mode
Commit fc21962 (libretro: modernize CannonBall core) rewrote
Outrun_vint() and dropped the 'config.fps < 120 || (frame & 1)' guard
introduced by 5d042e4 when 120 FPS mode was added. With the guard gone,
the v-blank block runs at 120Hz instead of the hardware rate of 60Hz.

Two accumulating routines are affected:

- OInitEngine_set_granular_position() advances oroad.pos_fine at double
  rate, while the level-object spawner OSprites_sprite_control() stays
  gated at 30Hz behind tick_frame and emits at most two sprites per
  call. The pump falls behind the road position, and when the next
  scenery point arrives it resets seg_pos/seg_total_sprites, silently
  discarding the tail of the previous segment. When the checkpoint sign
  (function_holder 6) lands in that tail it is never spawned, so
  checkpoint_marker is never set and OStats_init_next_level() never adds
  time -- matching the intermittent 'checkpoints not adding time'
  reports at 120 FPS.

- OStats_do_timers() counts lap/stage elapsed time at double rate.
  (The countdown itself was unaffected, as Outrun_decrement_timers()
  runs off tick_frame.)

Restore the guard. Tick frames at 120 FPS are frame & 3 == 1, so every
tick frame is odd and satisfies the guard, preserving the phasing of
the original 120 FPS implementation.

Fixes https://github.com/libretro/cannonball/issues/49
2026-08-04 10:23:55 +02:00
2026-07-21 09:17:05 +02:00
2026-07-19 23:31:12 +02:00
2018-05-23 02:20:21 +02:00
2026-07-20 22:55:18 +02:00
2026-07-19 23:31:12 +02:00
2026-07-19 23:31:12 +02:00
2026-04-02 16:42:57 +01:00
2018-05-23 01:32:23 +02:00
2026-07-19 23:31:12 +02:00

CannonBall Libretro

CannonBall is an enhanced game engine for Sega's 1986 OutRun arcade game. The original 68000 and Z80 code was rewritten in C++ by Chris White, enabling enhancements such as smoother frame rates, widescreen rendering and additional game modes.

This repository contains the Libretro core and synchronizes it with the modern CannonBall engine while retaining the Libretro integration.

Requirements

CannonBall requires legally obtained ROM files from the OutRun Revision B arcade set. No copyrighted game data is included in this repository.

For instructions on downloading the CannonBall support files, arranging the ROM files and starting the core, see:

https://docs.libretro.com/library/cannonball/

The core supports the .game and .88 content entry points.

Features

  • original, 30, 60 and 120 FPS rendering modes
  • widescreen and high-resolution rendering
  • Continuous and Time Trial game modes
  • analog steering, accelerator and brake controls
  • force feedback on supported frontend and input-driver combinations
  • custom track support
  • optional custom music support
  • additional car palette options
  • Libretro core reset support
  • persistent configuration and high scores
  • Libretro core options and input remapping

Feature availability may depend on the Libretro frontend, operating system and selected input driver.

Building the Libretro core

The Libretro build uses Makefile and Makefile.common.

Run:

make platform=<target> -j<number-of-jobs>

For example, on macOS:

make platform=osx -j"$(sysctl -n hw.ncpu)"

The resulting core uses the platform-appropriate shared-library extension, such as:

  • cannonball_libretro.so on Linux and other Unix-like systems
  • cannonball_libretro.dylib on macOS
  • cannonball_libretro.dll on Windows

Available targets and platform-specific settings are defined in the Makefile.

Dependencies

The Libretro core includes the required Libretro common sources and pugixml in the repository.

Configuration and high-score XML handling use pugixml. The previous vendored Boost dependency is no longer required.

The Libretro build does not require SDL2. SDL2 and CMake are used by the standalone CannonBall application instead.

Standalone CannonBall

Documentation and source code for the standalone application are available from the original project:

Credits

  • Chris White — CannonBall creator and original engine implementation
  • Arun Horne — cross-platform work
  • Libretro contributors — Libretro integration and maintenance
  • CannonBall contributors — continued engine development

License

CannonBall is distributed under a non-commercial license. See the repository license files for the complete terms.

The original OutRun ROM files and other copyrighted game data are not included.

S
Description
No description provided
Readme
5.1 MiB
0 Stars 1 Watchers 0 Forks
Languages
C 98.2%
Makefile 1.8%