Add FLAC support without changing raylib source code #95
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
These changes should build
raylib
with-DSUPPORT_FILEFORMAT_FLAC=1
.This enables FLAC support as mentioned in #78.
I tested both
TARGET_LINUX
andTARGET_WIN64_MINGW
and a sample FLAC file just works on both.Notes:
Maybe the flag could be passed only to the
raudio.c
module build step. But I don't know if that definition changes anything else and may be needed for all modules anyway.Maybe this could be done in a different way. I didn't want to assume too much and insert unrequested complexity, so a little more thought could shape this support introduction better than this bare minimum idea.
I don't think an additional configure option for the repo's build is needed (in order to have this be flexible/optional).
I guess it mostly comes down to the downsides of turning this support on.
5174kB
to5548kB
, so ~7% (onTARGET_LINUX
)5723kB
to6085kB
, so ~6% (onTARGET_WIN64_MINGW
)