Page 1 of 1

libvlc.dll(libvlc.lib) include/using problems in VS

Posted: 15 Apr 2014 09:52
by stocki4494
Hi Guys!

I wanted to set up a Visual C++ Project using the libvlc.dll (libvlc.lib) and have encountered problems by doing that.
I actually created a libvlc.lib file by following this instructions: https://wiki.videolan.org/GenerateLibFromDll/
(it's size is 68 KB if neccessary)

now i tried to link it to my Project and the main looks like:

Code: Select all

#include <stdio.h> #include <vlc/vlc.h> int main(){ libvlc_instance_t* inst; libvlc_media_player_t *mp; libvlc_media_t *m; inst = libvlc_new(0, NULL); }
nothing more, so far.

Properties of the Solution:
@Properties->Linker->Input-> "Additional Dependencies": "libvlc.lib"
@Properties->C/C++->Additional Include Directories:
C:\Program Files\VideoLAN\VLC\ (and)
C:\Program Files\VideoLAN\VLC\sdk\include

no compiler problems so far, but as soon as I start the program a console window opens and get an error message:
"The program can't start because libvlc.dll is missing from your computer. Try reinstalling the program to fix the problem"

So I checked wether the dll is available and IT IS. under the vlc installing directory. As I copied it to SYSWOW64 Folder (to add it to other dlls) it crashed again, so I deleted it again from SYSWOW64.

I really do not know, how I can fix that, please, please help me.

Re: libvlc.dll(libvlc.lib) include/using problems in VS

Posted: 15 Apr 2014 11:10
by RSATom
1) libvlc.lib can be downloaded from http://code.google.com/p/vc-libvlc/downloads/list
2) place libvlc.dll, libvlccore.dll and plugins folder near your .exe

Re: libvlc.dll(libvlc.lib) include/using problems in VS

Posted: 15 Apr 2014 14:23
by stocki4494
Thank you for the quick reply.

I put these 3 files now in the same folder where my .exe is located.
The problem with the dll seems to be fixed, but the program won't start at all.

The Error Message is now: The aaplication was unable to start correctly (0xc000007b). Click OK to close the Application"

Re: libvlc.dll(libvlc.lib) include/using problems in VS

Posted: 15 Apr 2014 15:32
by RSATom
did you build you application as x86 (32 bit) application?

Re: libvlc.dll(libvlc.lib) include/using problems in VS

Posted: 15 Apr 2014 15:34
by RSATom
you could try to find missing dlls with Dependency Walker