[vlc-commits] projectM: change font path on Win32

Jean-Baptiste Kempf git at videolan.org
Thu Jun 30 14:56:20 CEST 2011


vlc | branch: master | Jean-Baptiste Kempf <jb at videolan.org> | Thu Jun 30 14:55:04 2011 +0200| [d8549ccdda7a7626c7b39d7b7260c8a4b77ba78a] | committer: Jean-Baptiste Kempf

projectM: change font path on Win32

Close #4988

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

 modules/visualization/projectm.cpp |   14 +++++++++++---
 1 files changed, 11 insertions(+), 3 deletions(-)

diff --git a/modules/visualization/projectm.cpp b/modules/visualization/projectm.cpp
index ea7ea3f..bcdcb23 100644
--- a/modules/visualization/projectm.cpp
+++ b/modules/visualization/projectm.cpp
@@ -74,6 +74,14 @@ static void Close        ( vlc_object_t * );
 #define TEXTURE_TEXT N_("Texture size")
 #define TEXTURE_LONGTEXT N_("The size of the texture, in pixels.")
 
+#ifdef WIN32
+# define FONT_PATH      "C:\\WINDOWS\\Fonts\\arial.ttf"
+# define FONT_PATH_MENU "C:\\WINDOWS\\Fonts\\arial.ttf"
+#else
+# define FONT_PATH      "/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans.ttf"
+# define FONT_PATH_MENU "/usr/share/fonts/truetype/ttf-dejavu/DejaVuSansMono.ttf"
+#endif
+
 vlc_module_begin ()
     set_shortname( N_("projectM"))
     set_description( N_("libprojectM effect") )
@@ -90,10 +98,10 @@ vlc_module_begin ()
     add_directory( "projectm-preset-path", "/usr/share/projectM/presets",
 #endif
                   PRESET_PATH_TXT, PRESET_PATH_LONGTXT, true )
-    add_loadfile( "projectm-title-font", "/usr/share/fonts/truetype/ttf-dejavu/DejaVuSans.ttf",
+    add_loadfile( "projectm-title-font", FONT_PATH,
                   TITLE_FONT_TXT, TITLE_FONT_LONGTXT, true )
-    add_loadfile( "projectm-menu-font", "/usr/share/fonts/truetype/ttf-dejavu/DejaVuSansMono.ttf",
-              MENU_FONT_TXT, MENU_FONT_LONGTXT, true )
+    add_loadfile( "projectm-menu-font", FONT_PATH_MENU,
+                  MENU_FONT_TXT, MENU_FONT_LONGTXT, true )
 #endif
     add_integer( "projectm-width", 800, WIDTH_TEXT, WIDTH_LONGTEXT,
                  false )



More information about the vlc-commits mailing list