I just wonder has anybody fixed this issue. I've read all post but found no answers. The problem is: there is a python simple code
import cv2
cam = cv2.VideoCapture(0)
cv2.namedWindow('test', cv2.WINDOW_NORMAL)
while True:
ret, img = cam.read()
if ret:
print img.mean()
cv2.imshow('test', img)
cv2.waitKey(1)
When I run it I see only a window title bar with no content underneath. But frames keep updating that I can see on terminal with img.mean() printout. Since I set cv2.WINDOW_NORMAL I can grab the window corner and drag it and I see the frame content but at this time frames stop updating. When I release the window corner the window collapses back and frames start updating again.
If I use any other image display functions e.g. dlib.image_window() in my case everything works just fine.
I use opencv 3.2.0-dev compiled from sources with opencv_contrib and python 2.7.13 on MacOS
Problem solved
The solution is: in file opencv/modules/highgui/src/window_cocoa.mm change
@implementation CVView
#if defined(__LP64__)
@synthesize image;
#else // 32-bit Obj-C does not have automatic synthesize
@synthesize image = _image;
#endif
to
@implementation CVView
@synthesize image = _image;
The explanation is here
@DanMašek, thanks for your comment that made my life easier )