Commit b01923cf authored by Jean-Baptiste Kempf's avatar Jean-Baptiste Kempf

Remove qte and opie modules.

They don't compile since a long time anyway.
parent 4ad5f907
......@@ -1005,9 +1005,6 @@ fi
;;
esac
dnl build the qte plugin ?
NEED_QTE_MAIN=no
dnl Check for ntohl, etc.
AC_CACHE_CHECK([for ntohl in sys/param.h],
[ac_cv_c_ntohl_sys_param_h],
......@@ -3841,33 +3838,6 @@ then
VLC_ADD_PLUGIN([snapshot])
fi
dnl
dnl Qt Embedded module
dnl (disabled by default)
dnl
AC_ARG_ENABLE(qte,
[ --enable-qte QT Embedded support (default disabled)])
if test "${enable_qte}" = "yes"
then
AC_ARG_WITH(qte,
[ --with-qte=PATH Qt Embedded headers and libraries])
if test "${with_qte}" != "no" -a -n "${with_qte}"
then
VLC_ADD_LIBS([qte],[-L${with_qte}/lib `echo -L${with_qte}/lib | sed 's,opt/QtPalmtop,usr,'` -ljpeg -lqte])
VLC_ADD_CXXFLAGS([qte],[-I${with_qte}/include `echo -I${with_qte}/include | sed 's,opt/QtPalmtop,usr,'` -DQT_QWS_IPAQ -DQWS -fno-exceptions -fno-rtti])
else
VLC_ADD_LIBS([qte],[-L${QTDIR}/lib `echo -L${QTDIR}/lib | sed 's,opt/QtPalmtop,usr,'` -ljpeg -lqte])
VLC_ADD_CXXFLAGS([qte],[-I${QTDIR}/include `echo -I${QTDIR}/include | sed 's,opt/QtPalmtop,usr,'` -DQT_QWS_IPAQ -DQWS -fno-exceptions -fno-rtti])
fi
VLC_ADD_PLUGIN([qte])
NEED_QTE_MAIN=yes
CPPFLAGS="${CPPFLAGS_save} ${CXXFLAGS_qte}"
AC_CHECK_HEADERS(qt.h jpeglib.h, ,[
AC_MSG_ERROR([echo "Cannot find QT Embedded development headers."])
] )
CPPFLAGS="${CPPFLAGS_save}"
fi
dnl
dnl Roku HD1000 Video output module
dnl
......@@ -4397,40 +4367,6 @@ AS_IF([test "${enable_skins2}" != "no" && test "x$enable_qt4" = "xno"], [
AC_MSG_ERROR([The skins2 module depends on a the Qt4 development package. Without it you won't be able to open any dialog box from the interface, which makes the skins2 interface rather useless. Install the Qt4 development package or alternatively you can also configure with: --disable-qt4 --disable-skins2.])
])
dnl
dnl Opie QT embedded module
dnl
AC_ARG_ENABLE(opie,
[ --enable-opie Qt embedded interface support (default disabled)],
[if test "${enable_opie}" = "yes"; then
AC_ARG_WITH(qte,
[ --with-qte=PATH Qt Embedded headers and libraries])
if test "${with_qte}" != "no" -a -n "${with_qte}"
then
VLC_ADD_LIBS([qte],[-L${with_qte}/lib `echo -L${with_qte}/lib | sed 's,opt/QtPalmtop,usr,'` -ljpeg -lqte])
VLC_ADD_CXXFLAGS([qte],[-I${with_qte}/include `echo -I${with_qte}/include | sed 's,opt/QtPalmtop,usr,'` -DQT_QWS_IPAQ -DQWS -fno-exceptions -fno-rtti])
else
VLC_ADD_LIBS([qte],[-L${QTDIR}/lib `echo -L${QTDIR}/lib | sed 's,opt/QtPalmtop,usr,'`])
VLC_ADD_CXXFLAGS([qte],[-I${QTDIR}/include `echo -I${QTDIR}/include | sed 's,opt/QtPalmtop,usr,'`])
fi
CPPFLAGS="${CPPFLAGS_save} ${CXXFLAGS_qte}"
AC_CHECK_HEADERS(qt.h jpeglib.h, ,[
AC_MSG_ERROR([echo "Cannot find QT Embedded development headers."])
] )
CPPFLAGS="${CPPFLAGS_save}"
VLC_ADD_PLUGIN([opie])
NEED_QTE_MAIN=yes
VLC_ADD_LIBS([opie],[-lqpe ${LDFLAGS_qte}])
VLC_ADD_CXXFLAGS([opie],[${CXXFLAGS_qte}])
if test "${with_qte}" != "no" -a -n "${with_qte}"
then
MOC=${with_qte}/bin/moc
else
MOC=${QTDIR}/bin/moc
fi
fi])
dnl
dnl MacOS X video output/gui modules
dnl
......@@ -5072,17 +5008,6 @@ then
VLC_ADD_PLUGIN([test4])
fi
dnl
dnl qte_main plugin
dnl
if test "${NEED_QTE_MAIN}" != "no"
then
VLC_ADD_PLUGIN([qte_main])
VLC_ADD_CXXFLAGS([opie qte qt_video],[-DNEED_QTE_MAIN])
VLC_ADD_CXXFLAGS([qte_main],[${CXXFLAGS_qte} ${CXXFLAGS_qt_video}])
VLC_ADD_LDFLAGS([qte_main],[${LDFLAGS_qte} ${LDFLAGS_qt_video}])
fi
dnl
dnl Plugin and builtin checks
dnl
......@@ -5290,7 +5215,6 @@ AC_CONFIG_FILES([
modules/video_filter/dynamicoverlay/Makefile
modules/video_output/Makefile
modules/video_output/msw/Makefile
modules/video_output/qte/Makefile
modules/visualization/Makefile
modules/visualization/visual/Makefile
])
......
......@@ -224,7 +224,6 @@ $Id$
* opencv_wrapper: OpenCV wrapper video filter
* opengl: a opengl video output that uses opengl provider modules
* opengllayer: a simple openGL video output
* opie: interface for Opie using QT/Embedded library
* osd_parser: OSD import module
* osdmenu: video_filter for displaying and streaming a On Screen Display menu
* oss: audio output module using the OSS /dev/dsp interface
......@@ -253,8 +252,6 @@ $Id$
* qnx: QNX RTOS plugin
* qt4: interface module using the cross-platform Qt4 library
* qtcapture: Quicktime Capture
* qte: video output module for Qt Embedded
* qte_main: a QT Embedded GUI wrapper module
* quartztext: Text renderer using native Mac OS X API
* quicktime: Quicktime decoder that uses the QT library
* rawaud: raw audio input module for vlc
......
SOURCES_opie = \
$(NULL)
EXTRA_DIST += opie.ui \
$(NULL)
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>pda</class>
<widget class="QMainWindow">
<property name="name">
<cstring>pda</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>239</width>
<height>391</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>7</hsizetype>
<vsizetype>7</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="baseSize">
<size>
<width>240</width>
<height>320</height>
</size>
</property>
<property name="caption">
<string>VLC (pda)</string>
</property>
<property name="icon">
<pixmap>image0</pixmap>
</property>
<widget class="QSlider">
<property name="name">
<cstring>slider2</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>29</y>
<width>240</width>
<height>20</height>
</rect>
</property>
<property name="orientation">
<enum>Horizontal</enum>
</property>
</widget>
<widget class="QButtonGroup">
<property name="name">
<cstring>toolbar</cstring>
</property>
<property name="enabled">
<bool>true</bool>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>240</width>
<height>22</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>7</hsizetype>
<vsizetype>5</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="frameShape">
<enum>ToolBarPanel</enum>
</property>
<property name="frameShadow">
<enum>Sunken</enum>
</property>
<property name="title">
<string></string>
</property>
<property name="flat">
<bool>false</bool>
</property>
<widget class="QToolButton">
<property name="name">
<cstring>rewind</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>20</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string></string>
</property>
<property name="iconSet">
<iconset>image1</iconset>
</property>
</widget>
<widget class="QToolButton">
<property name="name">
<cstring>stop</cstring>
</property>
<property name="geometry">
<rect>
<x>20</x>
<y>0</y>
<width>20</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string></string>
</property>
<property name="iconSet">
<iconset>image2</iconset>
</property>
</widget>
<widget class="QToolButton">
<property name="name">
<cstring>pause</cstring>
</property>
<property name="geometry">
<rect>
<x>40</x>
<y>0</y>
<width>20</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string></string>
</property>
<property name="iconSet">
<iconset>image3</iconset>
</property>
</widget>
<widget class="QToolButton">
<property name="name">
<cstring>play</cstring>
</property>
<property name="geometry">
<rect>
<x>60</x>
<y>0</y>
<width>20</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string></string>
</property>
<property name="iconSet">
<iconset>image4</iconset>
</property>
</widget>
<widget class="QToolButton">
<property name="name">
<cstring>about</cstring>
</property>
<property name="geometry">
<rect>
<x>210</x>
<y>0</y>
<width>20</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string></string>
</property>
<property name="iconSet">
<iconset>image0</iconset>
</property>
</widget>
<widget class="QToolButton">
<property name="name">
<cstring>forward</cstring>
</property>
<property name="geometry">
<rect>
<x>80</x>
<y>0</y>
<width>20</width>
<height>21</height>
</rect>
</property>
<property name="text">
<string></string>
</property>
<property name="iconSet">
<iconset>image5</iconset>
</property>
</widget>
</widget>
<widget class="QTabWidget">
<property name="name">
<cstring>tabWidget2S</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>50</y>
<width>240</width>
<height>320</height>
</rect>
</property>
<widget class="QWidget">
<property name="name">
<cstring>file</cstring>
</property>
<attribute name="title">
<string>File</string>
</attribute>
<widget class="QPushButton">
<property name="name">
<cstring>filePlaylist</cstring>
</property>
<property name="geometry">
<rect>
<x>70</x>
<y>260</y>
<width>87</width>
<height>30</height>
</rect>
</property>
<property name="text">
<string>Add Playlist</string>
</property>
</widget>
<widget class="QListView">
<column>
<property name="text">
<string>File</string>
</property>
<property name="clickable">
<bool>true</bool>
</property>
<property name="resizable">
<bool>true</bool>
</property>
</column>
<column>
<property name="text">
<string>Size</string>
</property>
<property name="clickable">
<bool>true</bool>
</property>
<property name="resizable">
<bool>true</bool>
</property>
</column>
<column>
<property name="text">
<string>Rights</string>
</property>
<property name="clickable">
<bool>true</bool>
</property>
<property name="resizable">
<bool>true</bool>
</property>
</column>
<column>
<property name="text">
<string>UID</string>
</property>
<property name="clickable">
<bool>true</bool>
</property>
<property name="resizable">
<bool>true</bool>
</property>
</column>
<column>
<property name="text">
<string>GID</string>
</property>
<property name="clickable">
<bool>true</bool>
</property>
<property name="resizable">
<bool>true</bool>
</property>
</column>
<property name="name">
<cstring>filelist</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>240</width>
<height>250</height>
</rect>
</property>
<property name="selectionMode">
<enum>Extended</enum>
</property>
<property name="allColumnsShowFocus">
<bool>true</bool>
</property>
<property name="showSortIndicator">
<bool>true</bool>
</property>
</widget>
</widget>
<widget class="QWidget">
<property name="name">
<cstring>camera</cstring>
</property>
<attribute name="title">
<string>Camera</string>
</attribute>
<widget class="QLabel">
<property name="name">
<cstring>textLabel6</cstring>
</property>
<property name="geometry">
<rect>
<x>8</x>
<y>3</y>
<width>64</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Video:</string>
</property>
</widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>/dev/dsp</string>
</property>
</item>
<property name="name">
<cstring>comboBox13</cstring>
</property>
<property name="geometry">
<rect>
<x>88</x>
<y>33</y>
<width>140</width>
<height>27</height>
</rect>
</property>
<property name="editable">
<bool>true</bool>
</property>
</widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>/dev/video</string>
</property>
</item>
<property name="name">
<cstring>comboBox12</cstring>
</property>
<property name="geometry">
<rect>
<x>88</x>
<y>3</y>
<width>140</width>
<height>27</height>
</rect>
</property>
<property name="editable">
<bool>true</bool>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>textLabel7</cstring>
</property>
<property name="geometry">
<rect>
<x>8</x>
<y>33</y>
<width>64</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Audio:</string>
</property>
</widget>
<widget class="QPushButton">
<property name="name">
<cstring>mrlPlaylist_2</cstring>
</property>
<property name="geometry">
<rect>
<x>80</x>
<y>250</y>
<width>87</width>
<height>30</height>
</rect>
</property>
<property name="text">
<string>Add Playlist</string>
</property>
</widget>
</widget>
<widget class="QWidget">
<property name="name">
<cstring>network</cstring>
</property>
<attribute name="title">
<string>Network</string>
</attribute>
<widget class="QLabel">
<property name="name">
<cstring>protocol</cstring>
</property>
<property name="geometry">
<rect>
<x>8</x>
<y>43</y>
<width>56</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Protocol:</string>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>network</cstring>
</property>
<property name="geometry">
<rect>
<x>8</x>
<y>73</y>
<width>55</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Network:</string>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>mrl</cstring>
</property>
<property name="geometry">
<rect>
<x>10</x>
<y>10</y>
<width>40</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>MRL:</string>
</property>
</widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>udp://@:1234</string>
</property>
</item>
<item>
<property name="text">
<string>rtp://@:1234</string>
</property>
</item>
<item>
<property name="text">
<string>ftp://</string>
</property>
</item>
<item>
<property name="text">
<string>http://</string>
</property>
</item>
<property name="name">
<cstring>comboBox1</cstring>
</property>
<property name="geometry">
<rect>
<x>70</x>
<y>10</y>
<width>160</width>
<height>27</height>
</rect>
</property>
<property name="editable">
<bool>true</bool>
</property>
</widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>IPv4</string>
</property>
</item>
<item>
<property name="text">
<string>IPv6</string>
</property>
</item>
<property name="name">
<cstring>comboBox2</cstring>
</property>
<property name="geometry">
<rect>
<x>70</x>
<y>40</y>
<width>160</width>
<height>27</height>
</rect>
</property>
<property name="editable">
<bool>true</bool>
</property>
</widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>unicast</string>
</property>
</item>
<item>
<property name="text">
<string>multicast</string>
</property>
</item>
<property name="name">
<cstring>comboBox3</cstring>
</property>
<property name="geometry">
<rect>
<x>70</x>
<y>70</y>
<width>160</width>
<height>27</height>
</rect>
</property>
<property name="editable">
<bool>true</bool>
</property>
</widget>
<widget class="QPushButton">
<property name="name">
<cstring>mrlPlaylist</cstring>
</property>
<property name="geometry">
<rect>
<x>70</x>
<y>260</y>
<width>87</width>
<height>30</height>
</rect>
</property>
<property name="text">
<string>Add Playlist</string>
</property>
</widget>
</widget>
<widget class="QWidget">
<property name="name">
<cstring>server</cstring>
</property>
<attribute name="title">
<string>Server</string>
</attribute>
<widget class="QComboBox">
<property name="name">
<cstring>comboBox8</cstring>
</property>
<property name="geometry">
<rect>
<x>90</x>
<y>40</y>
<width>140</width>
<height>27</height>
</rect>
</property>
<property name="editable">
<bool>true</bool>
</property>
</widget>
<widget class="QSpinBox">
<property name="name">
<cstring>spinBox4_2</cstring>
</property>
<property name="geometry">
<rect>
<x>170</x>
<y>190</y>
<width>52</width>
<height>23</height>
</rect>
</property>
<property name="maxValue">
<number>240</number>
</property>
<property name="value">
<number>240</number>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>videocodec_2</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>130</y>
<width>82</width>
<height>20</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>5</hsizetype>
<vsizetype>5</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Video Codec:</string>
</property>
</widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>HuffYuv</string>
</property>
</item>
<property name="name">
<cstring>comboBox5_2</cstring>
</property>
<property name="geometry">
<rect>
<x>90</x>
<y>130</y>
<width>140</width>
<height>27</height>
</rect>
</property>
<property name="editable">
<bool>true</bool>
</property>
</widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>A-Law</string>
</property>
</item>
<property name="name">
<cstring>comboBox4_2</cstring>
</property>
<property name="geometry">
<rect>
<x>90</x>
<y>70</y>
<width>140</width>
<height>27</height>
</rect>
</property>
<property name="editable">
<bool>true</bool>
</property>
</widget>
<widget class="QSpinBox">
<property name="name">
<cstring>spinBox2_2</cstring>
</property>
<property name="geometry">
<rect>
<x>90</x>
<y>160</y>
<width>140</width>
<height>23</height>
</rect>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>textLabel5_3</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>100</y>
<width>80</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Audio bitrate:</string>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>audiocodec_2</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>70</y>
<width>82</width>
<height>20</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy>
<hsizetype>5</hsizetype>
<vsizetype>5</vsizetype>
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>Audio Codec:</string>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>videobitrate_2</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>160</y>
<width>80</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Video bitrate:</string>
</property>
</widget>
<widget class="QSpinBox">
<property name="name">
<cstring>spinBox1_2</cstring>
</property>
<property name="geometry">
<rect>
<x>90</x>
<y>100</y>
<width>140</width>
<height>23</height>
</rect>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>textLabel4_2</cstring>
</property>
<property name="geometry">
<rect>
<x>150</x>
<y>190</y>
<width>16</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>x</string>
</property>
</widget>
<widget class="QSpinBox">
<property name="name">
<cstring>spinBox3_2</cstring>
</property>
<property name="geometry">
<rect>
<x>90</x>
<y>190</y>
<width>52</width>
<height>23</height>
</rect>
</property>
<property name="maxValue">
<number>320</number>
</property>
<property name="value">
<number>320</number>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>textLabel3_2</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>190</y>
<width>69</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Video size:</string>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>textLabel2</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>40</y>
<width>73</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Destination:</string>
</property>
</widget>
<widget class="QLabel">
<property name="name">
<cstring>textLabel1</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>10</y>
<width>64</width>
<height>20</height>
</rect>
</property>
<property name="text">
<string>Method:</string>
</property>
</widget>
<widget class="QComboBox">
<item>
<property name="text">
<string>HTTP</string>
</property>
</item>
<item>
<property name="text">
<string>File</string>
</property>
</item>
<item>
<property name="text">
<string>MMS</string>
</property>
</item>
<item>
<property name="text">
<string>FTP</string>
</property>
</item>
<item>
<property name="text">
<string>UDP</string>
</property>
</item>
<item>
<property name="text">
<string>Transcode</string>
</property>
</item>
<property name="name">
<cstring>method</cstring>
</property>
<property name="geometry">
<rect>
<x>90</x>
<y>10</y>
<width>140</width>
<height>27</height>
</rect>
</property>
<property name="editable">
<bool>true</bool>
</property>
</widget>
</widget>
<widget class="QWidget">
<property name="name">
<cstring>playlst</cstring>
</property>
<attribute name="title">
<string>Playlist</string>
</attribute>
<widget class="QListView">
<column>
<property name="text">
<string>Name</string>
</property>
<property name="clickable">
<bool>true</bool>
</property>
<property name="resizable">
<bool>true</bool>
</property>
</column>
<column>
<property name="text">
<string>Location</string>
</property>
<property name="clickable">
<bool>true</bool>
</property>
<property name="resizable">
<bool>true</bool>
</property>
</column>
<property name="name">
<cstring>listView2</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>240</width>
<height>260</height>
</rect>
</property>
</widget>
<widget class="QPushButton">
<property name="name">
<cstring>Add</cstring>
</property>
<property name="geometry">
<rect>
<x>0</x>
<y>260</y>
<width>87</width>
<height>30</height>
</rect>
</property>
<property name="text">
<string>Add</string>
</property>
</widget>
<widget class="QPushButton">
<property name="name">
<cstring>delete</cstring>
</property>
<property name="geometry">
<rect>
<x>150</x>
<y>260</y>
<width>87</width>
<height>30</height>
</rect>
</property>
<property name="text">
<string>Delete</string>
</property>
</widget>
</widget>
</widget>
</widget>
<toolbars>
</toolbars>
<images>
<image name="image0">
<data format="XPM.GZ" length="2125">789c7dd45773db381007f0777f0a8df7cd73b3215800703279b0d38b1d3bd5c9cd3da090ae929b64cbcedc773ff0bfa012a79cca483f62b1c42e483ed898ecef6e4f361eac5dcdddfc284cc2a1bb9c6cc4c5747afbf73f8fbeadad2b3d499fb69e94eb7fadadefcd2761b27336eb06700a9f5081d760da5c59619c60358e73cc56d9172b4bfc122e57e3872bcbf85e767ac34fe06a8ca7adec32cf3f5a59e6df645779fe17b8296a31ddc12659e6bf5b19f3e9166e57e31e7629839c5fea0985cee397702c7ce1e0af83954e1112dfc3bee8f3fa5ec19d3205fa4be887ead5d85fe42b2b55e5fc1ddc289bf39fc3b634a586b1de4aa936c76b589756b5b083bb72ec8f195cd765ae870f609b66487faee0b6b479fc78b06eaa58448ca3bfbaadc6fa9f66c7c2c0d7834d630aed118ffcc6d7b91e9a678ffd443dd6d62ee7b3705f77d9bb83dbc27a6be1d7b0b28d91faa770b4aae9910ffd726533e6c7f5e89c29ab0af1d80f5f185349bd0b58ebb11fa7629b4a86df8b5d6503fc1836b6d70de6e3faf54e8ffd40ff7cf4d6633ea11f41e9bc3f84eb352a33eeef3eac439de3514fb43694d26ff43fb6c6e7ebf903ec6288522fd61b83ad0af10cee6d57ca7e7c14776d2feb3d1bdc55697be57c27706d55ce3f1777a197f96fe0184c2b2e06f7caba42aeaf3b716bf3f9b6c5ae93fde097625f69d4c39bd9da48fd67e2d039d9df122e9dad65be824dca2ffb85e7516f436565bdb3ecd470b8819def8db885bdcdf723d770088591f5ef648ff99ec3d17685ccafc43e18b97f3e89fbf4825fc09d73b55c8f5be2a85ba9f7b3788c273c2ffbdee6fb8b387bbc7f9f89dbf179e0b26b25f662176ac97f220eb596f5bf157721c8f37b211ecfbf37fffff7fd182676ecd36ff87d0cc7f4edb8e783f47bf88798a3f43de6133e1db2fc98698cc1f1c8539ef1199fa7ff177f88b9e42b9ef382afd3ff9bdfc42cd3f796ef7893b7f8f1fdb3ad629e70e0a7fc8c9ff30b7ec9afa4865fd61cf835bfe16ddee1b7bc9bb4773f261d59f23b7ecf1ff8237fe2cfbccf5fbe67fa21cf572e5871c915d7dcb0fe793da96ac3965b622272e42950a48efaa1f3ab98251dd0211dd1319dd0294d694667744e1752ddf7fe70a04bbaa2392de89a6e68391cf965cd341c4d91b774479b38127e5e73ee12e6d3d6bd3dfdf7e1da7f4582f3d8</data>
</image>
<image name="image1">
<data format="XPM.GZ" length="394">789cd3d7528808f055d0d2e72a2e492cc94c5648ce482c52d04a29cdcdad8c8eb5ade6523234530022230543251d2e253d856405bffcbc54105b19c856360003b0141ac023a6acacac07a630c49431c59431c59431c5942910c3661e567bb1ba0fcd1fc48601aa58ad35170077f34458</data>
</image>
<image name="image2">
<data format="XPM.GZ" length="394">789cd3d7528808f055d0d2e72a2e492cc94c5648ce482c52d04a29cdcdad8c8eb5ade6523234530022230543251d2e253d856405bffcbc54105b19c856360003b0141a20554c190a86ba185961506bcd0500949c444d</data>
</image>
<image name="image3">
<data format="XPM.GZ" length="394">789cd3d7528808f055d0d2e72a2e492cc94c5648ce482c52d04a29cdcdad8c8eb5ade6523234530022230543251d2e253d856405bffcbc54105b19c856360003b0141ac023a60c0430722488110e975a6b2e0024e4439d</data>
</image>
<image name="image4">
<data format="XPM.GZ" length="394">789cd3d7528808f055d0d2e72a2e492cc94c5648ce482c52d04a29cdcdad8c8eb5ade6523234530022230543251d2e253d856405bffcbc54105b19c856360003b0141ac02da6ac8c4d0c591421861045168389a28a4144d1c594891423c60e62dc4c5c18a089d55a73010080284437</data>
</image>
<image name="image5">
<data format="XPM.GZ" length="394">789cd3d7528808f055d0d2e72a2e492cc94c5648ce482c52d04a29cdcdad8c8eb5ade6523234530022230543251d2e253d856405bffcbc54105b19c856360003b0141ac027a6ac0c219551c494b18929631353c626a64c811871f662711fa63f880d0314b15a6b2e007b584458</data>
</image>
</images>
<layoutdefaults spacing="6" margin="11"/>
</UI>
......@@ -9,7 +9,6 @@ SUBDIRS += lua
endif
SOURCES_screensaver = screensaver.c
SOURCES_qte_main = qte_main.cpp
SOURCES_freetype = freetype.c text_renderer.h
SOURCES_win32text = win32text.c
SOURCES_quartztext = quartztext.c text_renderer.h
......
/*****************************************************************************
* qte_main.c : QT Embedded wrapper for gte_main
*****************************************************************************
* Copyright (C) 2003 the VideoLAN team
* $Id$
*
* Authors: Jean-Paul Saman <jpsaman _at_ videolan _dot_ org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
/*****************************************************************************
* Preamble
*****************************************************************************/
extern "C"
{
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <vlc_common.h>
#include <vlc_plugin.h>
}
#include <qapplication.h>
#include <qpainter.h>
extern "C"
{
typedef struct qte_thread_t
{
VLC_COMMON_MEMBERS
QApplication* p_qte_application;
QWidget* p_qte_widget;
bool b_gui_server;
} qte_thread_t;
/*****************************************************************************
* Local prototypes.
*****************************************************************************/
static int Open ( vlc_object_t * );
static void Close ( vlc_object_t * );
static void* QteMain( vlc_object_t * );
/*****************************************************************************
* Local variables (mutex-protected).
*****************************************************************************/
static int i_refcount = 0;
static qte_thread_t * p_qte_main = NULL;
/*****************************************************************************
* Module descriptor
*****************************************************************************/
#define STANDALONE_TEXT N_("Run as standalone Qt/Embedded GUI Server")
#define STANDALONE_LONGTEXT N_("Use this option to run as standalone " \
"Qt/Embedded GUI Server. This option is equivalent to the -qws option " \
"from normal Qt.")
vlc_module_begin ()
set_description( N_("Qt Embedded GUI helper") )
set_capability( "gui-helper", 90 )
add_bool( "qte-guiserver", false, NULL, STANDALONE_TEXT, STANDALONE_LONGTEXT, false )
add_shortcut( "qte" )
set_callbacks( Open, Close )
vlc_module_end ()
} /* extern "C" */
static vlc_mutex_t qte_lock = VLC_STATIC_MUTEX;
/*****************************************************************************
* Open: initialize and create window
*****************************************************************************/
static int Open( vlc_object_t *p_this )
{
vlc_mutex_lock( &qte_lock );
if( i_refcount > 0 )
{
i_refcount++;
vlc_mutex_unlock( &qte_lock );
return VLC_SUCCESS;
}
p_qte_main = (qte_thread_t *) vlc_object_create( p_this, sizeof(qte_thread_t) );
/* Launch the QApplication::exec() thread. It will not return until the
* application is properly initialized, which ensures us thread safety. */
if( vlc_thread_create( p_qte_main, "qte_main", QteMain,
VLC_THREAD_PRIORITY_LOW, true ) )
{
vlc_object_release( p_qte_main );
i_refcount--;
vlc_mutex_unlock( lock );
return VLC_ENOMEM;
}
i_refcount++;
vlc_mutex_unlock( &qte_lock );
vlc_object_attach( p_qte_main, p_this );
msg_Dbg( p_this, "qte_main running" );
return VLC_SUCCESS;
}
/*****************************************************************************
* Close: destroy interface window
*****************************************************************************/
static void Close( vlc_object_t *p_this )
{
vlc_mutex_lock( &qte_lock );
i_refcount--;
if( i_refcount > 0 )
{
vlc_mutex_unlock( lock );
return;
}
p_qte_main->p_qte_application->quit();
/* Cleanup allocated classes. */
delete p_qte_main->p_qte_widget;
delete p_qte_main->p_qte_application;
msg_Dbg( p_this, "Detaching qte_main" );
vlc_object_detach( p_qte_main );
vlc_object_release( p_qte_main );
p_qte_main = NULL;
vlc_mutex_unlock( &qte_lock );
}
/*****************************************************************************
* QteMain: Qt Embedded thread
*****************************************************************************
* this part of the interface is in a separate thread so that we can call
* qte_main() from within it without annoying the rest of the program.
*****************************************************************************/
static void* QteMain( vlc_object_t* p_vlc_obj )
{
qte_thread_t *p_this = (qte_thread_t*)p_vlc_obj;
int i_argc = 1;
int canc = vlc_savecancel ();
p_this->b_gui_server = false;
if( config_GetInt( p_this, "qte-guiserver" ) )
{
msg_Dbg( p_this, "Running as Qt Embedded standalone GuiServer" );
p_this->b_gui_server = true;
}
/* Run as standalone GuiServer or as GuiClient. */
QApplication* pApp = new QApplication(i_argc, NULL,
(p_this->b_gui_server ? (QApplication::GuiServer):(QApplication::GuiClient)) );
if( pApp )
{
p_this->p_qte_application = pApp;
}
QWidget* pWidget = new QWidget(0, _("video") );
if( pWidget )
{
p_this->p_qte_widget = pWidget;
}
/* signal the creation of the window */
p_this->p_qte_application->setMainWidget(p_this->p_qte_widget);
p_this->p_qte_widget->show();
vlc_thread_ready( p_this );
p_this->p_qte_application->exec();
vlc_restorecancel (canc);
return NULL;
}
SUBDIRS = msw qte
SUBDIRS = msw
# Automake forgets to add a proper tag to libtool with Objective-C files.
# Moreocer Libtool should default tag to CC when none is specified but
# obviously does not. Here is a fix for that.
......
SOURCES_qte = \
qte.cpp \
qte.h \
$(NULL)
/*****************************************************************************
* qte.cpp : QT Embedded plugin for vlc
*****************************************************************************
* Copyright (C) 1998-2003 the VideoLAN team
* $Id$
*
* Authors: Gerald Hansink <gerald.hansink@ordina.nl>
* Jean-Paul Saman <jpsaman _at_ videolan _dot_ org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
/*****************************************************************************
* Preamble
*****************************************************************************/
/*****************************************************************************
* notes:
* - written for ipaq, so hardcoded assumptions specific for ipaq...
* - runs full screen
* - no "mouse events" handling
* - etc.
*****************************************************************************/
extern "C"
{
#include <errno.h> /* ENOMEM */
#ifdef HAVE_CONFIG_H
# include "config.h"
#endif
#include <vlc_common.h>
#include <vlc_plugin.h>
#include <vlc_interface.h>
#include <vlc_vout.h>
#ifdef HAVE_MACHINE_PARAM_H
/* BSD */
# include <machine/param.h>
# include <sys/types.h> /* typedef ushort */
# include <sys/ipc.h>
#endif
#ifndef WIN32
# include <netinet/in.h> /* BSD: struct in_addr */
#endif
#ifdef HAVE_SYS_SHM_H
# include <sys/shm.h> /* shmget(), shmctl() */
#endif
} /* extern "C" */
#include <qapplication.h>
#include <qpainter.h>
#ifdef Q_WS_QWS
# define USE_DIRECT_PAINTER
# include <qdirectpainter_qws.h>
# include <qgfxraster_qws.h>
#endif
extern "C"
{
#include "qte.h"
/*****************************************************************************
* Module descriptor
*****************************************************************************/
#define DISPLAY_TEXT N_("QT Embedded display")
#define DISPLAY_LONGTEXT N_( \
"Qt Embedded hardware display to use. " \
"By default VLC will use the value of the DISPLAY environment variable.")
/*****************************************************************************
* Local prototypes
*****************************************************************************/
static int Open ( vlc_object_t * );
static void Close ( vlc_object_t * );
static void Render ( vout_thread_t *, picture_t * );
static void Display ( vout_thread_t *, picture_t * );
static int Manage ( vout_thread_t * );
static int Init ( vout_thread_t * );
static void End ( vout_thread_t * );
static int OpenDisplay ( vout_thread_t * );
static void CloseDisplay( vout_thread_t * );
static int NewPicture ( vout_thread_t *, picture_t * );
static void FreePicture ( vout_thread_t *, picture_t * );
static void ToggleFullScreen ( vout_thread_t * );
static void* RunQtThread( vlc_object_t *p_this );
} /* extern "C" */
/*****************************************************************************
* Exported prototypes
*****************************************************************************/
extern "C"
{
vlc_module_begin ()
set_category( CAT_VIDEO )
set_subcategory( SUBCAT_VIDEO_VOUT )
// add_category_hint( N_("QT Embedded"), NULL )
// add_string( "qte-display", "landscape", NULL, DISPLAY_TEXT, DISPLAY_LONGTEXT)
set_description( N_("QT Embedded video output") )
set_capability( "video output", 70 )
add_shortcut( "qte" )
set_callbacks( Open, Close)
vlc_module_end ()
} /* extern "C" */
/*****************************************************************************
* Seeking function TODO: put this in a generic location !
*****************************************************************************/
static inline void vout_Seek( off_t i_seek )
{
}
/*****************************************************************************
* Open: allocate video thread output method
*****************************************************************************/
static int Open( vlc_object_t *p_this )
{
vout_thread_t * p_vout = (vout_thread_t *)p_this;
/* Allocate structure */
p_vout->p_sys = (struct vout_sys_t*) malloc( sizeof( struct vout_sys_t ) );
if( p_vout->p_sys == NULL )
return( 1 );
p_vout->pf_init = Init;
p_vout->pf_end = End;
p_vout->pf_manage = Manage;
p_vout->pf_render = NULL; //Render;
p_vout->pf_display = Display;
#ifdef NEED_QTE_MAIN
p_vout->p_sys->p_qte_main =
module_need( p_this, "gui-helper", "qte", true );
if( p_vout->p_sys->p_qte_main == NULL )
{
free( p_vout->p_sys );
return VLC_ENOMOD;
}
#endif
if (OpenDisplay(p_vout))
{
msg_Err( p_vout, "Cannot set up qte video output" );
Close(p_this);
return( -1 );
}
return( 0 );
}
/*****************************************************************************
* CloseVideo: destroy Sys video thread output method
*****************************************************************************
* Terminate an output method created by Open
*****************************************************************************/
static void Close ( vlc_object_t *p_this )
{
vout_thread_t * p_vout = (vout_thread_t *)p_this;
msg_Dbg( p_vout, "close" );
if( p_vout->p_sys->p_event )
{
vlc_object_detach( p_vout->p_sys->p_event );
/* Kill RunQtThread */
vlc_object_kill( p_vout->p_sys->p_event );
CloseDisplay(p_vout);
vlc_thread_join( p_vout->p_sys->p_event );
vlc_object_release( p_vout->p_sys->p_event );
}
#ifdef NEED_QTE_MAIN
msg_Dbg( p_vout, "releasing gui-helper" );
module_unneed( p_vout, p_vout->p_sys->p_qte_main );
#endif
free( p_vout->p_sys );
p_vout->p_sys = NULL;
}
/*****************************************************************************
* Init: initialize video thread output method
*****************************************************************************
* This function create the buffers needed by the output thread. It is called
* at the beginning of the thread, but also each time the window is resized.
*****************************************************************************/
static int Init( vout_thread_t *p_vout )
{
int i_index;
picture_t* p_pic;
int dd = QPixmap::defaultDepth();
I_OUTPUTPICTURES = 0;
p_vout->output.i_chroma = (dd == 16) ? VLC_CODEC_RGB16 : VLC_CODEC_RGB32;
p_vout->output.i_rmask = 0xf800;
p_vout->output.i_gmask = 0x07e0;
p_vout->output.i_bmask = 0x001f;
/* All we have is an RGB image with square pixels */
p_vout->output.i_width = p_vout->p_sys->i_width;
p_vout->output.i_height = p_vout->p_sys->i_height;
if( !p_vout->b_fullscreen )
{
p_vout->output.i_aspect = p_vout->output.i_width
* VOUT_ASPECT_FACTOR
/ p_vout->output.i_height;
}
else
{
p_vout->output.i_aspect = p_vout->render.i_aspect;
}
#if 0
msg_Dbg( p_vout, "Init (h=%d,w=%d,aspect=%d)",p_vout->output.i_height,p_vout->output.i_width,p_vout->output.i_aspect );
#endif
/* Try to initialize MAX_DIRECTBUFFERS direct buffers */
while( I_OUTPUTPICTURES < QTE_MAX_DIRECTBUFFERS )
{
p_pic = NULL;
/* Find an empty picture slot */
for( i_index = 0 ; i_index < VOUT_MAX_PICTURES ; i_index++ )
{
if( p_vout->p_picture[ i_index ].i_status == FREE_PICTURE )
{
p_pic = p_vout->p_picture + i_index;
break;
}
}
/* Allocate the picture */
if( p_pic == NULL || NewPicture( p_vout, p_pic ) )
{
break;
}
p_pic->i_status = DESTROYED_PICTURE;
p_pic->i_type = DIRECT_PICTURE;
PP_OUTPUTPICTURE[ I_OUTPUTPICTURES ] = p_pic;
I_OUTPUTPICTURES++;
}
return( 0 );
}
/*****************************************************************************
* Render: render previously calculated output
*****************************************************************************/
static void Render( vout_thread_t *p_vout, picture_t *p_pic )
{
;
}
/*****************************************************************************
* Display: displays previously rendered output
*****************************************************************************
* This function sends the currently rendered image to screen.
*****************************************************************************/
static void Display( vout_thread_t *p_vout, picture_t *p_pic )
{
unsigned int x, y, w, h;
vout_PlacePicture( p_vout, p_vout->output.i_width, p_vout->output.i_height,
&x, &y, &w, &h );
#if 0
msg_Dbg(p_vout, "+qte::Display( p_vout, i_width=%d, i_height=%d, x=%u, y=%u, w=%u, h=%u",
p_vout->output.i_width, p_vout->output.i_height, x, y, w, h );
#endif
if(p_vout->p_sys->p_VideoWidget)
{
// shameless borrowed from opie mediaplayer....
#ifndef USE_DIRECT_PAINTER
msg_Dbg(p_vout, "not using direct painter");
QPainter p(p_vout->p_sys->p_VideoWidget);
/* rotate frame */
int dd = QPixmap::defaultDepth();
int bytes = ( dd == 16 ) ? 2 : 4;
int rw = h, rh = w;
QImage rotatedFrame( rw, rh, bytes << 3 );
ushort* in = (ushort*)p_pic->p_sys->pQImage->bits();
ushort* out = (ushort*)rotatedFrame.bits();
int spl = rotatedFrame.bytesPerLine() / bytes;
for (int x=0; x<h; x++)
{
if ( bytes == 2 )
{
ushort* lout = out++ + (w - 1)*spl;
for (int y=0; y<w; y++)
{
*lout=*in++;
lout-=spl;
}
}
else
{
ulong* lout = ((ulong *)out)++ + (w - 1)*spl;
for (int y=0; y<w; y++)
{
*lout=*((ulong*)in)++;
lout-=spl;
}
}
}
p.drawImage( x, y, rotatedFrame, 0, 0, rw, rh );
#else
QDirectPainter p(p_vout->p_sys->p_VideoWidget);
p.transformOrientation();
// just copy the image to the frame buffer...
memcpy(p.frameBuffer(), (p_pic->p_sys->pQImage->jumpTable())[0], h * p.lineStep());
#endif
}
}
/*****************************************************************************
* Manage: handle Qte events
*****************************************************************************
* This function should be called regularly by video output thread. It manages
* Qte events and allows window resizing. It returns a non null value on
* error.
*****************************************************************************/
static int Manage( vout_thread_t *p_vout )
{
// msg_Dbg( p_vout, "Manage" );
/* Fullscreen change */
if( p_vout->i_changes & VOUT_FULLSCREEN_CHANGE )
{
p_vout->b_fullscreen = ! p_vout->b_fullscreen;
// p_vout->p_sys->b_cursor_autohidden = 0;
// SDL_ShowCursor( p_vout->p_sys->b_cursor &&
// ! p_vout->p_sys->b_cursor_autohidden );
p_vout->i_changes &= ~VOUT_FULLSCREEN_CHANGE;
p_vout->i_changes |= VOUT_SIZE_CHANGE;
}
/*
* Size change
*/
if( p_vout->i_changes & VOUT_SIZE_CHANGE )
{
msg_Dbg( p_vout, "video display resized (%dx%d)",
p_vout->p_sys->i_width, p_vout->p_sys->i_height );
CloseDisplay( p_vout );
OpenDisplay( p_vout );
/* We don't need to signal the vout thread about the size change if
* we can handle rescaling ourselves */
p_vout->i_changes &= ~VOUT_SIZE_CHANGE;
}
/* Pointer change */
// if( ! p_vout->p_sys->b_cursor_autohidden &&
// ( mdate() - p_vout->p_sys->i_lastmoved >
// p_vout->p_sys->i_mouse_hide_timeout ) )
// {
// /* Hide the mouse automatically */
// p_vout->p_sys->b_cursor_autohidden = 1;
// SDL_ShowCursor( 0 );
// }
//
// if( !vlc_object_alive (p_vout->p_libvlc) )
// p_vout->p_sys->bRunning = FALSE;
return 0;
}
/*****************************************************************************
* End: terminate video thread output method
*****************************************************************************
* Destroy the buffers created by vout_Init. It is called at the end of
* the thread, but also each time the window is resized.
*****************************************************************************/
static void End( vout_thread_t *p_vout )
{
int i_index;
/* Free the direct buffers we allocated */
for( i_index = I_OUTPUTPICTURES ; i_index ; )
{
i_index--;
FreePicture( p_vout, PP_OUTPUTPICTURE[ i_index ] );
}
}
/*****************************************************************************
* NewPicture: allocate a picture
*****************************************************************************
* Returns 0 on success, -1 otherwise
*****************************************************************************/
static int NewPicture( vout_thread_t *p_vout, picture_t *p_pic )
{
int dd = QPixmap::defaultDepth();
p_pic->p_sys = (picture_sys_t*) malloc( sizeof( picture_sys_t ) );
if( p_pic->p_sys == NULL )
{
return -1;
}
/* Create the display */
p_pic->p_sys->pQImage = new QImage(p_vout->output.i_width,
p_vout->output.i_height, dd );
if(p_pic->p_sys->pQImage == NULL)
{
return -1;
}
switch( dd )
{
case 8:
p_pic->p->i_pixel_pitch = 1;
break;
case 15:
case 16:
p_pic->p->i_pixel_pitch = 2;
break;
case 24:
case 32:
p_pic->p->i_pixel_pitch = 4;
break;
default:
return( -1 );
}
p_pic->p->p_pixels = (p_pic->p_sys->pQImage->jumpTable())[0];
p_pic->p->i_pitch = p_pic->p_sys->pQImage->bytesPerLine();
p_pic->p->i_lines = p_vout->output.i_height;
p_pic->p->i_visible_lines = p_vout->output.i_height;
p_pic->p->i_visible_pitch =
p_pic->p->i_pixel_pitch * p_vout->output.i_width;
p_pic->i_planes = 1;
return 0;
}
/*****************************************************************************
* FreePicture: destroy a picture allocated with NewPicture
*****************************************************************************/
static void FreePicture( vout_thread_t *p_vout, picture_t *p_pic )
{
delete p_pic->p_sys->pQImage;
}
/*****************************************************************************
* ToggleFullScreen: Enable or disable full screen mode
*****************************************************************************
* This function will switch between fullscreen and window mode.
*
*****************************************************************************/
static void ToggleFullScreen ( vout_thread_t *p_vout )
{
if ( p_vout->b_fullscreen )
p_vout->p_sys->p_VideoWidget->showFullScreen();
else
p_vout->p_sys->p_VideoWidget->showNormal();
p_vout->b_fullscreen = !p_vout->b_fullscreen;
}
/*****************************************************************************
* OpenDisplay: create qte applicaton / window
*****************************************************************************
* Create a window according to video output given size, and set other
* properties according to the display properties.
*****************************************************************************/
static int OpenDisplay( vout_thread_t *p_vout )
{
/* for displaying the vout in a qt window we need the QtApplication */
p_vout->p_sys->p_QApplication = NULL;
p_vout->p_sys->p_VideoWidget = NULL;
p_vout->p_sys->p_event = (event_thread_t*) vlc_object_create( p_vout, sizeof(event_thread_t) );
p_vout->p_sys->p_event->p_vout = p_vout;
/* Initializations */
#if 1 /* FIXME: I need an event queue to handle video output size changes. */
p_vout->b_fullscreen = true;
#endif
/* Set main window's size */
QWidget *desktop = p_vout->p_sys->p_QApplication->desktop();
p_vout->p_sys->i_width = p_vout->b_fullscreen ? desktop->height() :
p_vout->i_window_width;
p_vout->p_sys->i_height = p_vout->b_fullscreen ? desktop->width() :
p_vout->i_window_height;
#if 0 /* FIXME: I need an event queue to handle video output size changes. */
/* Update dimensions */
p_vout->i_changes |= VOUT_SIZE_CHANGE;
p_vout->i_window_width = p_vout->p_sys->i_width;
p_vout->i_window_height = p_vout->p_sys->i_height;
#endif
msg_Dbg( p_vout, "opening display (h=%d,w=%d)",p_vout->p_sys->i_height,p_vout->p_sys->i_width);
/* create thread to exec the qpe application */
if ( vlc_thread_create( p_vout->p_sys->p_event, "QT Embedded Thread",
RunQtThread,
VLC_THREAD_PRIORITY_OUTPUT, true) )
{
msg_Err( p_vout, "cannot create QT Embedded Thread" );
vlc_object_release( p_vout->p_sys->p_event );
p_vout->p_sys->p_event = NULL;
return -1;
}
if( p_vout->p_sys->p_event->b_error )
{
msg_Err( p_vout, "RunQtThread failed" );
return -1;
}
vlc_object_attach( p_vout->p_sys->p_event, p_vout );
msg_Dbg( p_vout, "RunQtThread running" );
// just wait until the crew is complete...
while(p_vout->p_sys->p_VideoWidget == NULL)
{
msleep(1);
}
return VLC_SUCCESS;
}
/*****************************************************************************
* CloseDisplay: destroy the window
*****************************************************************************/
static void CloseDisplay( vout_thread_t *p_vout )
{
// quit qt application loop
msg_Dbg( p_vout, "destroying Qt Window" );
#ifdef NEED_QTE_MAIN
if(p_vout->p_sys->p_QApplication)
{
p_vout->p_sys->bRunning = FALSE;
while(p_vout->p_sys->p_VideoWidget)
{
msleep(1);
}
}
#else
if (p_vout->p_sys->p_QApplication)
p_vout->p_sys->p_QApplication->quit();
#endif
}
/*****************************************************************************
* main loop of qtapplication
*****************************************************************************/
static void* RunQtThread( vlc_object_t *p_this )
{
event_thread_t *p_event = (event_thread_t *)p_this;
int canc = vlc_savecancel ();
msg_Dbg( p_event->p_vout, "RunQtThread starting" );
#ifdef NEED_QTE_MAIN
if (qApp)
{
p_event->p_vout->p_sys->p_QApplication = qApp;
p_event->p_vout->p_sys->bOwnsQApp = FALSE;
p_event->p_vout->p_sys->p_VideoWidget = qApp->mainWidget();
msg_Dbg( p_event->p_vout, "RunQtThread applicaton attached" );
}
#else
if (qApp==NULL)
{
int argc = 0;
QApplication* pApp = new QApplication(argc, NULL);
if(pApp)
{
p_event->p_vout->p_sys->p_QApplication = pApp;
p_event->p_vout->p_sys->bOwnsQApp = TRUE;
}
QWidget* pWidget = new QWidget();
if (pWidget)
{
p_event->p_vout->p_sys->p_VideoWidget = pWidget;
}
}
#endif
/* signal the creation of the window */
vlc_thread_ready( p_event );
msg_Dbg( p_event->p_vout, "RunQtThread ready" );
if (p_event->p_vout->p_sys->p_QApplication)
{
/* Set default window width and heigh to exactly preferred size. */
QWidget *desktop = p_event->p_vout->p_sys->p_QApplication->desktop();
p_event->p_vout->p_sys->p_VideoWidget->setMinimumWidth( 10 );
p_event->p_vout->p_sys->p_VideoWidget->setMinimumHeight( 10 );
p_event->p_vout->p_sys->p_VideoWidget->setBaseSize( p_event->p_vout->p_sys->i_width,
p_event->p_vout->p_sys->i_height );
p_event->p_vout->p_sys->p_VideoWidget->setMaximumWidth( desktop->width() );
p_event->p_vout->p_sys->p_VideoWidget->setMaximumHeight( desktop->height() );
/* Check on fullscreen */
if (p_event->p_vout->b_fullscreen)
p_event->p_vout->p_sys->p_VideoWidget->showFullScreen();
else
p_event->p_vout->p_sys->p_VideoWidget->showNormal();
p_event->p_vout->p_sys->p_VideoWidget->show();
p_event->p_vout->p_sys->bRunning = TRUE;
#ifdef NEED_QTE_MAIN
while(vlc_object_alive (p_event) && p_event->p_vout->p_sys->bRunning)
{
/* Check if we are asked to exit */
if( !vlc_object_alive (p_event) )
break;
msleep(100);
}
#else
// run the main loop of qtapplication until someone says: 'quit'
p_event->p_vout->p_sys->pcQApplication->exec();
#endif
}
#ifndef NEED_QTE_MAIN
if(p_event->p_vout->p_sys->p_QApplication)
{
delete p_event->p_vout->p_sys->p_VideoWidget;
p_event->p_vout->p_sys->p_VideoWidget = NULL;
delete p_event->p_vout->p_sys->p_QApplication;
p_event->p_vout->p_sys->p_QApplication = NULL;
}
#else
p_event->p_vout->p_sys->p_VideoWidget = NULL;
#endif
msg_Dbg( p_event->p_vout, "RunQtThread terminating" );
vlc_restorecancel (canc);
return NULL;
}
/*****************************************************************************
* qte.h : QT Embedded plugin for vlc
*****************************************************************************
* Copyright (C) 1998-2002 the VideoLAN team
* $Id$
*
* Authors: Gerald Hansink <gerald.hansink@ordina.nl>
* Jean-Paul Saman <jpsaman _at_ videolan _dot_ org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
/*****************************************************************************
* Preamble
*****************************************************************************/
/*****************************************************************************
* event_thread_t: QT Embedded event thread
*****************************************************************************/
typedef struct event_thread_t
{
VLC_COMMON_MEMBERS
vout_thread_t * p_vout;
} event_thread_t;
/*****************************************************************************
* vout_sys_t: video output method descriptor
*****************************************************************************
* This structure is part of the video output thread descriptor.
* It describes the specific properties of an video output plugin
*****************************************************************************/
struct vout_sys_t
{
/* Internal settings and properties */
int i_width;
int i_height;
bool bRunning;
bool bOwnsQApp;
#ifdef NEED_QTE_MAIN
module_t * p_qte_main;
#endif
QApplication* p_QApplication;
QWidget* p_VideoWidget;
event_thread_t * p_event;
};
/*****************************************************************************
* picture_sys_t: direct buffer method descriptor
*****************************************************************************/
struct picture_sys_t
{
QImage* pQImage;
};
/*****************************************************************************
* Chroma defines
*****************************************************************************/
#define QTE_MAX_DIRECTBUFFERS 2
......@@ -1020,7 +1020,6 @@ modules/misc/playlist/html.c
modules/misc/playlist/m3u.c
modules/misc/playlist/xspf.c
modules/misc/playlist/xspf.h
modules/misc/qte_main.cpp
modules/misc/quartztext.c
modules/misc/rtsp.c
modules/misc/screensaver.c
......@@ -1208,8 +1207,6 @@ modules/video_output/msw/wingdi.c
modules/video_output/omapfb.c
modules/video_output/opengl.c
modules/video_output/opengllayer.m
modules/video_output/qte/qte.cpp
modules/video_output/qte/qte.h
modules/video_output/sdl.c
modules/video_output/snapshot.c
modules/video_output/svgalib.c
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment