Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Playing mono samples with libacm #2

Closed
winterheart opened this issue Apr 26, 2024 · 2 comments
Closed

Playing mono samples with libacm #2

winterheart opened this issue Apr 26, 2024 · 2 comments

Comments

@winterheart
Copy link

Hello!

We recently integrated libacm in our Descent 3 game project (https://github.com/DescentDevelopers/Descent3). It uses ACM audio files in both mono and stereo. After integration, we encountered a problem that samples with one channel were cut off during playback. We found that in this case acm_open_decoder() with force_chans = 0 forces two channels despite the correct ACM header.

Although we can do force_chans = 1/2, this requires separate processing of the ACM header, which is not optimal from the point of view of the logic of our code. Is it possible to remove this check in the code?

Proposed changes here.

@DanielGibson
Copy link
Contributor

I have a better idea on how this can be handled in a way that keeps the existing behavior of libacm, but also allows telling it to trust the header.

See #3

@markokr
Copy link
Owner

markokr commented Apr 27, 2024

Fixed by #3

@markokr markokr closed this as completed Apr 27, 2024
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

No branches or pull requests

3 participants