Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorJoerg Mueller <nexyon@gmail.com>2011-08-28 18:21:44 +0400
committerJoerg Mueller <nexyon@gmail.com>2011-08-28 18:21:44 +0400
commitb4b046995b21d59e315eb71ed08fc1ae066c891b (patch)
tree99980da0b92c4178489604e664d6bf799858830d /source
parent8e12b7b054c3c4e95a23f26db232d99ff18e2b90 (diff)
* Removing mocap GSoC (is an addon already).
* Fixing ffmpeg-0.8 errors. * Fixing Ketsji paths. * Removing DoSound from BGE. * Fixing audio scene update to use only current scene objects.
Diffstat (limited to 'source')
-rw-r--r--source/blender/blenkernel/BKE_sound.h2
-rw-r--r--source/blender/blenkernel/intern/scene.c2
-rw-r--r--source/blender/blenkernel/intern/sequencer.c15
-rw-r--r--source/blender/blenkernel/intern/sound.c7
-rw-r--r--source/gameengine/Ketsji/CMakeLists.txt25
-rw-r--r--source/gameengine/Ketsji/KX_KetsjiEngine.cpp34
-rw-r--r--source/gameengine/Ketsji/KX_KetsjiEngine.h2
7 files changed, 13 insertions, 74 deletions
diff --git a/source/blender/blenkernel/BKE_sound.h b/source/blender/blenkernel/BKE_sound.h
index ecf0d7e459a..e1b6ff02bc4 100644
--- a/source/blender/blenkernel/BKE_sound.h
+++ b/source/blender/blenkernel/BKE_sound.h
@@ -136,7 +136,7 @@ void sound_read_waveform(struct bSound* sound);
int sound_get_channels(struct bSound* sound);
-void sound_update_scene(struct Main* bmain, struct Scene* scene);
+void sound_update_scene(struct Scene* scene);
void* sound_get_factory(void* sound);
diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c
index 12e81e8296e..d6003a44a7d 100644
--- a/source/blender/blenkernel/intern/scene.c
+++ b/source/blender/blenkernel/intern/scene.c
@@ -968,7 +968,7 @@ static void scene_update_tagged_recursive(Main *bmain, Scene *scene, Scene *scen
scene_update_drivers(bmain, scene);
/* update sound system animation */
- sound_update_scene(bmain, scene);
+ sound_update_scene(scene);
}
/* this is called in main loop, doing tagged updates before redraw */
diff --git a/source/blender/blenkernel/intern/sequencer.c b/source/blender/blenkernel/intern/sequencer.c
index 4cec086aad4..bfbaa223a99 100644
--- a/source/blender/blenkernel/intern/sequencer.c
+++ b/source/blender/blenkernel/intern/sequencer.c
@@ -3150,18 +3150,14 @@ void seq_update_sound_bounds_all(Scene *scene)
{
Editing *ed = scene->ed;
- if(ed)
- {
+ if(ed) {
Sequence *seq;
- for(seq = ed->seqbase.first; seq; seq = seq->next)
- {
- if(seq->type == SEQ_META)
- {
+ for(seq = ed->seqbase.first; seq; seq = seq->next) {
+ if(seq->type == SEQ_META) {
seq_update_sound_bounds_recursive(scene, seq);
}
- else if(ELEM(seq->type, SEQ_SOUND, SEQ_SCENE))
- {
+ else if(ELEM(seq->type, SEQ_SOUND, SEQ_SCENE)) {
seq_update_sound_bounds(scene, seq);
}
}
@@ -3170,8 +3166,7 @@ void seq_update_sound_bounds_all(Scene *scene)
void seq_update_sound_bounds(Scene* scene, Sequence *seq)
{
- if(seq->scene_sound)
- {
+ if(seq->scene_sound) {
sound_move_scene_sound(scene, seq->scene_sound, seq->startdisp, seq->enddisp, seq->startofs + seq->anim_startofs);
/* mute is set in seq_update_muting_recursive */
}
diff --git a/source/blender/blenkernel/intern/sound.c b/source/blender/blenkernel/intern/sound.c
index a364f860255..842923e63d0 100644
--- a/source/blender/blenkernel/intern/sound.c
+++ b/source/blender/blenkernel/intern/sound.c
@@ -24,6 +24,7 @@
#include "DNA_sound_types.h"
#include "DNA_speaker_types.h"
+#define WITH_AUDASPACE
#ifdef WITH_AUDASPACE
# include "AUD_C-API.h"
#endif
@@ -649,9 +650,10 @@ int sound_get_channels(struct bSound* sound)
return info.specs.channels;
}
-void sound_update_scene(struct Main* bmain, struct Scene* scene)
+void sound_update_scene(struct Scene* scene)
{
Object* ob;
+ Base* base;
NlaTrack* track;
NlaStrip* strip;
Speaker* speaker;
@@ -660,8 +662,9 @@ void sound_update_scene(struct Main* bmain, struct Scene* scene)
void* handle;
float quat[4];
- for(ob = bmain->object.first; ob; ob = ob->id.next)
+ for(base = FIRSTBASE; base; base=base->next)
{
+ ob = base->object;
if(ob->type == OB_SPEAKER)
{
if(ob->adt)
diff --git a/source/gameengine/Ketsji/CMakeLists.txt b/source/gameengine/Ketsji/CMakeLists.txt
index 73365860fce..99c9fb25a65 100644
--- a/source/gameengine/Ketsji/CMakeLists.txt
+++ b/source/gameengine/Ketsji/CMakeLists.txt
@@ -45,37 +45,14 @@ set(INC
../../blender/gpu
../../blender/imbuf
../../blender/makesdna
+ ../../blender/makesrna
../../blender/python
../../blender/python/generic
../../blender/python/mathutils
../../../intern/container
../../../intern/guardedalloc
- ../../../intern/container
- ../../../source/gameengine/Rasterizer/RAS_OpenGLRasterizer
- ../../../source/gameengine/Converter
- ../../../source/gameengine/BlenderRoutines
- ../../../source/blender/imbuf
../../../intern/moto/include
../../../intern/string
- ../../../source/gameengine/Ketsji
- ../../../source/blender/blenlib
- ../../../source/blender/blenfont
- ../../../source/blender/blenkernel
- ../../../source/blender/python
- ../../../source/blender/python/generic
- ../../../source/blender
- ../../../source/blender/makesdna
- ../../../source/blender/makesrna
- ../../../source/gameengine/Rasterizer
- ../../../source/gameengine/GameLogic
- ../../../source/gameengine/Expressions
- ../../../source/gameengine/Ketsji/KXNetwork
- ../../../source/gameengine/Network
- ../../../source/gameengine/SceneGraph
- ../../../source/gameengine/Physics/common
- ../../../source/gameengine/Network/LoopBackNetwork
- ../../../source/blender/blenloader
- ../../../source/blender/gpu
)
set(INC_SYS
diff --git a/source/gameengine/Ketsji/KX_KetsjiEngine.cpp b/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
index dd1cc09cdc6..620f46e743e 100644
--- a/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
+++ b/source/gameengine/Ketsji/KX_KetsjiEngine.cpp
@@ -96,7 +96,6 @@ const char KX_KetsjiEngine::m_profileLabels[tc_numCategories][15] = {
"Animations:", // tc_animations
"Network:", // tc_network
"Scenegraph:", // tc_scenegraph
- "Sound:", // tc_sound
"Rasterizer:", // tc_rasterizer
"Services:", // tc_services
"Overhead:", // tc_overhead
@@ -692,8 +691,6 @@ else
else
if(scene->getSuspendedTime()==0.0)
scene->setSuspendedTime(m_clockTime);
-
- DoSound(scene);
m_logger->StartLog(tc_services, m_kxsystem->GetTimeInSeconds(), true);
}
@@ -769,8 +766,6 @@ else
if(scene->getSuspendedTime()==0.0)
scene->setSuspendedTime(m_clockTime);
- DoSound(scene);
-
m_logger->StartLog(tc_services, m_kxsystem->GetTimeInSeconds(), true);
}
}
@@ -1003,35 +998,6 @@ const STR_String& KX_KetsjiEngine::GetExitString()
}
-
-void KX_KetsjiEngine::DoSound(KX_Scene* scene)
-{
- m_logger->StartLog(tc_sound, m_kxsystem->GetTimeInSeconds(), true);
-
- // nothing to do here, everything relative now...
- /*KX_Camera* cam = scene->GetActiveCamera();
- if (!cam)
- return;
-
- AUD_I3DDevice* dev = AUD_get3DDevice();
- if(dev)
- {
- AUD_Vector3 v;
- //float q[4];
- //cam->NodeGetWorldPosition().getValue(v.get());
- dev->setListenerLocation(v);
-
- //cam->GetLinearVelocity().getValue(v.get());
- dev->setListenerVelocity(v);
-
- //cam->NodeGetWorldOrientation().getRotation().getValue(q);
- //dev->setListenerOrientation(AUD_Quaternion(q[3], q[0], q[1], q[2]));
- dev->setListenerOrientation(AUD_Quaternion());
- }*/
-}
-
-
-
void KX_KetsjiEngine::SetBackGround(KX_WorldInfo* wi)
{
if (wi->hasWorld())
diff --git a/source/gameengine/Ketsji/KX_KetsjiEngine.h b/source/gameengine/Ketsji/KX_KetsjiEngine.h
index 95a6b3401a7..b1009c7d8f0 100644
--- a/source/gameengine/Ketsji/KX_KetsjiEngine.h
+++ b/source/gameengine/Ketsji/KX_KetsjiEngine.h
@@ -153,7 +153,6 @@ private:
tc_animations,
tc_network,
tc_scenegraph,
- tc_sound,
tc_rasterizer,
tc_services, // time spend in miscelaneous activities
tc_overhead, // profile info drawing overhead
@@ -199,7 +198,6 @@ private:
void RenderDebugProperties();
void RenderShadowBuffers(KX_Scene *scene);
void SetBackGround(KX_WorldInfo* worldinfo);
- void DoSound(KX_Scene* scene);
void RenderFonts(KX_Scene* scene);
public: