I've been trying to use FFmpeg for video compression and other tasks, but I've been stuck for a while. Up until now, I've mostly avoided linking and have only worked with header-only libraries, so I'm not very familiar with CMake or how CLion handles code execution.
Linking the import libraries (.lib files) only tells the linker that the contained symbols need to be imported from the respective DLL files at runtime. So, if, at runtime, you get error 0xC0000135, it indicates that at least one required DLL could not be loaded by the OS loader!
Also, be aware that not only the "main" EXE can have some direct DLL dependencies, but the DLL's themselves may have transitive dependencies on additional DLL's! Use a tool like Dependencies for figure out all direct and indirect dependencies: https://github.com/lucasg/Dependencies