--- engine/menu/video_control.cpp.disable-smpeg 2008-09-22 08:10:57.000000000 -0500
+++ engine/menu/video_control.cpp 2011-06-25 03:00:25.000000000 -0500
@@ -7,10 +7,10 @@
#include "config.h"
#include <assert.h>
-#define SMPEG_CHECK(f) do { const char * err; if ((err = SMPEG_error(mpeg)) != NULL) throw_ex(("%s: %s", f, err)); } while(0)
+//#define SMPEG_CHECK(f) do { const char * err; if ((err = SMPEG_error(mpeg)) != NULL) throw_ex(("%s: %s", f, err)); } while(0)
VideoControl::VideoControl(const std::string &base, const std::string &name) :
-base(base), name(name), mpeg(0), lock(SDL_CreateMutex()), active(false), started(false) //, updated(false)
+base(base), name(name), /*mpeg(0),*/ lock(SDL_CreateMutex()), active(false), started(false) //, updated(false)
{
if (lock == NULL)
throw_sdl(("SDL_CreateMutex"));
@@ -25,6 +25,7 @@
if (edv)
return;
+ /*
fname = "maps/" + name + ".mpg";
if (Finder->exists(base, fname)) {
{
@@ -62,6 +63,7 @@
//SMPEG_play(mpeg);
//SMPEG_CHECK("SMPEG_play");
}
+ */
}
void VideoControl::activate(const bool a) {
@@ -71,6 +73,7 @@
}
void VideoControl::checkStatus() {
+ /*
if (mpeg == NULL)
return;
@@ -101,10 +104,12 @@
mpeg = NULL;
break;
}
+ */
}
void VideoControl::tick(const float dt) {
Control::tick(dt);
+ /*
if (mpeg == NULL || !active)
return;
@@ -134,19 +139,22 @@
//updated = false;
SDL_mutexV(lock);
}
+ */
}
void VideoControl::render(sdlx::Surface &surface, const int x, const int y) const {
- if (mpeg == NULL || !active) {
+ //if (mpeg == NULL || !active) {
surface.blit(*screenshot, x, y);
return;
- }
+ //}
+ /*
//int dx = (screenshot->get_width() - mpeg_info.width) / 2;
//int dy = (screenshot->get_height() - mpeg_info.height) / 2;
int dx = 0, dy = 0;
//LOG_DEBUG(("render %d %d", dx, dy));
surface.blit(frame, x + dx, y + dy);
+ */
}
void VideoControl::get_size(int &w, int &h) const {
@@ -155,9 +163,11 @@
}
VideoControl::~VideoControl() {
+ /*
if (mpeg != NULL) {
SMPEG_stop(mpeg);
SMPEG_delete(mpeg);
}
+ */
SDL_DestroyMutex(lock);
}
--- engine/menu/video_control_disabled.h.disable-smpeg 2008-06-08 04:02:39.000000000 -0500
+++ engine/menu/video_control_disabled.h 2011-06-25 03:00:25.000000000 -0500
@@ -3,7 +3,7 @@
#include <string>
#include "control.h"
-#include <smpeg/smpeg.h>
+//#include <smpeg/smpeg.h>
#include "sdlx/surface.h"
class DisabledVideoControl : public Control {
--- engine/menu/video_control.h.disable-smpeg 2008-06-08 04:02:39.000000000 -0500
+++ engine/menu/video_control.h 2011-06-25 03:00:25.000000000 -0500
@@ -3,7 +3,7 @@
#include <string>
#include "control.h"
-#include <smpeg/smpeg.h>
+//#include <smpeg/smpeg.h>
#include "sdlx/surface.h"
#include <SDL_thread.h>
@@ -20,8 +20,8 @@
void checkStatus();
std::string base, name;
const sdlx::Surface *screenshot;
- SMPEG * mpeg;
- SMPEG_Info mpeg_info;
+// SMPEG * mpeg;
+// SMPEG_Info mpeg_info;
sdlx::Surface shadow, frame;
SDL_mutex * lock;
bool active, started;
--- SConstruct.disable-smpeg 2009-12-10 08:58:55.000000000 -0600
+++ SConstruct 2011-06-25 03:13:10.000000000 -0500
@@ -135,13 +135,6 @@
Export('sdl_cflags')
Export('sdl_libs')
-smpeg_lib = 'smpeg'
-if debug and sys.platform == 'win32':
- smpeg_lib = 'smpeg_d'
-Export('smpeg_lib')
-
-if not conf.CheckLibWithHeader(smpeg_lib, 'smpeg/smpeg.h', 'c++', "SMPEG_new_data(malloc(42), 42, NULL, 0);", False):
- Exit(1)
if not conf.CheckLibWithHeader('SDL_image', 'SDL_image.h', 'c++', "IMG_Load(0);", False):
Exit(1)
--- engine/SConscript.disable-smpeg 2011-06-26 12:34:34.000000000 -0500
+++ engine/SConscript 2011-06-26 12:35:11.000000000 -0500
@@ -7,7 +7,6 @@
Import('sdl_cflags')
Import('sdl_libs')
Import('lib_dir')
-Import('smpeg_lib')
venv = env.Clone()
env = env.Clone()
@@ -75,7 +74,7 @@
if debug and sys.platform == "win32":
vorbis = 'vorbisfile_d'
-bt_libs = ['mrt', 'sdlx', smpeg_lib, 'SDL', vorbis, 'clunk']
+bt_libs = ['mrt', 'sdlx', 'SDL', vorbis, 'clunk']
if sys.platform != 'win32':
got_lua = False