WaterMark: create water mark plugin

GitLab: #13
Change-Id: Idab3d0b8fdfe6af2b481ac483a5b7ff423bec418
diff --git a/GreenScreen/main.cpp b/GreenScreen/main.cpp
index 3566169..bfc1bc8 100644
--- a/GreenScreen/main.cpp
+++ b/GreenScreen/main.cpp
@@ -44,10 +44,10 @@
 EXPORT_PLUGIN JAMI_PluginExitFunc
 JAMI_dynPluginInit(const JAMI_PluginAPI* api)
 {
-    std::cout << "**************************" << std::endl << std::endl;
+    std::cout << "**************************" << std::endl;
     std::cout << "**  GREENSCREEN PLUGIN  **" << std::endl;
     std::cout << "**************************" << std::endl << std::endl;
-    std::cout << " Version " << GreenScreen_VERSION_MAJOR << "." << GreenScreen_VERSION_MINOR << "."
+    std::cout << "Version " << GreenScreen_VERSION_MAJOR << "." << GreenScreen_VERSION_MINOR << "."
               << GreenScreen_VERSION_PATCH << std::endl;
 
     // If invokeService doesn't return an error
@@ -56,7 +56,8 @@
         api->invokeService(api, "getPluginPreferences", &preferences);
         std::string dataPath;
         api->invokeService(api, "getPluginDataPath", &dataPath);
-        auto fmp = std::make_unique<jami::PluginMediaHandler>(std::move(preferences), std::move(dataPath));
+        auto fmp = std::make_unique<jami::PluginMediaHandler>(std::move(preferences),
+                                                              std::move(dataPath));
 
         if (!api->manageComponent(api, "CallMediaHandlerManager", fmp.release())) {
             return pluginExit;
diff --git a/GreenScreen/videoSubscriber.cpp b/GreenScreen/videoSubscriber.cpp
index 5af29c5..583a5c5 100644
--- a/GreenScreen/videoSubscriber.cpp
+++ b/GreenScreen/videoSubscriber.cpp
@@ -39,7 +39,10 @@
 
 namespace jami {
 
-VideoSubscriber::VideoSubscriber(const std::string& dataPath, const std::string& model, const std::string& backgroundImage, bool acc)
+VideoSubscriber::VideoSubscriber(const std::string& dataPath,
+                                 const std::string& model,
+                                 const std::string& backgroundImage,
+                                 bool acc)
     : path_ {dataPath}
     , pluginProcessor {dataPath, model, backgroundImage, acc}
 {
@@ -78,13 +81,13 @@
 void
 VideoSubscriber::update(jami::Observable<AVFrame*>*, AVFrame* const& pluginFrame)
 {
-    if (!observable_ || !pluginProcessor.isAllocated() || !pluginProcessor.hasBackground() || !pluginFrame)
+    if (!observable_ || !pluginProcessor.isAllocated() || !pluginProcessor.hasBackground()
+        || !pluginFrame)
         return;
 
     //======================================================================================
     // GET FRAME ROTATION
-    AVFrameSideData* side_data = av_frame_get_side_data(pluginFrame,
-                                                        AV_FRAME_DATA_DISPLAYMATRIX);
+    AVFrameSideData* side_data = av_frame_get_side_data(pluginFrame, AV_FRAME_DATA_DISPLAYMATRIX);
 
     int angle {0};
     if (side_data) {
@@ -108,10 +111,10 @@
     if (!bgrFrame)
         return;
     cv::Mat frame = cv::Mat {bgrFrame->height,
-                                bgrFrame->width,
-                                CV_8UC3,
-                                bgrFrame->data[0],
-                                static_cast<size_t>(bgrFrame->linesize[0])};
+                             bgrFrame->width,
+                             CV_8UC3,
+                             bgrFrame->data[0],
+                             static_cast<size_t>(bgrFrame->linesize[0])};
     // First clone the frame as the original one is unusable because of
     // linespace
 
@@ -128,8 +131,8 @@
         pluginProcessor.rotateFrame(angle, fcopy.resizedFrameRGB);
 
         cv::resize(pluginProcessor.backgroundImage,
-                    pluginProcessor.backgroundImage,
-                    fcopy.resizedSize);
+                   pluginProcessor.backgroundImage,
+                   fcopy.resizedSize);
 
         firstRun = false;
     }
@@ -157,12 +160,11 @@
         uint8_t* frameData = bgrFrame->data[0];
         if (angle == 90 || angle == -90) {
             std::memmove(frameData,
-                            fcopy.predictionsFrameRGB.data,
-                            static_cast<size_t>(pluginFrame->width * pluginFrame->height * 3)
-                                * sizeof(uint8_t));
+                         fcopy.predictionsFrameRGB.data,
+                         static_cast<size_t>(pluginFrame->width * pluginFrame->height * 3)
+                             * sizeof(uint8_t));
         }
 
-        av_frame_copy_props(bgrFrame, pluginFrame);
         moveFrom(pluginFrame, bgrFrame);
     }
     av_frame_unref(bgrFrame);