After some improvement, now the error occurs here:<br>                   <br>          /* Create a media player playing environement */<br>          mp = libvlc_media_player_new_from_media (m);<br><br>The program does not continue. <br>
<br>----------------------------------------------------------------------------------------------------------------<br>The following is my test program. <br><br>#include <stdio.h><br>#include <stdlib.h><br>#include <vlc/vlc.h><br>
#include <dir.h> <br>#include <windows.h><br><br>int WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPWSTR lpCmdLine, int nCmdShow)<br>{<br>          <br>          int status; <br>          status = mkdir("/sample/EEv4"); <br>
          <br>          <br>          libvlc_instance_t * inst;<br>          libvlc_media_player_t *mp;<br>          libvlc_media_t *m;<br>           <br>          /* Load the VLC engine */<br>          inst = libvlc_new (0, NULL);<br>
<br>          /* Create a new item */<br>          m = libvlc_media_new_path (inst, "/sample/EEv3.mp4");<br>                   <br>          /* Create a media player playing environement */<br>          mp = libvlc_media_player_new_from_media (m);<br>
          <br>          MessageBoxW(0, L"CREAT ENV SUC!", L"LOG", 0);<br>                   <br>            /* No need to keep the media now */<br>          libvlc_media_release (m);<br> <br> #if 0<br>
     /* This is a non working code that show how to hooks into a window,<br>      * if we have a window around */<br>      libvlc_media_player_set_xdrawable (mp, xdrawable);<br>     /* or on windows */<br>      libvlc_media_player_set_hwnd (mp, hwnd);<br>
     /* or on mac os */<br>      libvlc_media_player_set_nsobject (mp, view);<br>  #endif<br> <br>     /* play the media_player */<br>     libvlc_media_player_play (mp);<br>    <br>     //sleep(1000); /* Let it play a bit */<br>
     //system("pause");<br>     int i=1;<br>     int j=1;<br>     for (i=1;i<10000000;i++){<br>         for (j=1;j<100;j++);<br>     }<br>    <br>     /* Stop playing */<br>     libvlc_media_player_stop (mp);<br>
 <br>     /* Free the media_player */<br>     libvlc_media_player_release (mp);<br>           <br>          libvlc_release (inst);<br>    <br> <br>          return 0; <br>}<br><br><br><br><div class="gmail_quote">2010/8/21 InfoEyes BJ <span dir="ltr"><<a href="mailto:infoeyes2010@gmail.com">infoeyes2010@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">HI, <br><br>I wrote the libvlc invoking program as <br><a href="http://wiki.videolan.org/LibVLC_Tutorial" target="_blank">http://wiki.videolan.org/LibVLC_Tutorial</a><br>
<br>To embed some "printf"-like debug labels, I find that when the program creates a new libvlc instance <br>
<br>          /* Load the VLC engine */<br>          inst = libvlc_new (0, NULL);<br><br>The program is blocked there. I also find that some DLL are called. <br><br>Any help is appreciated!<br><br>Thanks,<br><br>
</blockquote></div><br>