From 6bfd380bc17942dec42165929dd9dc162431e650 Mon Sep 17 00:00:00 2001
From: Joseph Redmon <pjreddie@burninator.cs.washington.edu>
Date: Thu, 23 Jun 2016 04:47:28 +0000
Subject: [PATCH] hi

---
 src/coco_demo.c |   14 +++++++++-----
 1 files changed, 9 insertions(+), 5 deletions(-)

diff --git a/src/coco_demo.c b/src/coco_demo.c
index c516f78..370516d 100644
--- a/src/coco_demo.c
+++ b/src/coco_demo.c
@@ -10,8 +10,8 @@
 #define FRAMES 1
 
 #ifdef OPENCV
-#include "opencv2/highgui/highgui.hpp"
-#include "opencv2/imgproc/imgproc.hpp"
+#include "opencv2/highgui/highgui_c.h"
+#include "opencv2/imgproc/imgproc_c.h"
 void convert_coco_detections(float *predictions, int classes, int num, int square, int side, int w, int h, float thresh, float **probs, box *boxes, int only_objectness);
 
 extern char *coco_classes[];
@@ -87,8 +87,6 @@
     }
 
     if(!cap) error("Couldn't connect to webcam.\n");
-    cvNamedWindow("COCO", CV_WINDOW_NORMAL); 
-    cvResizeWindow("COCO", 512, 512);
 
     detection_layer l = net.layers[net.n-1];
     int j;
@@ -123,16 +121,22 @@
     }
 
     int count = 0;
+    cvNamedWindow("COCO", CV_WINDOW_NORMAL); 
+    cvMoveWindow("COCO", 0, 0);
+    cvResizeWindow("COCO", 1352, 1013);
+
     while(1){
         ++count;
         struct timeval tval_before, tval_after, tval_result;
         gettimeofday(&tval_before, NULL);
         if(pthread_create(&fetch_thread, 0, fetch_in_thread_coco, 0)) error("Thread creation failed");
         if(pthread_create(&detect_thread, 0, detect_in_thread_coco, 0)) error("Thread creation failed");
-        //show_image(disp, "COCO");
+        show_image(disp, "COCO");
+        /*
         char buff[256];
         sprintf(buff, "/home/pjreddie/coco/coco_%05d", count);
         save_image(disp, buff);
+        */
 
         free_image(disp);
         cvWaitKey(10);

--
Gitblit v1.10.0