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
diff options
context:
space:
mode:
Diffstat (limited to 'source/gameengine/GamePlayer/ghost')
-rw-r--r--source/gameengine/GamePlayer/ghost/CMakeLists.txt1
-rw-r--r--source/gameengine/GamePlayer/ghost/GPG_Application.cpp6
-rw-r--r--source/gameengine/GamePlayer/ghost/GPG_Canvas.cpp12
-rw-r--r--source/gameengine/GamePlayer/ghost/GPG_Canvas.h2
-rw-r--r--source/gameengine/GamePlayer/ghost/GPG_ghost.cpp11
-rw-r--r--source/gameengine/GamePlayer/ghost/SConscript1
6 files changed, 28 insertions, 5 deletions
diff --git a/source/gameengine/GamePlayer/ghost/CMakeLists.txt b/source/gameengine/GamePlayer/ghost/CMakeLists.txt
index a1bc7e88840..dfa115e085c 100644
--- a/source/gameengine/GamePlayer/ghost/CMakeLists.txt
+++ b/source/gameengine/GamePlayer/ghost/CMakeLists.txt
@@ -46,6 +46,7 @@ set(INC
../../../blender/imbuf
../../../blender/makesdna
../../../blender/makesrna
+ ../../../blender/pointcache
../../../../intern/container
../../../../intern/ghost
../../../../intern/glew-mx
diff --git a/source/gameengine/GamePlayer/ghost/GPG_Application.cpp b/source/gameengine/GamePlayer/ghost/GPG_Application.cpp
index 6b69a991968..b8ce67743de 100644
--- a/source/gameengine/GamePlayer/ghost/GPG_Application.cpp
+++ b/source/gameengine/GamePlayer/ghost/GPG_Application.cpp
@@ -636,7 +636,7 @@ bool GPG_Application::initEngine(GHOST_IWindow* window, const int stereoMode)
if (!m_networkdevice)
goto initFailed;
- sound_init(m_maggie);
+ BKE_sound_init(m_maggie);
// create a ketsjisystem (only needed for timing and stuff)
m_kxsystem = new GPG_System (m_system);
@@ -672,7 +672,7 @@ bool GPG_Application::initEngine(GHOST_IWindow* window, const int stereoMode)
return m_engineInitialized;
initFailed:
- sound_exit();
+ BKE_sound_exit();
delete m_kxsystem;
delete m_networkdevice;
delete m_mouse;
@@ -847,7 +847,7 @@ void GPG_Application::exitEngine()
if (!m_engineInitialized)
return;
- sound_exit();
+ BKE_sound_exit();
if (m_ketsjiengine)
{
stopEngine();
diff --git a/source/gameengine/GamePlayer/ghost/GPG_Canvas.cpp b/source/gameengine/GamePlayer/ghost/GPG_Canvas.cpp
index 556f85804ea..09eb1691dae 100644
--- a/source/gameengine/GamePlayer/ghost/GPG_Canvas.cpp
+++ b/source/gameengine/GamePlayer/ghost/GPG_Canvas.cpp
@@ -121,6 +121,18 @@ bool GPG_Canvas::GetSwapInterval(int& intervalOut)
return false;
}
+void GPG_Canvas::GetDisplayDimensions(int &width, int &height)
+ {
+ unsigned int uiwidth;
+ unsigned int uiheight;
+
+ GHOST_ISystem *system = GHOST_ISystem::getSystem();
+ system->getMainDisplayDimensions(uiwidth, uiheight);
+
+ width = uiwidth;
+ height = uiheight;
+}
+
void GPG_Canvas::ResizeWindow(int width, int height)
{
if (m_window->getState() == GHOST_kWindowStateFullScreen)
diff --git a/source/gameengine/GamePlayer/ghost/GPG_Canvas.h b/source/gameengine/GamePlayer/ghost/GPG_Canvas.h
index 337c2cedf55..18afbf6cd9e 100644
--- a/source/gameengine/GamePlayer/ghost/GPG_Canvas.h
+++ b/source/gameengine/GamePlayer/ghost/GPG_Canvas.h
@@ -63,6 +63,8 @@ public:
virtual float GetMouseNormalizedX(int x);
virtual float GetMouseNormalizedY(int y);
+ virtual void GetDisplayDimensions(int &width, int &height);
+
virtual void ResizeWindow(int width, int height);
virtual void SetFullScreen(bool enable);
virtual bool GetFullScreen();
diff --git a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp
index 915fe614957..6d97447dff0 100644
--- a/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp
+++ b/source/gameengine/GamePlayer/ghost/GPG_ghost.cpp
@@ -74,11 +74,14 @@ extern "C"
#include "BKE_report.h"
#include "BKE_library.h"
#include "BKE_modifier.h"
+#include "BKE_material.h"
#include "BKE_text.h"
#include "BKE_sound.h"
#include "IMB_imbuf.h"
#include "IMB_moviecache.h"
+
+#include "PTC_api.h"
#ifdef __APPLE__
int GHOST_HACK_getFirstFile(char buf[]);
@@ -451,6 +454,7 @@ int main(int argc, char** argv)
RNA_init();
init_nodesystem();
+ PTC_alembic_init();
initglobals();
@@ -517,9 +521,12 @@ int main(int argc, char** argv)
// enable fast mipmap generation
U.use_gpu_mipmap = 1;
- sound_init_once();
+ BKE_sound_init_once();
+
+ // Initialize a default material for meshes without materials.
+ init_def_material();
- set_free_windowmanager_cb(wm_free);
+ BKE_library_callback_free_window_manager_set(wm_free);
/* if running blenderplayer the last argument can't be parsed since it has to be the filename. else it is bundled */
isBlenderPlayer = !BLO_is_a_runtime(argv[0]);
diff --git a/source/gameengine/GamePlayer/ghost/SConscript b/source/gameengine/GamePlayer/ghost/SConscript
index 610abcd0357..27adc000413 100644
--- a/source/gameengine/GamePlayer/ghost/SConscript
+++ b/source/gameengine/GamePlayer/ghost/SConscript
@@ -57,6 +57,7 @@ incs = [
'#source/blender/include',
'#source/blender/makesdna',
'#source/blender/makesrna',
+ '#source/blender/pointcache',
'#source/gameengine/Rasterizer',
'#source/gameengine/GameLogic',
'#source/gameengine/Expressions',