diff options
author | Joerg Mueller <nexyon@gmail.com> | 2011-08-07 15:54:58 +0400 |
---|---|---|
committer | Joerg Mueller <nexyon@gmail.com> | 2011-08-07 15:54:58 +0400 |
commit | 2d884fc035d403d43c7a18e3e61cd56ccdfbec2b (patch) | |
tree | 2548dcfbb52370618d1f255f57e65bcf1cbb49a4 /source/gameengine/BlenderRoutines | |
parent | 4370099fb0bc1bdd21f78b14a91a1d8eb76e1bc1 (diff) |
3D Audio GSoC:
* Pepper depends on ffmpeg 0.7.1 or higher now, windows and mac build systems set to ffmpeg-0.8
* Fixed orientation retrieval in OpenAL device code.
* Added stopAll() method to AUD_IDevice (also for Python) and call it on BGE exit
* Changed BGE to use audaspace via native C++ instead over the C API.
* Made AUD_SequencerFactory and AUD_SequencerEntry thread safe.
* Changed sound caching into a flag which fixes problems on file loading, especially with undo.
* Removed unused parameter from sound_mute_scene_sound
* Fixed bug: changing FPS didn't update the sequencer sound positions.
* Fixed bug: Properties of sequencer strips weren't set correctly.
* Minor warning fixes.
Diffstat (limited to 'source/gameengine/BlenderRoutines')
-rw-r--r-- | source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp | 24 |
1 files changed, 16 insertions, 8 deletions
diff --git a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp index a3ea85b605c..3c766affe56 100644 --- a/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp +++ b/source/gameengine/BlenderRoutines/BL_KetsjiEmbedStart.cpp @@ -95,10 +95,6 @@ extern float BKE_screen_view3d_zoom_to_fac(float camzoom); #include "BKE_ipo.h" /***/ -#ifdef WITH_AUDASPACE -# include "AUD_C-API.h" -#endif - //XXX #include "BSE_headerbuttons.h" #include "BKE_context.h" #include "../../blender/windowmanager/WM_types.h" @@ -108,6 +104,11 @@ extern float BKE_screen_view3d_zoom_to_fac(float camzoom); } #endif +#ifdef WITH_AUDASPACE +# include "AUD_C-API.h" +# include "AUD_I3DDevice.h" +# include "AUD_IDevice.h" +#endif static BlendFileData *load_game_data(char *filename) { @@ -394,9 +395,13 @@ extern "C" void StartKetsjiShell(struct bContext *C, struct ARegion *ar, rcti *c ketsjiengine->InitDome(scene->gm.dome.res, scene->gm.dome.mode, scene->gm.dome.angle, scene->gm.dome.resbuf, scene->gm.dome.tilt, scene->gm.dome.warptext); // initialize 3D Audio Settings - AUD_setSpeedOfSound(scene->audio.speed_of_sound); - AUD_setDopplerFactor(scene->audio.doppler_factor); - AUD_setDistanceModel(AUD_DistanceModel(scene->audio.distance_model)); + AUD_I3DDevice* dev = AUD_get3DDevice(); + if(dev) + { + dev->setSpeedOfSound(scene->audio.speed_of_sound); + dev->setDopplerFactor(scene->audio.doppler_factor); + dev->setDistanceModel(AUD_DistanceModel(scene->audio.distance_model)); + } // from see blender.c: // FIXME: this version patching should really be part of the file-reading code, @@ -581,7 +586,10 @@ extern "C" void StartKetsjiShell(struct bContext *C, struct ARegion *ar, rcti *c { delete canvas; canvas = NULL; - } + } + + // stop all remaining playing sounds + AUD_getDevice()->stopAll(); } while (exitrequested == KX_EXIT_REQUEST_RESTART_GAME || exitrequested == KX_EXIT_REQUEST_START_OTHER_GAME); |