Add RecorderMutex

This commit is contained in:
2023-03-16 13:41:53 +01:00
parent cacf6cfdca
commit 59f4409ab4
19 changed files with 233 additions and 35 deletions
+3 -1
View File
@@ -1,4 +1,5 @@
#include "API/WebAPI.h"
#include "Util/RecorderMutex.h"
#include <ctpl_stl.h>
#include <INIReader.h>
#include <Logging.h>
@@ -41,7 +42,8 @@ int main(int argc, char** argv)
ctpl::thread_pool threadPool(6);
Http::HttpClient httpClient;
Http::HttpServer::CallbackMethod callback = std::bind(&CameraRecorder::API::WebAPI::ProcessQuery, &threadPool, &httpClient, path.str(), ffmpeg, std::placeholders::_1, std::placeholders::_2);
CameraRecorder::Util::RecorderMutex recorderMutex;
Http::HttpServer::CallbackMethod callback = std::bind(&CameraRecorder::API::WebAPI::ProcessQuery, &threadPool, &httpClient, &recorderMutex, path.str(), ffmpeg, std::placeholders::_1, std::placeholders::_2);
Http::HttpServer server(port, callback);
Logging::Log(Logging::Severity::Info, "Startup Complete");