My current goal is to get this repo, CV-camera-finder, to be compatible with Python 3.10. In the README file, the original publisher says
A simple function to find a connected camera list with media foundation. This is just a modified code of a sample found in https://github.com/Microsoft/Windows-classic-samples/tree/master/Samples/Win7Samples/multimedia/mediafoundation/MFCaptureToFile to use in python.
Download pymf.pyd(32-bit -> file in folder 32, 64-bit -> ...) to your PYTHONPATH to just use it. If you want to modify it, edit cpp files and rebuild it.
My knowledge of Python is intermediate and C++ beginner at best. I downloaded Visual Studio 2022 and attempted to rebuild it myself with no success. I used his cap.cpp and pymf.cpp files, as well as the capture.h files from the referenced Media Foundation samples as I was under the impression based off of includes that I didn't need anything else. I pointed my include of Python.h to the one located in the 3.10 include folders assuming that would fix the problem.
I ran into multiple issues. The first being
unable to open 'python310.lib'
I added an additional library dependency pointing to the 3.10 libs folder. After doing that, here are the errors I am getting now.
LNK2001 unresolved external symbol main
LNK1120 1 unresolved externals
I am clearly over my head with this but I would really like to get this working for Python 3.10. Could anyone provide an steps/advice/tutorials/etc on getting this built and made into a .pyd?