GNOME Bugzilla – Bug 697039
users: taking photo doesn't work
Last modified: 2014-10-15 16:32:58 UTC
when trying to take a photo, I do get the live preview ok, but when I click 'take photo', I am left with a screen-size, all-gray window that doesn't go away.
Are you still facing up the bug? Taking photo works for me great on master.
When I see click on 'Take a Photo' I see flash and than crash. here bt: (gnome-control-center:23068): GLib-GObject-CRITICAL **: g_object_unref: assertion 'G_IS_OBJECT (object)' failed (gnome-control-center:23068): GLib-GObject-WARNING **: invalid uninstantiatable type '(null)' in cast to 'GtkWidget' (gnome-control-center:23068): Gtk-CRITICAL **: gtk_widget_queue_draw: assertion 'GTK_IS_WIDGET (widget)' failed (gnome-control-center:23068): Gtk-CRITICAL **: gtk_widget_get_visible: assertion 'GTK_IS_WIDGET (widget)' failed Program received signal SIGSEGV, Segmentation fault. 0x00007ffff211aaa4 in gtk_widget_verify_invariants (widget=0x2c0c900) at gtkwidget.c:9494 warning: Source file is more recent than executable. 9494 if (widget->priv->verifying_invariants_count > 0) (gdb) bt
+ Trace 233568
Thanks for your bug report. I can reproduce it either. Looks like problem with cheese, however I have recently updated my desktop to Gnome 3.12. I think it was working with Gnome 3.10 properly, unfortunately my virtualized Fedora 20 with Gnome 3.10 doesn't see the webcam. Have you upgraded your Gnome either?
Looks like problem in cheese, changing component... It fails for me with different backtrace (updated Fedora 21 with Gnome 3.12 from copr):
+ Trace 233723
This commit triggers the issue: https://git.gnome.org/browse/cheese/commit/?id=3b3105828787f988c0865e4ef4117d0742f6b527
(In reply to comment #5) > This commit triggers the issue: > https://git.gnome.org/browse/cheese/commit/?id=3b3105828787f988c0865e4ef4117d0742f6b527 Yep, the cheese-camera.c chunk is half-ported.
Created attachment 288542 [details] [review] libcheese: Fix private structure access We were still using CHEESE_CAMERA_GET_PRIVATE() instead of the G_DEFINE_TYPE_WITH_PRIVATE() provided macro. This a regression caused by 3b3105828787f988c0865e4ef4117d0742f6b527
Review of attachment 288542 [details] [review]: Already pushed an identical patch as bf5c9922eb1db09467795047b310e554ba990a38 (and a couple of other cleanups). They do not fix the bug, unfortunately.
The bug is in the um-crop-area changes.
Created attachment 288573 [details] [review] libcheese: Work-around crasher bug
This patch fixes the crash. Now if somebody wants to play spot the bug...
Review of attachment 288573 [details] [review]: Patch seems fine-ish, although it would be good to fix this properly, and I think that I found the underlying cause. The bug itself seems to be that libcheese-gtk exports a um_crop_area_get_type() function, and g-c-c also has the same function for its internal copy. This gets a bit messy, especially when the two objects are different (which was made obvious by the G_DEFINE_TYPE_WITH_PRIVATE rework in Cheese). Putting the Cheese version of UmCropArea into g-c-c does not fix the problem, but renaming one of the two versions does. As the get_type() function is publically visible in libcheese-gtk, changing the name there would be an ABI break, so I will postpone that to next cycle. The next best thing is to rename the UmCropArea in the control center to CcCropArea.
Created attachment 288578 [details] [review] rename UmCropArea to CcCropArea
It seems to me for the first look, UmCropArea in g-c-c is just copy of UmCropArea from cheese. It would be better to synchronize those files or remove it if it is possible. Will have to look at...
Grrr, we need this to crop pictures from file (not from camera). I really don't like this "code sharing".
UmCropArea in Cheese is a copy of the control center code (in 2010, and synced up occasionally after that). Copying the Cheese code back to the control center does not fix the bug. It might be possible to not export the type in libcheese-gtk, but I think that would still confuse GType if the type names were identical. Another option would be to only enable the local copy if Cheese support is disabled, but then Cheese would need to export the complete API rather than just the _get_type() function. Bastien already acked the patch on IRC, but I am waiting on git.gnome.org to be able to push it.
Review of attachment 288578 [details] [review]: Pushed to master and gnome-3-12.