diff options
| author | Michael Roitzsch <mroi@users.sourceforge.net> | 2004-03-16 11:43:38 +0000 |
|---|---|---|
| committer | Michael Roitzsch <mroi@users.sourceforge.net> | 2004-03-16 11:43:38 +0000 |
| commit | 50a26e7dabcb36c002f8527c8364c67439adbb11 (patch) | |
| tree | d79ee798b6681d0fc8e8a3c93c845d34cfdb92e4 /src/input/libdvdnav/dvdnav_internal.h | |
| parent | b323267b7a8f5592c66158376a1ce25e2bdfefd5 (diff) | |
| download | xine-lib-50a26e7dabcb36c002f8527c8364c67439adbb11.tar.gz xine-lib-50a26e7dabcb36c002f8527c8364c67439adbb11.tar.bz2 | |
sync to latest libdvdnav
* fixes a menu problem (German RC2 of "Anatomie", chapter menu)
* addresses some compilation problems on Windows
(Could someone try cygwin, mingw builds, please? It should work with the
standalone libdvdnav, but who knows if the integration breaks anything...)
* turns some abort()s into assert(0)s, where we really can try to continue
CVS patchset: 6269
CVS date: 2004/03/16 11:43:38
Diffstat (limited to 'src/input/libdvdnav/dvdnav_internal.h')
| -rw-r--r-- | src/input/libdvdnav/dvdnav_internal.h | 35 |
1 files changed, 29 insertions, 6 deletions
diff --git a/src/input/libdvdnav/dvdnav_internal.h b/src/input/libdvdnav/dvdnav_internal.h index 65a4e0e58..29733ed54 100644 --- a/src/input/libdvdnav/dvdnav_internal.h +++ b/src/input/libdvdnav/dvdnav_internal.h @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: dvdnav_internal.h,v 1.13 2003/05/16 10:22:51 mroi Exp $ + * $Id: dvdnav_internal.h,v 1.14 2004/03/16 11:43:38 mroi Exp $ * */ @@ -33,11 +33,36 @@ #include <unistd.h> #include <limits.h> #include <string.h> + +#ifdef WIN32 + +/* pthread_mutex_* wrapper for win32 */ +#include <windows.h> +#include <process.h> +typedef CRITICAL_SECTION pthread_mutex_t; +#define pthread_mutex_init(a, b) InitializeCriticalSection(a) +#define pthread_mutex_lock(a) EnterCriticalSection(a) +#define pthread_mutex_unlock(a) LeaveCriticalSection(a) +#define pthread_mutex_destroy(a) + +/* replacement gettimeofday implementation */ +#include <sys/timeb.h> +static inline int gettimeofday( struct timeval *tv, void *tz ) +{ + struct timeb t; + ftime( &t ); + tv->tv_sec = t.time; + tv->tv_usec = t.millitm * 1000; + return 0; +} +#include <io.h> /* read() */ +#define lseek64 _lseeki64 + +#else + #include <pthread.h> -#include "dvd_reader.h" -#include "ifo_read.h" -#include "ifo_types.h" +#endif /* WIN32 */ /* Uncomment for VM command tracing */ /* #define TRACE */ @@ -126,8 +151,6 @@ struct dvdnav_s { /* General data */ char path[MAX_PATH_LEN]; /* Path to DVD device/dir */ dvd_file_t *file; /* Currently opened file */ - int open_vtsN; /* The domain and number of the... */ - int open_domain; /* ..currently opened VOB */ /* Position data */ vm_position_t position_next; |
