Skip to content

fix: No-op on single player setAudioContext in desktop platforms#1888

Merged
Gustl22 merged 6 commits into
bluefireteam:mainfrom
livtanong:graceful-windows-set-audio-context
Feb 18, 2025
Merged

fix: No-op on single player setAudioContext in desktop platforms#1888
Gustl22 merged 6 commits into
bluefireteam:mainfrom
livtanong:graceful-windows-set-audio-context

Conversation

@livtanong

@livtanong livtanong commented Feb 17, 2025

Copy link
Copy Markdown
Contributor

Description

Calling setAudioContext on the windows platform throws a NotImplemented error. setAudioContext is handled as a no-op in the global method call, but not in a method call for a single audio player. This PR simply adds that no-op (and log message) for a single audio player.

More context is here flame-engine/flame#3498

Checklist

  • The title of my PR starts with a Conventional Commit prefix (fix:, feat:, refactor:,
    docs:, chore:, test:, ci: etc).
  • I have read the Contributor Guide and followed the process outlined for submitting PRs.
  • I have updated/added tests for ALL new/updated/fixed functionality.
  • I have updated/added relevant documentation and added dartdoc comments with ///, where necessary.
  • I have updated/added relevant examples in example.

Breaking Change

  • Yes, this is a breaking change.
  • No, this is not a breaking change.

Related Issues

Resolves flame-engine/flame#3498

@livtanong

Copy link
Copy Markdown
Contributor Author

Hi @Gustl22 , I'm not familiar with c++, so I'm just doing my best pattern matching as a human. 😅 Please advise me if this was the incorrect way to log the message.

@livtanong livtanong changed the title fix: No-op on single player setAudioContext in windows platform (draft) fix: No-op on single player setAudioContext in windows platform Feb 17, 2025
@livtanong livtanong changed the title (draft) fix: No-op on single player setAudioContext in windows platform fix: No-op on single player setAudioContext in windows platform (draft) Feb 17, 2025
@Gustl22

Gustl22 commented Feb 17, 2025

Copy link
Copy Markdown
Collaborator

Very cool, thank you. I try to add some tests and then we can be sure it works.

@Gustl22 Gustl22 changed the title fix: No-op on single player setAudioContext in windows platform (draft) fix: No-op on single player setAudioContext in desktop platforms Feb 18, 2025
@Gustl22 Gustl22 requested a review from spydon February 18, 2025 08:07
@Gustl22 Gustl22 merged commit 50d7a8b into bluefireteam:main Feb 18, 2025
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.

When using FlameAudio.bgm.initialize() on a windows project, MissingPluginException for setAudioContext is thrown

3 participants