]> icculus.org git repositories - taylor/freespace2.git/blob - src/movie/movie.cpp
Preliminary MVE code (Where's the soup now?!)
[taylor/freespace2.git] / src / movie / movie.cpp
1 #include <stdio.h>
2 #include "mvelib.h"
3 #include "mve_audio.h"
4
5 extern void initializeMovie(MVESTREAM *mve);
6 extern void playMovie(MVESTREAM *mve);
7 extern void shutdownMovie(MVESTREAM *mve);
8
9 int movie_play(char *filename, int unknown)
10 {
11         fprintf (stderr, "Playing MVE file %s\n",filename);
12 #ifdef MVE
13         char file[200];
14         snprintf (file, 200, "movies/%s", filename);
15         MVESTREAM *mve = mve_open(file);
16         if (mve == NULL)
17         {
18                 fprintf(stderr, "can't open MVE file '%s'\n", file);
19                 return -1;
20         }
21
22         initializeMovie(mve);
23         playMovie(mve);
24         shutdownMovie(mve);
25
26         mve_close(mve);
27 #else
28         fprintf(stderr, "STUB: if movie support existed, you'd be watching %s\n", filename);
29 #endif
30         return 1;
31 }
32
33 int movie_play_two(char *filename1, char *filename2)
34 {
35         fprintf(stderr, "STUB: if movie support existed, you'd be watching %s, followed by %s\n", filename1, filename2);        
36
37         return 1;
38 }