Ticket #1223 (closed enhancement: fixed)

Opened 14 months ago

Last modified 9 months ago

[PATCH] Redesign Sound System

Reported by: k776 Owned by: stwf
Priority: Must Have Milestone: Alpha 11
Component: Core engine Keywords: patch
Cc:

Description (last modified by k776) (diff)

Redesign the sound engine. Current one is broken and full of hacks.

  • During redesign, aim to solve the current issues, namely:
    • Current engine doesn't support Mac (#685, #931)
    • Music stops playing when returning to main menu (#946)
    • Suppress sound when minimized (#1218)
  • Further improve sound system (#961)
    • Sequential/random sounds
    • Fading sounds
    • Looping sounds

Attachments

new_sound_manager_1.diff (75.5 KB) - added by stwf 13 months ago.
patch12.diff (85.7 KB) - added by stwf 12 months ago.
good_sounds.patch (194.5 KB) - added by stwf 11 months ago.
most recent code version
RealPatch1.diff (200.0 KB) - added by historic_bruno 10 months ago.
RealPatch2.diff (200.5 KB) - added by stwf 10 months ago.
Latest sound manager fixes

Change History

comment:1 Changed 14 months ago by k776

  • Description modified (diff)

comment:2 Changed 14 months ago by k776

  • Description modified (diff)

comment:3 Changed 14 months ago by k776

  • Description modified (diff)
Last edited 14 months ago by k776 (previous) (diff)

comment:4 Changed 13 months ago by historic_bruno

Old ticket: #138 Related: #685

comment:5 Changed 13 months ago by stwf

  • Owner set to stwf
  • Status changed from new to assigned

Changed 13 months ago by stwf

comment:6 Changed 13 months ago by stwf

OK, this version builds on mac and linux

Fully supports the SoundGroup?.xml as well as allowing for control of the Sound item from Javascript.

The missing feature is for position. It seems like the implementation of this merits some discussions on the forums.

Bugs carried over from the previous code include the playing of sounds that aren't on the screen and special intensity levels which also probably needs some discussion.

comment:7 Changed 13 months ago by stwf

  • Status changed from assigned to closed
  • Resolution set to fixed

comment:8 Changed 13 months ago by stwf

  • Keywords patch review added
  • Status changed from closed to reopened
  • Resolution fixed deleted

comment:9 Changed 13 months ago by stwf

  • Keywords music, added; music removed
  • Status changed from reopened to closed
  • Resolution set to fixed
  • Summary changed from New Sound System to New Sound System [PATCH]

comment:10 Changed 13 months ago by stwf

  • Status changed from closed to reopened
  • Resolution fixed deleted

comment:11 Changed 13 months ago by k776

  • Keywords sound added; sound, music, removed
  • Summary changed from New Sound System [PATCH] to [PATCH] New Sound System

comment:12 Changed 12 months ago by k776

  • Description modified (diff)
  • Summary changed from [PATCH] New Sound System to [PATCH] Redesign Sound System

Changed 12 months ago by stwf

comment:13 Changed 12 months ago by stwf

This patch contains the first pass of functionality for the new sound manager. Aff fields of the SOundGroup xml should be supported nd directionality for on screen sounds incudeed.

[PATCH REQUEST]

Version 0, edited 12 months ago by stwf (next)

comment:14 follow-up: ↓ 15 Changed 11 months ago by stwf

OK, new path. This fixes the issues with acknowledgements and some situations where the screen coordinates were not being correctly calculated. Also confirmed that sond gains are being applied correctly.

Changed 11 months ago by stwf

most recent code version

comment:15 in reply to: ↑ 14 Changed 11 months ago by historic_bruno

Replying to stwf:

OK, new path. This fixes the issues with acknowledgements and some situations where the screen coordinates were not being correctly calculated. Also confirmed that sond gains are being applied correctly.

After applying the patch and resolving a few conflicts, I ran into these build errors:

10>..\..\..\source\soundmanager\CSoundManager.cpp(24): fatal error C1083: Cannot open include file: 'soundmanager/js/JSoundPlayer.h': No such file or directory

18>..\..\..\source\main.cpp(42): fatal error C1083: Cannot open include file: 'lib/res/sound/snd_mgr.h': No such file or directory

Changed 10 months ago by historic_bruno

Changed 10 months ago by stwf

Latest sound manager fixes

comment:16 Changed 10 months ago by stwf

THis version fixes some compiler warnings and guards against a segfault due to a missing resource, and now logs it. Loud music startup also addressed.

comment:17 Changed 9 months ago by ben

In 12428:

New sound system implementation by stwf, refs #1223, #961.
Enables audio on OS X, refs #685, #931.
Fixes music not playing after a game, refs #946.

comment:18 Changed 9 months ago by k776

  • Keywords review sound removed
  • Status changed from reopened to closed
  • Resolution set to fixed

comment:19 Changed 9 months ago by ben

In 12444:

Fixes unnecessary use of VfsPath? pointers in sound system. Refs #1223

comment:20 Changed 9 months ago by ben

In 12459:

Updates bundled win32 OpenAL Soft to v1.14, seems to fix Windows crashes with new sound system. Refs #864, #1223

Note: See TracTickets for help on using tickets.