DLL not found

For the developers that use FFmpeg in Windows software.
Post Reply
FrankNatoli
Posts: 6
Joined: Wed Nov 27, 2013 12:09 am

DLL not found

Post by FrankNatoli » Sat Sep 16, 2017 2:55 am

Writing VS2012 C# application with VS2012 C++ bridge DLL to FFmpeg libraries. Everything links properly. But once I reference an FFmpeg library, e.g., avcodec.lib for avcodec_register_all, C# application reports "DLL not found". But it's not the bridge DLL that's not found. DEPENDS.EXE reports that avcodec-57.dll is not found. Why is this happening? Am linking with avcodec.lib [190,786 bytes]. Why is runtime referencing avcodec-57.dll?

FrameOfReference
Posts: 2
Joined: Fri Sep 15, 2017 2:46 pm

Re: DLL not found

Post by FrameOfReference » Sun Sep 17, 2017 11:50 pm

I have had this problem albeit on nix, make sure that you got the right libs for your target platform, 32/64bit.

FrankNatoli
Posts: 6
Joined: Wed Nov 27, 2013 12:09 am

Re: DLL not found

Post by FrankNatoli » Wed Sep 27, 2017 11:47 pm

I got the LIB files from the same Zeranoe distribution as the DLL files. I put the DLL files in the same folder as the resultant EXE files, so there's no question about "where are the DLLs". Almost certainly, there's a mismatch between the Zeranoe LIB for, say, avcodec.lib and the Zernoe DLL, which should be avcodec-57.dll, but it's impossible to ascertain what.
I've "solved" the problem by using LoadLibrary to pull the DLLs into memory and then GetProcAddress to get the entry points. But it's ridiculous to have to do that.

Post Reply