-
Notifications
You must be signed in to change notification settings - Fork 43
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
Player enhancements #223
Player enhancements #223
Conversation
Awesome |
Very cool, thoughts @sezero ? |
I don't know. One thing that comes to my mind is why make OpenAL the default?? Don't like that one for sure. (OpenAL output was added with the sole purpose of supporting macOS the easy way. It isn't available everywhere by default.) As for the rest, needs review and testing. |
Well, I locally did
The resulting config.h has this:
Obviously not acceptable as is. Haven't done any further testing, nor have I compared the moved code to the |
@sezero main idea is give to user choice what he like to enable. If user desired to enable OpenAL, ALSA and OSS, new functionality gives him that opportunity. If he decided to disable all - he'll get what he want to: only very basic functionality with one 'true' output which will work on all platforms - wave. Build system changed for that, so you can enable or disable any variation of outputs that theoretically support target platform. OpenAL chosen as default output with one reason - it runs practically everywhere. If you have OpenAL support on target, you'll don't have to think about platform-specific output and build environment. So this ease to port player/library into new platform. Like I sad, if you have POSIX system with available OpenAL on it, you'll be OK, nothing to do for porting wildmidi player. But still old behavior still available - disable OpenAL and enable one of native output, and you'll receive same functionality as from current master. Player autodetect next available output and will use it for playback. |
ping? |
@winterheart if you're still around, would be nice to rebase this. I think the main point of contention was the 'default'. We can still have that discussion if you want. Keep in mind that openal is deprecated on macos and will eventually be removed. So we'll defo need a replacement, though that is likely not for this PR. |
Player should supports all available outputs besides noout and waveout.
Extended wildmidi_info struct with core functions (open, write, close, pause, resume), which should be implemented for each supported driver. If there no need on certain function there may be used one from noout.
There also may need to fix other architectures.
Now all playbacks are equals.
Simplified project, reworked player build options. Now multiple playback outputs can be coexists same time.
By default preferred output is OpenAL (if available).
Implementing artifacts upload for each pipeline
Multiconfiguration generators (such as VS MSBuild) relies on CMAKE_CONFIGURATION_TYPES instead of CMAKE_BUILD_TYPE. To build one of supported build types you need to issue `cmake --build <directory> --config <build_type>`.
2528e4a
to
78d602a
Compare
- wave output and 'none' output are always available (as before) - player '-o xxx.wav' command line switch implies '-P wave' - as it should to keep old wildmidi behavior the same.
cmake >= 3.4 is now needed because of string(APPEND ...)
I think I'm mostly done with this. @psi29a, @winterheart: Take a look (and test if possible) one last time. I still want to add a native backend for netbsd, but that can be done after this gets in. |
Yeah, native backends needed for:
We can put that on our issue tracker |
rate isn't an extern global anymore.
That's already done: coreaudio is added in this P/R
Working on it, can possibly do it today
For e.g. ? |
Oh wow, reads notes |
That means we can make use of github actions to make macos builds as well... perhaps in another PR? We can have a rule to make release builds when tagged. |
Current github actions generates artifacts, thanks to @winterheart
For another PR. Merging this now. |
@psi29a, @winterheart: With alsa or oss configured, It used to work before (e.g. in 0.4.5) -- what am I doing wrong? (It's probably something obvious, but I can't see it for now..) |
Created this as a new ticket #250 so that it doesn't get lost. Please respond / discuss at there. |
Ah, was going to validate on my mac, but alright. If I come up with anything, will create an issue for it. Cheers everyone! |
Yes please |
Just added a native netbsd backend to master |
And also check the newly added sndio (on openbsd) and netbsd backends if you are able. |
Huge refactor for wildmidi player intended to enable more than one playback outputs.
Now player supports -P option which controls actual output (default value depends on platform capabilities, but OpenAL output is preferred when available). Each output can be enabled or disabled on configuration and compile time. Currently there 9 outputs:
Player now can be easily extended for additional outputs and ported to another platforms, since there modular "framework" has been implemented.
open_*_output
functions now accept path as output where to save file or send stream to sound device and can be defined by-o <out>
option. This parameter currently required by wave, alsa, oss outputs.Additional fixes to build system
Besides changes related to player, there also some fixes in CMake build system. Now CMake can properly generate project for multiconfiguration systems like VS MSBuild. If such system is detected, you can build any of supported build types with
cmake --build <dir> --config <build_type>
.Additionally Github Actions now stores build artifacts available on Actions page (like here https://github.com/winterheart/wildmidi/actions/runs/376312898).