libdecklink: port to windows, add thread and another semaphore