I'm trying to open a namedWindow using openCV in raspberry pi but it freezes after cv2.namedWindow("image")line. However, the project works in Windows. Before it freezes it prints the following warnings:

(python3:959): GLib-GObject-WARNING **: 16:34:34.421: cannot register existing type 'GdkDisplayManager'

(python3:959): GLib-CRITICAL **: 16:34:34.421: g_once_init_leave: assertion 'result != 0' failed

(python3:959): GLib-GObject-CRITICAL **: 16:34:34.421: g_object_new_with_properties: assertion 'G_TYPE_IS_OBJECT (object_type)' failed
  • Are you sure that cv2.namedWindow("image") is enough to reproduce the problem? On an unrelated note, raspberry-pi-desktop doesn't run on RPi 4, it's a PC/Mac OS. You probably mean raspbian. – Dmitry Grigoryev Jul 8 '19 at 13:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.