示例#1
0
文件: Smpeg.cs 项目: conankzhang/fez
 public static void SMPEG_double(IntPtr mpeg, int on)
 {
     if (on != 0)
     {
         Smpeg.SMPEG_scale(mpeg, 2);
     }
     else
     {
         Smpeg.SMPEG_scale(mpeg, 1);
     }
 }
示例#2
0
        public void SMPEG_new_rwops()
        {
            this.InitSdl();

            //IntPtr intPtr = Smpeg.SMPEG_new("test.mpg", out info, 0);
            //IntPtr intPtr = Sdl.SDL_RWFromFile("test.mpg", "rb");
            IntPtr intPtr = Smpeg.SMPEG_new_rwops(Sdl.SDL_RWFromFile("../../test.mpg", "rb"), out info, 0);

            Console.WriteLine("Smpeg_error: " + Smpeg.SMPEG_error(intPtr));
            Assert.IsFalse(intPtr == IntPtr.Zero);
            this.Quit();
        }
示例#3
0
        public void SMPEG_play()
        {
            this.InitSdl();

            //IntPtr intPtr = Smpeg.SMPEG_new("test.mpg", out info, 0);
            //IntPtr intPtr = Sdl.SDL_RWFromFile("test.mpg", "rb");
            IntPtr intPtr = Smpeg.SMPEG_new("../../test.mpg", out info, 0);

            Console.WriteLine("Smpeg_error: " + Smpeg.SMPEG_error(intPtr));
            Assert.IsFalse(intPtr == IntPtr.Zero);
            Smpeg.SMPEG_enableaudio(intPtr, 1);
            Smpeg.SMPEG_enablevideo(intPtr, 1);
            Smpeg.SMPEG_setvolume(intPtr, 100);
            Smpeg.SMPEG_setdisplay(intPtr, surfacePtr, IntPtr.Zero, null);

            Smpeg.SMPEG_play(intPtr);
            //while (Smpeg.SMPEG_status(intPtr) == Smpeg.SMPEG_PLAYING){}
            Thread.Sleep(sleepTime);
            Smpeg.SMPEG_stop(intPtr);
            Smpeg.SMPEG_delete(intPtr);
            this.Quit();
        }
示例#4
0
文件: Smpeg.cs 项目: Zeludon/FEZ
 public static void SMPEG_getinfo(IntPtr mpeg, out Smpeg.SMPEG_Info info);
示例#5
0
文件: Smpeg.cs 项目: Zeludon/FEZ
 public static void SMPEG_setdisplay(IntPtr mpeg, IntPtr dst, IntPtr surfLock, Smpeg.SMPEG_DisplayCallback callback);
示例#6
0
文件: Smpeg.cs 项目: Zeludon/FEZ
 public static IntPtr SMPEG_new_rwops(IntPtr src, out Smpeg.SMPEG_Info info, int sdl_audio);
示例#7
0
文件: Smpeg.cs 项目: Zeludon/FEZ
 public static IntPtr SMPEG_new_descr(int file, out Smpeg.SMPEG_Info info, int sdl_audio);
示例#8
0
文件: Smpeg.cs 项目: Zeludon/FEZ
 public static IntPtr SMPEG_new_data(object data, int size, out Smpeg.SMPEG_Info info, int sdl_audio);
示例#9
0
文件: Smpeg.cs 项目: Zeludon/FEZ
 public static IntPtr SMPEG_new(string file, out Smpeg.SMPEG_Info info, int sdl_audio);