2 Copyright 2004-2005 Chris Tallon
4 This file is part of VOMP.
6 VOMP is free software; you can redistribute it and/or modify
7 it under the terms of the GNU General Public License as published by
8 the Free Software Foundation; either version 2 of the License, or
9 (at your option) any later version.
11 VOMP is distributed in the hope that it will be useful,
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 GNU General Public License for more details.
16 You should have received a copy of the GNU General Public License
17 along with VOMP; if not, write to the Free Software
18 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
24 typedef unsigned char UCHAR;
25 typedef unsigned short USHORT;
26 typedef unsigned int UINT;
27 typedef unsigned long ULONG;
28 typedef unsigned long long ULLONG;
30 #define OPTIONTYPE_TEXT 1
31 #define OPTIONTYPE_INT 2
35 //ULLONG htonll(ULLONG a);
36 //ULLONG ntohll(ULLONG a);
37 void MILLISLEEP(ULONG a);
38 long long getTimeMS();
42 #define Surface_TYPE SurfaceWin
43 #define Thread_TYPE ThreadWin
44 #define ThreadID_TYPE unsigned int
46 #define SNPRINTF _snprintf
47 #define VSNPRINTF _vsnprintf
48 #define STRCASECMP _stricmp
49 #define STRCASESTR StrStrI
50 /* #define STRTOULL _strtoui64 */
51 #define STRTOUL strtoul
52 #define CLOSESOCKET closesocket
53 #define DEFAULT_TCP_WINDOWSIZENR 1 /*=2048*/
54 #define PLAYER_MAX_STREAMING_BUFFERS 120 // for video in uints of 50000 KB
63 #define Surface_TYPE SurfaceDirectFB
65 #define Surface_TYPE SurfaceMVP
68 #define Thread_TYPE ThreadPAndroid
71 #define Thread_TYPE ThreadP
75 #define ThreadID_TYPE pthread_t
77 #define SNPRINTF snprintf
78 #define VSNPRINTF vsnprintf
79 #define STRCASECMP strcasecmp
80 #define STRCASESTR strcasestr
81 #define STRTOUL strtoul
82 #define CLOSESOCKET close
84 // add here defines for plattform specific objects
85 #ifdef VOMP_PLATTFORM_RASPBERRY
86 #define Remote_TYPE RemoteLinux // Generic Remote under Linux (Konsole!, not X) will support in the end:
87 #define RemoteStartDev ""//No devices passed
90 // remotes under /dev/event
93 #define Mtd_TYPE MtdRaspberry //this is device dependent
94 #define Led_TYPE LedRaspberry //this is device dependent
95 #define Osd_TYPE OsdOpenVG // This OpenGL ES 2.0, in the moment only for raspberry, but might be splitted for other devices
96 #define OsdStartDev ""
97 #define Audio_TYPE AudioOMX // This is Audio based on OpenMax and libav for decoding
98 #define Video_TYPE VideoOMX // This is Video based on OpenMax
102 #define VPE_OMX_SUPPORT // Activate support for hardware codec using openmax il
103 #define VPE_OMX_H264_DECODER "OMX.broadcom.video_decode"
104 #define VPE_OMX_MPEG2_DECODER "OMX.broadcom.video_decode"
105 #define VPE_OMX_VIDEO_SCHED "OMX.broadcom.video_scheduler"
106 #define VPE_OMX_VIDEO_REND "OMX.broadcom.video_render"
107 #define VPE_OMX_VIDEO_DEINTERLACE "OMX.broadcom.image_fx"
108 #define VPE_OMX_CLOCK "OMX.broadcom.clock"
109 #define VPE_OMX_AUDIO_DECODER "OMX.broadcom.audio_decode"
110 #define VPE_OMX_AUDIO_REND "OMX.broadcom.audio_render"
112 //#define VPE_LIBAV_SUPPORT
113 // #define VPE_LIBAV_MPEG2_TRANSCODING
115 #define DEFAULT_TCP_WINDOWSIZENR 6 /*=2048*/
116 #define PLAYER_MAX_STREAMING_BUFFERS 120 // for video in uints of 50000 KB
117 #define TV_NORM_SWITCHABLE
118 #define HANDLE_VT_SWITCHING
120 #define VOMP_LINUX_CLOCK CLOCK_MONOTONIC
123 #ifdef VOMP_PLATTFORM_MVP
124 #define Remote_TYPE RemoteMVP
125 #define RemoteStartDev "/dev/rawir"
126 #define Mtd_TYPE MtdMVP
127 #define Led_TYPE LedMVP
128 #define Osd_TYPE OsdMVP
129 #define OsdStartDev "/dev/stbgfx"
130 #define Audio_TYPE AudioMVP
131 #define Video_TYPE VideoMVP
132 #define Surface_TYPE SurfaceMVP //deprecated
133 #define DEFAULT_TCP_WINDOWSIZENR 1 /*=2048*/
134 #define PLAYER_MAX_STREAMING_BUFFERS 11 // for video in uints of 50000 KB
136 #define MVP_REMOTE_TYPES
138 #define VOMP_MEDIAPLAYER
139 #define VOMP_LINUX_CLOCK CLOCK_REALTIME
142 #ifdef VOMP_PLATTFORM_NMT // This was the attempt to port vomp to nmt, it failed but maybe the code is useful at some time
143 #define Remote_TYPE RemoteLirc
144 #define RemoteStartDev "/dev/lircd"
145 #define Mtd_TYPE MtdNMT
146 #define Led_TYPE LedMVP
147 #define Osd_TYPE OsdDirectFB
148 #define OsdStartDev ""
149 #define Audio_TYPE AudioNMT
150 #define Video_TYPE VideoNMT
151 #define Surface_TYPE SurfaceDirectFB //deprecated
152 #define DEFAULT_TCP_WINDOWSIZENR 1 /*=2048*/
153 #define PLAYER_MAX_STREAMING_BUFFERS 11 // for video in uints of 50000 KB
155 #define VOMP_LINUX_CLOCK CLOCK_REALTIME
164 UINT id; // Used for working out what has changed at the end
165 char *title; // Name of the option
166 char *configSection; // Which section of the config file
167 char *configParam; // Parameter name in the config file
168 UINT optionType; // 1 for text, 2 for int
169 UINT optionCount; // How many choices?
170 UINT defaultOption; // Serial of the default choice (base 0), or actual option in int mode
171 int startInt; // Starting int for int mode
172 const char * const * options; // Text for the options (null for int mode)