[vlc-commits] directx: improve DirectSound and DirectDraw module names

Rémi Denis-Courmont git at videolan.org
Thu Jul 19 15:51:29 CEST 2012


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Thu Jul 19 16:25:31 2012 +0300| [35ac8d12b578c149c732284f3c569ce139da1871] | committer: Rémi Denis-Courmont

directx: improve DirectSound and DirectDraw module names

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=35ac8d12b578c149c732284f3c569ce139da1871
---

 modules/LIST                                      |    4 ++--
 modules/audio_output/Modules.am                   |   10 +++++-----
 modules/audio_output/directx.c                    |    2 +-
 modules/gui/qt4/components/simple_preferences.cpp |    4 ++--
 modules/video_output/msw/Modules.am               |   10 +++++-----
 modules/video_output/msw/common.c                 |   12 ++++++------
 modules/video_output/msw/common.h                 |    2 +-
 modules/video_output/msw/events.c                 |    6 +++---
 8 files changed, 25 insertions(+), 25 deletions(-)

diff --git a/modules/LIST b/modules/LIST
index d518d93..e6af94e 100644
--- a/modules/LIST
+++ b/modules/LIST
@@ -43,7 +43,6 @@ $Id$
  * anaglyph: anaglyph 3d video filter
  * android_surface: video output for Android, based on Surface
  * antiflicker: anti-flicker video filter
- * aout_directx: audio output module using the DirectX API
  * aout_file: Audio output to write to a file
  * araw: Pseudo audio decoder for raw PCM
  * asf: ASF demuxer
@@ -93,8 +92,9 @@ $Id$
  * dirac: BBC Dirac codec
  * direct2d: video output module using the Direct2D API
  * direct3d: video output module using the Direct3D API
+ * directdraw: video output module using the DirectDraw API
  * directfb: Direct Framebuffer video output
- * directx: video output module using the DirectX API
+ * directsound: audio output module using the DirectSound API
  * dmo: a DirectMediaObject decoder that uses DirectMedia to decode video (WMV3)
  * dolby_surround_decoder: simple decoder for dolby surround encoded streams
  * drawable: legacy LibVLC video window provider
diff --git a/modules/audio_output/Modules.am b/modules/audio_output/Modules.am
index de0c292..1eca3c7 100644
--- a/modules/audio_output/Modules.am
+++ b/modules/audio_output/Modules.am
@@ -44,12 +44,12 @@ if HAVE_PULSE
 libvlc_LTLIBRARIES += libpulse_plugin.la
 endif
 
-libaout_directx_plugin_la_SOURCES = directx.c windows_audio_common.h packet.c
-libaout_directx_plugin_la_CFLAGS = $(AM_CFLAGS)
-libaout_directx_plugin_la_LIBADD = $(AM_LIBADD)
-libaout_directx_plugin_la_DEPENDENCIES =
+libdirectsound_plugin_la_SOURCES = directx.c windows_audio_common.h packet.c
+libdirectsound_plugin_la_CFLAGS = $(AM_CFLAGS)
+libdirectsound_plugin_la_LIBADD = $(AM_LIBADD)
+libdirectsound_plugin_la_DEPENDENCIES =
 if HAVE_DIRECTX
-libvlc_LTLIBRARIES += libaout_directx_plugin.la
+libvlc_LTLIBRARIES += libdirectsound_plugin.la
 endif
 
 libkai_plugin_la_SOURCES = kai.c packet.c
diff --git a/modules/audio_output/directx.c b/modules/audio_output/directx.c
index 0d09548..a23e490 100644
--- a/modules/audio_output/directx.c
+++ b/modules/audio_output/directx.c
@@ -138,7 +138,7 @@ vlc_module_begin ()
     set_capability( "audio output", 100 )
     set_category( CAT_AUDIO )
     set_subcategory( SUBCAT_AUDIO_AOUT )
-    add_shortcut( "directx", "directsound" )
+    add_shortcut( "directx", "aout_directx" )
 
     add_string( "directx-audio-device", "default",
              DEVICE_TEXT, DEVICE_LONGTEXT, false )
diff --git a/modules/gui/qt4/components/simple_preferences.cpp b/modules/gui/qt4/components/simple_preferences.cpp
index 3ff0087..ee4f049 100644
--- a/modules/gui/qt4/components/simple_preferences.cpp
+++ b/modules/gui/qt4/components/simple_preferences.cpp
@@ -744,7 +744,7 @@ void SPrefsPanel::updateAudioOptions( int number)
     QString value = qobject_cast<QComboBox *>(optionWidgets[audioOutCoB])
                                             ->itemData( number ).toString();
 #ifdef WIN32
-    optionWidgets[directxW]->setVisible( ( value == "aout_directx" ) );
+    optionWidgets[directxW]->setVisible( ( value == "directsound" ) );
 #elif defined( __OS2__ )
     optionWidgets[kaiW]->setVisible( ( value == "kai" ) );
 #else
@@ -757,7 +757,7 @@ void SPrefsPanel::updateAudioOptions( int number)
 #endif
     optionWidgets[fileW]->setVisible( ( value == "aout_file" ) );
     optionWidgets[spdifChB]->setVisible( ( value == "alsa" || value == "oss" || value == "auhal" ||
-                                           value == "aout_directx" || value == "waveout" ) );
+                                           value == "directsound" || value == "waveout" ) );
 }
 
 
diff --git a/modules/video_output/msw/Modules.am b/modules/video_output/msw/Modules.am
index 6ef2365..d74aeeb 100644
--- a/modules/video_output/msw/Modules.am
+++ b/modules/video_output/msw/Modules.am
@@ -6,18 +6,18 @@ SOURCES_direct2d = \
         common.c \
         $(NULL)
 
-libdirectx_plugin_la_SOURCES = \
+libdirectdraw_plugin_la_SOURCES = \
 	directx.c \
 	common.h \
 	events.h \
 	events.c \
 	common.c \
 	$(NULL)
-libdirectx_plugin_la_CFLAGS = $(AM_CFLAGS)
-libdirectx_plugin_la_LIBADD = $(AM_LIBADD) -luser32 -lgdi32 -lole32 -luuid
-libdirectx_plugin_la_DEPENDENCIES =
+libdirectdraw_plugin_la_CFLAGS = $(AM_CFLAGS)
+libdirectdraw_plugin_la_LIBADD = $(AM_LIBADD) -luser32 -lgdi32 -lole32 -luuid
+libdirectdraw_plugin_la_DEPENDENCIES =
 if HAVE_DIRECTX
-libvlc_LTLIBRARIES += libdirectx_plugin.la
+libvlc_LTLIBRARIES += libdirectdraw_plugin.la
 endif
 
 SOURCES_direct3d = \
diff --git a/modules/video_output/msw/common.c b/modules/video_output/msw/common.c
index 4743516..e9ebfc9 100644
--- a/modules/video_output/msw/common.c
+++ b/modules/video_output/msw/common.c
@@ -39,7 +39,7 @@
 #include <windowsx.h>
 #include <shellapi.h>
 
-#ifdef MODULE_NAME_IS_directx
+#ifdef MODULE_NAME_IS_directdraw
 #include <ddraw.h>
 #endif
 #ifdef MODULE_NAME_IS_direct3d
@@ -99,7 +99,7 @@ int CommonInit(vout_display_t *vd)
 #ifdef MODULE_NAME_IS_direct3d
     cfg.use_desktop = sys->use_desktop;
 #endif
-#ifdef MODULE_NAME_IS_directx
+#ifdef MODULE_NAME_IS_directdraw
     cfg.use_overlay = sys->use_overlay;
 #endif
     cfg.win.type   = VOUT_WINDOW_TYPE_HWND;
@@ -396,7 +396,7 @@ void UpdateRects(vout_display_t *vd,
     rect_dest.top = point.y + place.y;
     rect_dest.bottom = rect_dest.top + place.height;
 
-#ifdef MODULE_NAME_IS_directx
+#ifdef MODULE_NAME_IS_directdraw
     /* Apply overlay hardware constraints */
     if (sys->use_overlay)
         AlignRect(&rect_dest, sys->i_align_dest_boundary, sys->i_align_dest_size);
@@ -404,7 +404,7 @@ void UpdateRects(vout_display_t *vd,
 
 #endif
 
-#if defined(MODULE_NAME_IS_directx)
+#if defined(MODULE_NAME_IS_directdraw)
     /* UpdateOverlay directdraw function doesn't automatically clip to the
      * display size so we need to do it otherwise it will fail */
 
@@ -458,7 +458,7 @@ void UpdateRects(vout_display_t *vd,
       (rect_dest.bottom - rect_dest_clipped.bottom) *
       source->i_visible_height / (rect_dest.bottom - rect_dest.top);
 
-#ifdef MODULE_NAME_IS_directx
+#ifdef MODULE_NAME_IS_directdraw
     /* Apply overlay hardware constraints */
     if (sys->use_overlay)
         AlignRect(&rect_src_clipped, sys->i_align_src_boundary, sys->i_align_src_size);
@@ -477,7 +477,7 @@ void UpdateRects(vout_display_t *vd,
                 rect_src_clipped.right, rect_src_clipped.bottom);
 #endif
 
-#ifdef MODULE_NAME_IS_directx
+#ifdef MODULE_NAME_IS_directdraw
     /* The destination coordinates need to be relative to the current
      * directdraw primary surface (display) */
     rect_dest_clipped.left -= sys->rect_display.left;
diff --git a/modules/video_output/msw/common.h b/modules/video_output/msw/common.h
index e7bed61..704311d 100644
--- a/modules/video_output/msw/common.h
+++ b/modules/video_output/msw/common.h
@@ -110,7 +110,7 @@ struct vout_display_sys_t
 
     picture_pool_t *pool;
 
-#ifdef MODULE_NAME_IS_directx
+#ifdef MODULE_NAME_IS_directdraw
     /* Multi-monitor support */
     HMONITOR             hmonitor;          /* handle of the current monitor */
     GUID                 *display_driver;
diff --git a/modules/video_output/msw/events.c b/modules/video_output/msw/events.c
index 51de721..8952f85f 100644
--- a/modules/video_output/msw/events.c
+++ b/modules/video_output/msw/events.c
@@ -40,7 +40,7 @@
 
 #include <ctype.h>
 
-#ifdef MODULE_NAME_IS_directx
+#ifdef MODULE_NAME_IS_directdraw
 #include <ddraw.h>
 #endif
 #ifdef MODULE_NAME_IS_direct3d
@@ -788,7 +788,7 @@ static long FAR PASCAL DirectXEventProc( HWND hwnd, UINT message,
 
     if( hwnd == p_event->hvideownd )
     {
-#ifdef MODULE_NAME_IS_directx
+#ifdef MODULE_NAME_IS_directdraw
         vlc_mutex_lock( &p_event->lock );
         const bool use_overlay = p_event->use_overlay;
         vlc_mutex_unlock( &p_event->lock );
@@ -796,7 +796,7 @@ static long FAR PASCAL DirectXEventProc( HWND hwnd, UINT message,
 
         switch( message )
         {
-#ifdef MODULE_NAME_IS_directx
+#ifdef MODULE_NAME_IS_directdraw
         case WM_ERASEBKGND:
         /* For overlay, we need to erase background */
             return !use_overlay ? 1 : DefWindowProc(hwnd, message, wParam, lParam);



More information about the vlc-commits mailing list