Skip to content

Conversation

@dtwotwo
Copy link

@dtwotwo dtwotwo commented Feb 8, 2026

Add Opus decoding support for HashLink target.
Requires: approved HashLink pull request - HashLink#875

Add Opus decoding support for HashLink target.

- Add OpusData.hx decoder using @:hlNative("fmt", ...) bindings
  for opus_open, opus_info, opus_read, opus_seek
- Update Sound.hx to detect Ogg Opus via "OpusHead" magic bytes
  after Ogg page header, distinguishing from Ogg Vorbis
- Register .opus extension in Config.hx with wav as paired extension,
  auto-ignored on non-HL platforms
@dtwotwo dtwotwo marked this pull request as draft February 8, 2026 19:49
@dtwotwo
Copy link
Author

dtwotwo commented Feb 10, 2026

Use this library for heaps to get Opus support: https://github.com/gimmesoda/hlopus.
It is based on my pull request code and works independently, without modifying HashLink or Heaps.
It would be better to use it as a separate library instead of this one.

@dtwotwo dtwotwo closed this Feb 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant