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.
Halfway through adding file callback support to
Audio::AbstractImporter
for consistency with scene and font importers I realized it just doesn't make sense to have audio import separate in the Audio library. Reasons:Audio
and theBufferFormat
enum depend on OpenAL, while the actual data import doesn't, at all, basically preventing users from using the importer plugins together with, let's say, fmod, SoLoud or other implementationsTrade::AbstractImporter
importerState()
-- and then, if the audio data are embedded in the file, no way of passing those toAudioImporter
sA possible follow-up question could be if
Text::AbstractFont
should get merged intoTrade
as well. In my opinion nope, since text rendering is a very specific thing and it's far from "having a buffer with data that you pass to the GPU or the audio card". Besides that, text objects are usually not embedded in scenes (unlike audio) and if such need arises, it can be always done via a format-specific extension.Things to do:
Magnum::AudioFormat
zero-based enumAudio::BufferFormat
Trade::AudioData
class, wrapping format, frequency and buffer dataaudioCount()
,audioName()
,audioForName()
,audio()
accessors toTrade::AbstractImporter
AnyAudioImporter
andWavAudioImporter
to be a part ofTrade
Audio::AbstractImporter
hooking intoTrade
? ugh