2 * This file is part of MPlayer.
4 * MPlayer is free software; you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation; either version 2 of the License, or
7 * (at your option) any later version.
9 * MPlayer is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License along
15 * with MPlayer; if not, write to the Free Software Foundation, Inc.,
16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
19 #ifndef MPLAYER_GUI_INTERFACE_H
20 #define MPLAYER_GUI_INTERFACE_H
23 #include "mplayer/play.h"
24 #include "libvo/font_load.h"
28 #include "stream/stream.h"
43 } guiUnknownErrorStruct
;
63 int nr_of_audio_channels
;
64 stream_language_t audio_streams
[32];
66 stream_language_t subtitles
[32];
73 guiResizeStruct resize
;
74 guiVideoStruct videodata
;
75 guiUnknownErrorStruct error
;
77 struct MPContext
* mpcontext
;
127 int AudioFileChanged
;
132 extern guiInterface_t guiIntfStruct
;
138 #define guiSetFileName 4
139 #define guiSetState 5
140 #define guiSetAudioOnly 6
141 #define guiReDrawSubWindow 7
142 #define guiSetShVideo 8
143 #define guiSetStream 9
145 #define guiSetVolume 11
146 #define guiSetDefaults 12
147 #define guiSetValues 13
148 #define guiSetFileFormat 14
149 #define guiSetDemuxer 15
150 #define guiSetParameters 16
151 #define guiSetAfilter 17
152 #define guiSetContext 18
156 #define guiSetPause 2
160 #define guiFilenames 4
161 #define guiALL 0xffffffff
165 void guiInit( void );
166 void guiDone( void );
167 int guiGetEvent( int type
,char * arg
);
168 void guiEventHandling( void );
169 void guiLoadFont( void );
170 void guiLoadSubtitle( char * name
);
171 void guiMessageBox(int level
, char * str
);
173 typedef struct plItem
175 struct plItem
* prev
,* next
;
181 typedef struct urlItem
183 struct urlItem
*next
;
187 extern plItem
* plList
;
188 extern plItem
* plCurrent
;
189 extern plItem
* plLastPlayed
;
191 extern URLItem
* URLList
;
193 #define fsPersistant_MaxPath 512
194 #define fsPersistant_MaxPos 5
195 extern char * fsHistory
[fsPersistant_MaxPos
];
197 #define gtkSetContrast 0
198 #define gtkSetBrightness 1
200 #define gtkSetSaturation 3
201 #define gtkSetEqualizer 4
202 #define gtkAddPlItem 5
203 #define gtkGetNextPlItem 6
204 #define gtkGetPrevPlItem 7
205 #define gtkGetCurrPlItem 8
207 #define gtkSetExtraStereo 10
208 #define gtkSetPanscan 11
209 #define gtkSetFontFactor 12
210 #define gtkSetAutoq 13
211 #define gtkClearStruct 14
212 #define gtkAddURLItem 15
213 #define gtkSetFontOutLine 16
214 #define gtkSetFontBlur 17
215 #define gtkSetFontTextScale 18
216 #define gtkSetFontOSDScale 19
217 #define gtkSetFontEncoding 20
218 #define gtkSetFontAutoScale 21
219 #define gtkSetSubEncoding 22
220 #define gtkDelCurrPlItem 23
221 #define gtkInsertPlItem 24
222 #define gtkSetCurrPlItem 25
224 extern float gtkEquChannels
[6][10];
226 void * gtkSet( int cmd
, float param
, void * vparam
);
228 char * gstrdup( const char * str
);
229 int gstrcmp( const char * a
, const char * b
);
230 void gfree( void ** p
);
231 void gaddlist( char *** list
, const char * entry
);
232 char * gstrchr( char * str
, int c
);
234 #define guiSetFilename( s,n ) { gfree( (void **)&s ); s=gstrdup( n ); }
236 #define guiSetDF( s,d,n ) \
238 gfree( (void **)&s ); \
239 s=malloc( strlen( d ) + strlen( n ) + 5 ); \
240 sprintf( s,"%s/%s",d,n ); \
243 #endif /* MPLAYER_GUI_INTERFACE_H */