Aeon Engine c550894
AeonGames Open Source Game Engine
Loading...
Searching...
No Matches
Plugin.cpp
1/*
2Copyright (C) 2017-2019,2025 Rodrigo Jose Hernandez Cordoba
3
4Licensed under the Apache License, Version 2.0 (the "License");
5you may not use this file except in compliance with the License.
6You may obtain a copy of the License at
7
8http://www.apache.org/licenses/LICENSE-2.0
9
10Unless required by applicable law or agreed to in writing, software
11distributed under the License is distributed on an "AS IS" BASIS,
12WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13See the License for the specific language governing permissions and
14limitations under the License.
15*/
18#include "aeongames/Plugin.hpp"
19#include "aeongames/Sound.hpp"
20#include "OggSound.h"
21#include <iostream>
22
23extern "C"
24{
25 bool OggStartUp()
26 {
28 }
29
30 void OggShutdown()
31 {
33 }
34
35 PLUGIN PluginModuleInterface PMI =
36 {
37 "Ogg sound loader",
38 "Implements Ogg Vorbis sound support.",
39 OggStartUp,
40 OggShutdown
41 };
42}
Platform-specific macros, includes, and DLL export/import definitions.
Defines the plugin module interface for dynamically loaded plugins.
DLL bool RegisterSoundDecoder(const std::string &aMagick, const std::function< bool(Sound &, size_t, const void *) > &aDecoder)
Register a sound decoder for the given magic identifier.
Definition Sound.cpp:25
bool DecodeOGG(Sound &aSound, size_t aBufferSize, const void *aBuffer)
Decodes OGG Vorbis audio data from a memory buffer into a Sound.
Definition OggSound.cpp:25
DLL bool UnregisterSoundDecoder(const std::string &aMagick)
Unregister a previously registered sound decoder.
Definition Sound.cpp:30
Interface that every loadable plugin module must expose.
Definition Plugin.hpp:35