From 9365711ee188a28ef52ed6fd8c07811bb725b7d2 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 6 Jan 2009 01:45:09 -0700 Subject: Streaming music/video now works on Windows. --- ChangeLog.txt | 23 +- linden/indra/llmedia/CMakeLists.txt | 20 +- linden/indra/llmedia/llmediaimplgstreamer.cpp | 279 ++++++++++----------- linden/indra/llmedia/llmediaimplgstreamer.h | 10 +- linden/indra/llmedia/llmediaimplgstreamer_syms.cpp | 4 +- linden/indra/llmedia/llmediaimplgstreamer_syms.h | 4 +- .../indra/llmedia/llmediaimplgstreamervidplug.cpp | 28 +-- linden/indra/llmedia/llmediaimplgstreamervidplug.h | 8 +- linden/indra/llmedia/llmediamanager.cpp | 8 +- linden/indra/llwindow/llwindowsdl.cpp | 4 +- 10 files changed, 200 insertions(+), 188 deletions(-) diff --git a/ChangeLog.txt b/ChangeLog.txt index 4ebc477..62e959b 100644 --- a/ChangeLog.txt +++ b/ChangeLog.txt @@ -1,5 +1,26 @@ -2008-12-30 McCabe Maxsted +2008-01-06 McCabe Maxsted + * linden/indra/llmedia/CMakeLists.txt: + Streaming music/video now works on Windows. + * linden/indra/llmedia/llmediaimplgstreamer.cpp: + Ditto. + * linden/indra/llmedia/llmediaimplgstreamer.h: + Ditto. + * linden/indra/llmedia/llmediaimplgstreamer_syms.cpp: + Ditto. + * linden/indra/llmedia/llmediaimplgstreamer_syms.h: + Ditto. + * linden/indra/llmedia/llmediaimplgstreamervidplug.cpp: + Ditto. + * linden/indra/llmedia/llmediaimplgstreamervidplug.h: + Ditto. + * linden/indra/llmedia/llmediamanager.cpp: + Ditto. + * linden/indra/llwindow/llwindowsdl.cpp: + Ditto. + + +2008-12-30 McCabe Maxsted * linden/indra/llaudio/audioengine_openal.cpp: Fixed a compile problem in VS2005. diff --git a/linden/indra/llmedia/CMakeLists.txt b/linden/indra/llmedia/CMakeLists.txt index 8ef8006..026afc1 100644 --- a/linden/indra/llmedia/CMakeLists.txt +++ b/linden/indra/llmedia/CMakeLists.txt @@ -29,6 +29,9 @@ set(llmedia_SOURCE_FILES llmediaimplexample2.cpp llmediaimplfactory.cpp llmediamanager.cpp + llmediaimplgstreamer.cpp + llmediaimplgstreamer_syms.cpp + llmediaimplgstreamervidplug.cpp ) set(llmedia_HEADER_FILES @@ -43,21 +46,11 @@ set(llmedia_HEADER_FILES llmediaimplregister.h llmediamanager.h llmediaobserver.h + llmediaimplgstreamer.h + llmediaimplgstreamervidplug.h + llmediaimplgstreamer_syms.h ) -if (GSTREAMER) - list(APPEND llmedia_SOURCE_FILES - llmediaimplgstreamer.cpp - llmediaimplgstreamer_syms.cpp - llmediaimplgstreamervidplug.cpp - ) - - list(APPEND llmedia_HEADER_FILES - llmediaimplgstreamer.h - llmediaimplgstreamervidplug.h - llmediaimplgstreamer_syms.h - ) - # Work around a bad interaction between broken gstreamer headers and # g++ 4.3's increased strictness. @@ -65,7 +58,6 @@ if (GSTREAMER) set_source_files_properties(llmediaimplgstreamervidplug.cpp PROPERTIES COMPILE_FLAGS -Wno-error=write-strings) endif (${CXX_VERSION} MATCHES "4.[23]") -endif (GSTREAMER) if (MOZLIB) list(APPEND llmedia_SOURCE_FILES llmediaimplllmozlib.cpp) diff --git a/linden/indra/llmedia/llmediaimplgstreamer.cpp b/linden/indra/llmedia/llmediaimplgstreamer.cpp index fa42756..f4ff8c2 100644 --- a/linden/indra/llmedia/llmediaimplgstreamer.cpp +++ b/linden/indra/llmedia/llmediaimplgstreamer.cpp @@ -32,7 +32,7 @@ #include "llmediaimplgstreamer.h" -#if LL_GSTREAMER_ENABLED +///#if LL_GSTREAMER_ENABLED extern "C" { #include @@ -50,6 +50,7 @@ extern "C" { #include "llmediaimplgstreamer_syms.h" #include "llerror.h" + // register this impl with media manager factory static LLMediaImplRegister sLLMediaImplGStreamerReg( "LLMediaImplGStreamer", new LLMediaImplGStreamerMaker() ); @@ -100,7 +101,8 @@ LLMediaImplGStreamer () : return; // error } - if (NULL == getenv("LL_GSTREAMER_EXTERNAL")) { + if (NULL == getenv("LL_GSTREAMER_EXTERNAL")) + { // instantiate and connect a custom video sink LL_DEBUGS("MediaManager") << "extrenal video sink..." << LL_ENDL; mVideoSink = @@ -166,25 +168,28 @@ std::string LLMediaImplGStreamer::getVersion() rtn = "[" + sLLMediaImplGStreamerReg.getImplName() + "] - GStreamer 0.10.x"; return rtn; } - +// +//THIS IS THE METHOD THAT'S BREAKING STUFF /////////////////////////////////////////////////////////////////////////////// // (static) super-initialization - called once at application startup -bool -LLMediaImplGStreamer:: -startup ( LLMediaManagerData* init_data ) +bool LLMediaImplGStreamer::startup (LLMediaManagerData* init_data) { static bool done_init = false; if (!done_init) { + // Init the glib type system - we need it. + g_type_init(); + // Get symbols! - if (! grab_gst_syms("libgstreamer-0.10.so.0", - "libgstvideo-0.10.so.0", - "libgstaudio-0.10.so.0") ) +#if LL_WINDOWS + if (! grab_gst_syms("libgstreamer-0.10.dll", "libgstvideo-0.10.dll", "libgstaudio-0.10.dll") ) +#else + if (! grab_gst_syms("libgstreamer-0.10.so.0", "libgstvideo-0.10.so.0", "libgstaudio-0.10.so.0") ) { LL_WARNS("MediaImpl") << "Couldn't find suitable GStreamer 0.10 support on this system - video playback disabled." << LL_ENDL; return false; } - +#endif if (llgst_segtrap_set_enabled) llgst_segtrap_set_enabled(FALSE); else @@ -211,16 +216,13 @@ startup ( LLMediaManagerData* init_data ) done_init = true; } - return true; } -bool LLMediaImplGStreamer:: -closedown() +bool LLMediaImplGStreamer::closedown() { ungrab_gst_syms(); - return true; } @@ -228,122 +230,128 @@ closedown() /////////////////////////////////////////////////////////////////////////////// // //#define LL_GST_REPORT_STATE_CHANGES -#ifdef LL_GST_REPORT_STATE_CHANGES +///#ifdef LL_GST_REPORT_STATE_CHANGES static const char* get_gst_state_name(GstState state) { - switch (state) { - case GST_STATE_VOID_PENDING: return "VOID_PENDING"; - case GST_STATE_NULL: return "NULL"; - case GST_STATE_READY: return "READY"; - case GST_STATE_PAUSED: return "PAUSED"; - case GST_STATE_PLAYING: return "PLAYING"; + switch (state) + { + case GST_STATE_VOID_PENDING: return "VOID_PENDING"; + case GST_STATE_NULL: return "NULL"; + case GST_STATE_READY: return "READY"; + case GST_STATE_PAUSED: return "PAUSED"; + case GST_STATE_PLAYING: return "PLAYING"; } return "(unknown)"; } -#endif // LL_GST_REPORT_STATE_CHANGES +///#endif // LL_GST_REPORT_STATE_CHANGES //static -gboolean -LLMediaImplGStreamer::bus_callback (GstBus *bus, - GstMessage *message, - gpointer data) +gboolean LLMediaImplGStreamer::bus_callback(GstBus *bus, GstMessage *message, gpointer data) { LL_DEBUGS("MediaCallback") << "Got GST message type: " << LLGST_MESSAGE_TYPE_NAME (message) << LL_ENDL; LLMediaImplGStreamer *impl = (LLMediaImplGStreamer*)data; - switch (GST_MESSAGE_TYPE (message)) { - case GST_MESSAGE_BUFFERING: { - // NEEDS GST 0.10.11+ - if (llgst_message_parse_buffering) + switch (GST_MESSAGE_TYPE (message)) + { + case GST_MESSAGE_BUFFERING: { - gint percent = 0; - llgst_message_parse_buffering(message, &percent); - LL_DEBUGS("MediaBuffering") << "GST buffering: " << percent << "%%" << LL_ENDL; - LLMediaEvent event( impl, percent ); - impl->getEventEmitter().update( &LLMediaObserver::onUpdateProgress, event ); - + // NEEDS GST 0.10.11+ + if (llgst_message_parse_buffering) + { + gint percent = 0; + llgst_message_parse_buffering(message, &percent); + LL_DEBUGS("MediaBuffering") << "GST buffering: " << percent << "%%" << LL_ENDL; + LLMediaEvent event( impl, percent ); + impl->getEventEmitter().update( &LLMediaObserver::onUpdateProgress, event ); + } } - break; - } - case GST_MESSAGE_STATE_CHANGED: { - GstState old_state; - GstState new_state; - GstState pending_state; - llgst_message_parse_state_changed(message, + break; + case GST_MESSAGE_STATE_CHANGED: + { + GstState old_state; + GstState new_state; + GstState pending_state; + llgst_message_parse_state_changed(message, &old_state, &new_state, &pending_state); -#ifdef LL_GST_REPORT_STATE_CHANGES +///#ifdef LL_GST_REPORT_STATE_CHANGES // not generally very useful, and rather spammy. LL_DEBUGS("MediaState") << "GST state change (old,,pending): "<< get_gst_state_name(old_state) << ",<" << get_gst_state_name(new_state) << ">," << get_gst_state_name(pending_state) << LL_ENDL; -#endif // LL_GST_REPORT_STATE_CHANGES +///#endif // LL_GST_REPORT_STATE_CHANGES - switch (new_state) { - case GST_STATE_VOID_PENDING: - break; - case GST_STATE_NULL: - LL_DEBUGS("MediaImpl") << "State changed to NULL" << LL_ENDL; - if (impl->getState() == GST_STATE_PLAYING) { // We got stoped by gstremer... - impl->play(); - LL_DEBUGS("MediaImpl") << "Trying to restart." << LL_ENDL; + switch (new_state) + { + case GST_STATE_VOID_PENDING: + break; + case GST_STATE_NULL: + LL_DEBUGS("MediaImpl") << "State changed to NULL" << LL_ENDL; + if (impl->getState() == GST_STATE_PLAYING) + { // We got stoped by gstremer... + impl->play(); + LL_DEBUGS("MediaImpl") << "Trying to restart." << LL_ENDL; + } + break; + case GST_STATE_READY: + break; + case GST_STATE_PAUSED: + break; + case GST_STATE_PLAYING: + LLMediaEvent event( impl, 100 ); + impl->getEventEmitter().update( &LLMediaObserver::onUpdateProgress, event ); + // emit an event to say that a media source was loaded + LLMediaEvent event2( impl ); + impl->getEventEmitter().update( &LLMediaObserver::onMediaLoaded, event2 ); + break; } break; - case GST_STATE_READY: - break; - case GST_STATE_PAUSED: - break; - case GST_STATE_PLAYING: - LLMediaEvent event( impl, 100 ); - impl->getEventEmitter().update( &LLMediaObserver::onUpdateProgress, event ); - // emit an event to say that a media source was loaded - LLMediaEvent event2( impl ); - impl->getEventEmitter().update( &LLMediaObserver::onMediaLoaded, event2 ); - break; } - break; - } - case GST_MESSAGE_ERROR: { - GError *err = NULL; - gchar *debug = NULL; + case GST_MESSAGE_ERROR: + { + GError *err = NULL; + gchar *debug = NULL; - llgst_message_parse_error (message, &err, &debug); - LL_WARNS("MediaImpl") << "GST Error: " << err->message << LL_ENDL; - g_error_free (err); - g_free (debug); + llgst_message_parse_error (message, &err, &debug); + LL_WARNS("MediaImpl") << "GST Error: " << err->message << LL_ENDL; + g_error_free (err); + g_free (debug); - impl->addCommand(LLMediaBase::COMMAND_STOP); - //impl->addCommand(LLMediaBase::COMMAND_START); + impl->addCommand(LLMediaBase::COMMAND_STOP); + //impl->addCommand(LLMediaBase::COMMAND_START); - break; - } - case GST_MESSAGE_INFO: { - if (llgst_message_parse_info) + break; + } + case GST_MESSAGE_INFO: { - GError *err = NULL; - gchar *debug = NULL; + if (llgst_message_parse_info) + { + GError *err = NULL; + gchar *debug = NULL; - llgst_message_parse_info (message, &err, &debug); - LL_INFOS("MediaImpl") << "GST info: " << err->message + llgst_message_parse_info (message, &err, &debug); + LL_INFOS("MediaImpl") << "GST info: " << err->message << LL_ENDL; - g_error_free (err); - g_free (debug); + g_error_free (err); + g_free (debug); + } + break; } - break; - } - case GST_MESSAGE_WARNING: { - GError *err = NULL; - gchar *debug = NULL; + case GST_MESSAGE_WARNING: + { + GError *err = NULL; + gchar *debug = NULL; - llgst_message_parse_warning (message, &err, &debug); - LL_WARNS("MediaImpl") << "GST warning: " << err->message + llgst_message_parse_warning (message, &err, &debug); + LL_WARNS("MediaImpl") << "GST warning: " << err->message << LL_ENDL; - g_error_free (err); - g_free (debug); + g_error_free (err); + g_free (debug); - break; - } - case GST_MESSAGE_TAG: { + break; + } + case GST_MESSAGE_TAG: + { #if 0 GstTagList *tag_list; gchar *title; @@ -358,28 +366,29 @@ LLMediaImplGStreamer::bus_callback (GstBus *bus, if(hazArtist) LL_INFOS("MediaInfo") << "Artist is " << artist << LL_ENDL; #endif - break; - } - case GST_MESSAGE_EOS: - /* end-of-stream */ - LL_DEBUGS("MediaImpl") << "GST end-of-stream." << LL_ENDL; - if (impl->isLooping()) - { - LL_DEBUGS("MediaImpl") << "looping media..." << LL_ENDL; - impl->stop(); - impl->play(); + break; } - else + case GST_MESSAGE_EOS: { - // inject a COMMAND_STOP - impl->addCommand(LLMediaBase::COMMAND_STOP); + /* end-of-stream */ + LL_DEBUGS("MediaImpl") << "GST end-of-stream." << LL_ENDL; + if (impl->isLooping()) + { + LL_DEBUGS("MediaImpl") << "looping media..." << LL_ENDL; + impl->stop(); + impl->play(); + } + else + { + // inject a COMMAND_STOP + impl->addCommand(LLMediaBase::COMMAND_STOP); + } + break; + default: + /* unhandled message */ + break; } - break; - default: - /* unhandled message */ - break; } - /* we want to be notified again the next time there is a message * on the bus, so return true (false means we want to stop watching * for messages on the bus and our callback should not be called again) @@ -389,9 +398,7 @@ LLMediaImplGStreamer::bus_callback (GstBus *bus, /////////////////////////////////////////////////////////// // virtual -bool -LLMediaImplGStreamer:: -navigateTo ( const std::string urlIn ) +bool LLMediaImplGStreamer::navigateTo (const std::string urlIn) { LL_DEBUGS("MediaImpl") << "Setting media URI: " << urlIn.c_str() << LL_ENDL; @@ -428,9 +435,7 @@ navigateTo ( const std::string urlIn ) /////////////////////////////////////////////////////////////////////////////// // -bool -LLMediaImplGStreamer:: -unload () +bool LLMediaImplGStreamer::unload() { LL_DEBUGS("MediaImpl") << "unloading media..." << LL_ENDL; if (mPlaybin) @@ -460,9 +465,7 @@ unload () /////////////////////////////////////////////////////////////////////////////// // virtual -bool -LLMediaImplGStreamer:: -updateMedia () +bool LLMediaImplGStreamer::updateMedia() { //LL_DEBUGS("MediaImpl") << "updating media..." << LL_ENDL; @@ -583,9 +586,7 @@ updateMedia () /////////////////////////////////////////////////////////////////////////////// // -bool -LLMediaImplGStreamer:: -stop () +bool LLMediaImplGStreamer::stop() { LL_DEBUGS("MediaImpl") << "stopping media..." << LL_ENDL; // todo: error-check this? @@ -596,9 +597,7 @@ stop () /////////////////////////////////////////////////////////////////////////////// // -bool -LLMediaImplGStreamer:: -play () +bool LLMediaImplGStreamer::play() { LL_DEBUGS("MediaImpl") << "playing media..." << LL_ENDL; // todo: error-check this? @@ -609,9 +608,7 @@ play () /////////////////////////////////////////////////////////////////////////////// // -bool -LLMediaImplGStreamer:: -pause () +bool LLMediaImplGStreamer::pause() { LL_DEBUGS("MediaImpl") <<"pausing media..." << LL_ENDL; // todo: error-check this? @@ -623,9 +620,7 @@ pause () /////////////////////////////////////////////////////////////////////////////// // virtual -unsigned char* -LLMediaImplGStreamer:: -getMediaData () +unsigned char* LLMediaImplGStreamer::getMediaData() { return mediaData; } @@ -633,9 +628,7 @@ getMediaData () /////////////////////////////////////////////////////////////////////////////// // virtual -bool -LLMediaImplGStreamer:: -seek( double time ) +bool LLMediaImplGStreamer::seek(double time) { bool success = false; if (mPlaybin) @@ -654,9 +647,7 @@ seek( double time ) /////////////////////////////////////////////////////////////////////////////// // virtual -bool -LLMediaImplGStreamer:: -setVolume(float volume) +bool LLMediaImplGStreamer::setVolume(float volume) { // XXX hack to make volume volume changes less othen // bug in gstreamer 0.10.21 @@ -673,4 +664,6 @@ setVolume(float volume) return false; } -#endif // LL_GSTREAMER_ENABLED + + +///#endif // LL_GSTREAMER_ENABLED \ No newline at end of file diff --git a/linden/indra/llmedia/llmediaimplgstreamer.h b/linden/indra/llmedia/llmediaimplgstreamer.h index 4d0638a..6deb3f4 100644 --- a/linden/indra/llmedia/llmediaimplgstreamer.h +++ b/linden/indra/llmedia/llmediaimplgstreamer.h @@ -31,13 +31,13 @@ */ // header guard -#ifndef llmediaimplgstreamer_h +///#ifndef llmediaimplgstreamer_h #define llmediaimplgstreamer_h #include "llmediaimplcommon.h" #include "llmediaimplfactory.h" -#if LL_GSTREAMER_ENABLED +///#if LL_GSTREAMER_ENABLED extern "C" { #include @@ -46,6 +46,8 @@ extern "C" { #include "apr_pools.h" #include "apr_dso.h" } +//#include +//#include #include "llmediaimplgstreamervidplug.h" #ifdef LL_GST_SOUNDSINK @@ -131,6 +133,6 @@ public: #define WARNMSG STDERRMSG ///////////////////////////////////////////////////////////////////////// -#endif // LL_GSTREAMER_ENABLED +///#endif // LL_GSTREAMER_ENABLED -#endif // llmediaimplgstreamer_h +///#endif // llmediaimplgstreamer_h diff --git a/linden/indra/llmedia/llmediaimplgstreamer_syms.cpp b/linden/indra/llmedia/llmediaimplgstreamer_syms.cpp index e81d886..fb1949a 100644 --- a/linden/indra/llmedia/llmediaimplgstreamer_syms.cpp +++ b/linden/indra/llmedia/llmediaimplgstreamer_syms.cpp @@ -29,7 +29,7 @@ * $/LicenseInfo$ */ -#if LL_GSTREAMER_ENABLED +///#if LL_GSTREAMER_ENABLED extern "C" { #include @@ -185,4 +185,4 @@ void ungrab_gst_syms() } -#endif // LL_GSTREAMER_ENABLED +///#endif // LL_GSTREAMER_ENABLED diff --git a/linden/indra/llmedia/llmediaimplgstreamer_syms.h b/linden/indra/llmedia/llmediaimplgstreamer_syms.h index 92d46b7..ebebd80 100644 --- a/linden/indra/llmedia/llmediaimplgstreamer_syms.h +++ b/linden/indra/llmedia/llmediaimplgstreamer_syms.h @@ -31,7 +31,7 @@ #include "linden_common.h" -#if LL_GSTREAMER_ENABLED +///#if LL_GSTREAMER_ENABLED extern "C" { #include @@ -75,4 +75,4 @@ void ungrab_gst_syms(); // more hacks #define LLGST_MESSAGE_TYPE_NAME(M) (llgst_message_type_get_name(GST_MESSAGE_TYPE(M))) -#endif // LL_GSTREAMER_ENABLED +///#endif // LL_GSTREAMER_ENABLED diff --git a/linden/indra/llmedia/llmediaimplgstreamervidplug.cpp b/linden/indra/llmedia/llmediaimplgstreamervidplug.cpp index f9c2f89..892c50d 100644 --- a/linden/indra/llmedia/llmediaimplgstreamervidplug.cpp +++ b/linden/indra/llmedia/llmediaimplgstreamervidplug.cpp @@ -29,7 +29,7 @@ * $/LicenseInfo$ */ -#if LL_GSTREAMER_ENABLED +///#if LL_GSTREAMER_ENABLED #include "linden_common.h" @@ -68,8 +68,10 @@ static GstStaticPadTemplate sink_factory = GST_STATIC_PAD_TEMPLATE ( GST_STATIC_CAPS (SLV_ALLCAPS) ); -GST_BOILERPLATE (GstSLVideo, gst_slvideo, GstVideoSink, - GST_TYPE_VIDEO_SINK); +GST_BOILERPLATE (GstSLVideo, + gst_slvideo, + GstVideoSink, + GST_TYPE_VIDEO_SINK); static void gst_slvideo_set_property (GObject * object, guint prop_id, const GValue * value, @@ -229,7 +231,8 @@ gst_slvideo_set_caps (GstBaseSink * bsink, GstCaps * caps) } llgst_caps_unref(intersection); - int width, height; + int width = 0; + int height = 0; gboolean ret; const GValue *fps; const GValue *par; @@ -402,10 +405,8 @@ gst_slvideo_set_property (GObject * object, guint prop_id, { llg_return_if_fail (GST_IS_SLVIDEO (object)); - switch (prop_id) { - default: + if (prop_id) { G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); - break; } } @@ -415,10 +416,8 @@ gst_slvideo_get_property (GObject * object, guint prop_id, { llg_return_if_fail (GST_IS_SLVIDEO (object)); - switch (prop_id) { - default: + if (prop_id) { G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec); - break; } } @@ -446,10 +445,8 @@ plugin_init (GstPlugin * plugin) some g++ versions buggily avoid __attribute__((constructor)) functions - so we provide an explicit plugin init function. */ -void gst_slvideo_init_class (void) -{ #define PACKAGE "packagehack" - static GST_PLUGIN_DEFINE (GST_VERSION_MAJOR, + GST_PLUGIN_DEFINE (GST_VERSION_MAJOR, GST_VERSION_MINOR, "private-slvideoplugin", "SL Video sink plugin", @@ -457,8 +454,11 @@ void gst_slvideo_init_class (void) "Second Life", "http://www.secondlife.com/"); #undef PACKAGE + +void gst_slvideo_init_class (void) +{ ll_gst_plugin_register_static (&gst_plugin_desc); //fprintf(stderr, "\n\n\nCLASS INIT\n\n\n"); } -#endif // LL_GSTREAMER_ENABLED +///#endif // LL_GSTREAMER_ENABLED diff --git a/linden/indra/llmedia/llmediaimplgstreamervidplug.h b/linden/indra/llmedia/llmediaimplgstreamervidplug.h index 27957db..da7de6e 100644 --- a/linden/indra/llmedia/llmediaimplgstreamervidplug.h +++ b/linden/indra/llmedia/llmediaimplgstreamervidplug.h @@ -32,12 +32,13 @@ #ifndef __GST_SLVIDEO_H__ #define __GST_SLVIDEO_H__ -#if LL_GSTREAMER_ENABLED +///#if LL_GSTREAMER_ENABLED extern "C" { #include #include #include +#include } G_BEGIN_DECLS @@ -97,8 +98,11 @@ GType gst_slvideo_get_type (void); void gst_slvideo_init_class (void); +bool g_once_init_enter (volatile gsize *value_location); +void g_once_init_leave (volatile gsize *value_location, gsize initialization_value); + G_END_DECLS -#endif // LL_GSTREAMER_ENABLED +///#endif // LL_GSTREAMER_ENABLED #endif /* __GST_SLVIDEO_H__ */ diff --git a/linden/indra/llmedia/llmediamanager.cpp b/linden/indra/llmedia/llmediamanager.cpp index 57256e6..5394b62 100644 --- a/linden/indra/llmedia/llmediamanager.cpp +++ b/linden/indra/llmedia/llmediamanager.cpp @@ -90,10 +90,10 @@ void LLMediaManager::initClass( LLMediaManagerData* init_data ) LLMediaImplQuickTime::startup( init_data ); #endif // LL_QUICKTIME_ENABLED -#if LL_GSTREAMER_ENABLED +///#if LL_GSTREAMER_ENABLED LL_DEBUGS("MediaManager") << "LLMediaManager::initClass: starting gstreamer" << LL_ENDL; LLMediaImplGStreamer::startup( init_data ); -#endif // LL_GSTREAMER_ENABLED +///#endif // LL_GSTREAMER_ENABLED } //////////////////////////////////////////////////////////////////////////////// @@ -133,9 +133,9 @@ void LLMediaManager::cleanupClass() LLMediaImplQuickTime::closedown(); #endif // LL_QUICKTIME_ENABLED -#if LL_GSTREAMER_ENABLED +///#if LL_GSTREAMER_ENABLED LLMediaImplGStreamer::closedown(); -#endif // LL_QUICKTIME_ENABLED +///#endif // LL_QUICKTIME_ENABLED if ( sInstance ) delete sInstance; diff --git a/linden/indra/llwindow/llwindowsdl.cpp b/linden/indra/llwindow/llwindowsdl.cpp index f0acee5..0cff44f 100644 --- a/linden/indra/llwindow/llwindowsdl.cpp +++ b/linden/indra/llwindow/llwindowsdl.cpp @@ -123,9 +123,9 @@ BOOL ll_try_gtk_init(void) if (!tried_gtk_init) { tried_gtk_init = TRUE; -#if LL_GSTREAMER_ENABLED +///#if LL_GSTREAMER_ENABLED if (!g_thread_supported ()) g_thread_init (NULL); -#endif // LL_GSTREAMER_ENABLED +///#endif // LL_GSTREAMER_ENABLED maybe_lock_display(); gtk_is_good = gtk_init_check(NULL, NULL); maybe_unlock_display(); -- cgit v1.1