After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 545190 - Cheese does not detect iSight Firewire Camera (as v4l device)
Cheese does not detect iSight Firewire Camera (as v4l device)
Status: RESOLVED NOTGNOME
Product: cheese
Classification: Applications
Component: general
2.22.x
Other All
: Normal major
: ---
Assigned To: Cheese Maintainer(s)
Cheese Maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2008-07-28 16:54 UTC by Rob
Modified: 2008-08-15 00:33 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Rob 2008-07-28 16:54:22 UTC
Please describe the problem:
I have setup my Apple iSight Firewire camera as a v4l device using coriander and vloopback.  The real iSight is at /dev/video1394/0.  vloopback sets /dev/video0 as input and /dev/video1 as output.

I have used gstreamer-properties to set up v4l.  And used "Video loopback 0 output" as the device and "v4l" as the plugin.

The iSight works fine in Ekiga as a v4l device.  

But when I run cheese, my iSight is not detected.  When I run "cheese --verbose" in Terminal,  I do not see any messages.  

I notice that when I run gconf-editor, I see the following under -- apps - cheese:

webcam   CHECK_PATTERN

P.S.  I am running Ubuntu 8.04.1.

So it is not being detected!  Any ideas?

Steps to reproduce:
1. Connect Apple iSight
2. RUn coriander and set v4l to ON in services tab
3. Run gstreamer-properties and set "Video loopback 0 output" as the device and "v4l" as the plugin.
4. Run Cheese.



Actual results:

The webcam  is not detected.

"cheese --verbose" produces no output.

Expected results:
The webcam should be detected.  (It is detected as a v4l device in other apps like Ekiga).

Does this happen every time?
Yes

Other information:
Comment 1 Filippo Argiolas 2008-07-28 20:27:08 UTC
Hi, there should be a bug in 2.22.x that results in empty cheese --verbose logs.
Whould you mind trying to reproduce the bug with the svn version or the latest tarball from gnome ftp (2.23.5), it should output some useful info to better understand what's happening.
Thanks.
Comment 2 Rob 2008-07-31 15:44:37 UTC
I tried to install cheese 2.23.5 on my Ubuntu Hardy Heron Box.  But to get it to work I needed to install some dependencies (most were updates of libraries etc).  I compiled and installed many of the dependencies form  source but then I ran into a roadblock.   cheese 2.23.5 would not compile and complained that I need to install many more dependencies like hal, glibc etc.  But I have hal installed!  

At this stage I gave up.  In my view, Ubuntu is really not a developer's platform (especially for bleeding edge software).  

Unfortunately, my arch linux box is broken now.  If I can get it fixed, I will install the latest version of cheese on it and run "cheese --verbose".  It is so much easier to get bleeding edge software to run under arch.
Comment 3 Filippo Argiolas 2008-07-31 18:27:31 UTC
Hi, it's not that hard to install software from source with ubuntu, you just have to do it in the ubuntu/debian "way". The only needed command should be "sudo apt-get build-dep cheese". It will install all packages needed to build cheese.
If some library is still missing you just have to find the corrispondent -dev package and install it. 
Finally the only thing you will still have to install from source is intltool 0.40 that is not in ubuntu repos yet and you can grab it from gnome ftp (http://ftp.gnome.org/pub/gnome/sources/intltool/0.40/intltool-0.40.3.tar.bz2).
Comment 4 Rob 2008-08-01 12:09:45 UTC
Thanks,  On my first  attempt I did successfully compile from source intltool and install it.  And I started to compile some of the other dependencies but ran into roadblocks.

I will try "sudo apt-get build-dep cheese" and see how that goes.  And you are right.  I am not "debianized" yet.  I am used to compiling code from source.  That is way I like Slackware and Arch so much. 

If you can, please give me a week.  It is a long weekend here in Canada.

Cheers
Rob
Comment 5 Rob 2008-08-01 17:16:36 UTC
I have successfully compiled cheese 2.23.5 on my Ubuntu Hardy Heron box.  The trick was to use "sudo apt-get build-dep cheese" to get the needed missing dependencies.  (As you mentioned before, I also had to compile from source intltool-0.40.3).  Many thanks for getting me over this hurdle.

Unfortunately, I still do not see ANY output when I run "cheese -v" or "cheese --verbose" in Terminal.  The program does run and displays a new message.  "No camera found" at the top of the Cheese window.  (When I click Help-About, I can confirm I am running cheese version 2.23.5).

I exited cheese and tried "camstream".  camstream was able to see my Firewire camera being piped through coriander and vloopback as "video loopback 0 output".  I was able to see myself (but my face was purple).

When I run gstreamer-properties, I see that video is configured as a "v4l" (not v4l2) device with the device being identified as "video loopback 0 output".  When I click TEST, I see myself (but my face is purple again).

I even tried Ekiga.  I was able to use the Firewire iSight as a V4L device  (and the colour of my face was okay!).

So it looks like coriander and vloopback are doing their job and making my iSight Firewire camera into a Video For Linux (v4l) version 1 device.  (But I do not know why some programs display my face as purple as others with the right colour).

But cheese gives me nothing at this time.  I wish I could give you more info.  But "cheese -v" is not providing any.

Rob

Comment 6 Rob 2008-08-01 18:34:29 UTC
I have done some more testing.  I am now starting to get some output when I do a "cheese - v" but it occurs AFTER I QUIT the program.  Here it is:

ubuntu@ubuntu:~$ cheese -v

(cheese:21279): GLib-GObject-CRITICAL **: g_object_unref: assertion `G_IS_OBJECT (object)' failed

(cheese:21279): GLib-GObject-CRITICAL **: g_object_unref: assertion `G_IS_OBJECT (object)' failed


In my view, the real problem is the lack of support for Firewire webcams by many Linux apps.  The hack is to use coriander and vloopback.  But that is not perfect.  Many apps do not properly read the video being piped through coriander and vloopback.  

Ekiga and gqcam are an exception.  They work and I see my face with the right colour.  But the video adjustments in these programs do not work.  I must use the video adjustments in coriander (if I want more brightness etc).  

Motion also works and I see my face with the right colour.

camstream works but my face is purple.  I must use the coriander hue etc controls to adjust.  (The video adjustments in these programs do not work like Ekiga.  I need to use corriander to get my face the right colour).

I think camstream is NOT doing the FGB to BGR Conversion that is needed.  gqcam does this conversion automatically.  When I turn this conversion off in gqcam,  see a purple face!  (FYI -- the settings in gqcam are RGB-BGR conversion and YUV).

Some programs like cheese and vgrabbj do not work at all.  But vgrabbj does provide some output:

 vgrabbj -d /dev/video1
Device doesn't support width/height
Fatal Error (non-daemon), exiting...
There was no map allocated to be freed...
ubuntu@ubuntu:~$ vgrabbj -g -d /dev/video1
Device doesn't support width/height
Fatal Error (non-daemon), exiting...
There was no map allocated to be freed...
ubuntu@ubuntu:~$ vgrabbj -g -G -d /dev/video1
Device doesn't support width/height
Fatal Error (non-daemon), exiting...
There was no map allocated to be freed...
ubuntu@ubuntu:~$ vgrabbj -s /dev/video1
vgrabbj, Version 0.9.6
Videodevice name: /dev/video1 (Video loopback 0 output)
Capabilities
Type     : 1	Values can be looked up at videodev.h
Channels : 1
Audio    : 0
MaxWidth : 320
MaxHeight: 240
MinWidth : 20
MinHeigth: 20

Current Settings:
Brightness: 32768
Hue       : 32768
Color     : 32768
Contrast  : 32768
Whiteness : 32768
Depth     : 32768
Palette   : RGB24 (4)
Width     : 320
Height    : 240
Chromakey : 0

I hope this helps.
Comment 7 Rob 2008-08-01 18:48:47 UTC
I see you have some command line debug options.  Here is the output of "cheese --gst-debug-level=2".

ubuntu@ubuntu:~$ cheese --gst-debug-level=2
0:00:00.727241864 22920 0x8448f80 WARN           xvimagesink xvimagesink.c:1333:gst_xvimagesink_get_xv_support:<autovideosink0-actual-sink-xvimage> error: Could not initialise Xv output
0:00:00.727278042 22920 0x8448f80 WARN           xvimagesink xvimagesink.c:1333:gst_xvimagesink_get_xv_support:<autovideosink0-actual-sink-xvimage> error: No port available

(cheese:22920): GLib-GObject-CRITICAL **: g_object_unref: assertion `G_IS_OBJECT (object)' failed

(cheese:22920): GLib-GObject-CRITICAL **: g_object_unref: assertion `G_IS_OBJECT (object)' failed
ubuntu@ubuntu:~$ 

To get rid of this warning, I ran gstreamer-propertes and changed the Video Default Output Plugin from "Auto Detect" to "X Window System (No Xv)" which changes the pipeline to ximagesink.  Now when I run cheese, I don't see the warnings, cheese runs but still NO webcam.

I also tried changing the Video Default Output Plugin from "Auto Detect" to "X Window System (X11/XShm/Xv)" which would also change the pipeline to xvimagesink. But gstreamer-properties would not let me make this change.  I got this error:  "Could not initialize Xv Ouput".

So it looks like my Linux box only supports No Xv.

I hope this helps.  If there is something else you want me to try, please let me know.

Rob



  
Comment 8 Filippo Argiolas 2008-08-01 21:44:12 UTC
>I have successfully compiled cheese 2.23.5 on my Ubuntu Hardy Heron box.  The
>trick was to use "sudo apt-get build-dep cheese" to get the needed missing
>dependencies.  (As you mentioned before, I also had to compile from source
>intltool-0.40.3).  Many thanks for getting me over this hurdle.
Great ;)! You're welcome

I think your webcam is not working because we query hal for video4linux devices and this uncommon method (coriander + vloopback) that you use to make the device work most probably isn't compatible with hal. What does "hal-find-by-capability --capability video4linux" returns? nothing I suppose..
Are you sure that's the only available way to make your isight camera work?
I did a quick google search and found a couple of tutorials to make it work on ubuntu copying the firmware from the osx partition, extracting it with isight-firmware-tools and loading it with common uvcvideo drivers.
Here's just one of those:
http://ubuntuforums.org/showthread.php?t=764616
But I'm sure there are more detailed ones on the net, I just did a quick search.
Let me know if this helps!
Comment 9 Rob 2008-08-01 23:13:06 UTC
Thanks for the reply.  And you are right, ""hal-find-by-capability --capability video4linux" returns nothing! 

I am not sure whether this is a bug with hal, vloopback or coriander. Where do you think the bug lies? 

Unfortunately, the link you provided is not of much help.  There are two kinds of Apple iSight webcams.  The external iSight FIREWIRE webcams and the internal iSight USB webcams.  Both go under the trade-mark "iSight" which leads to a lot of confusion.  The link you provided deals with the internal iSight USB webcams.

So I am still trying to figure out ho wto get this external iSIght FIREWIRE webcam to work.  Many of the apps do work but some (like Cheese and Skype) do not.

If you have any ideas on how to proceed, please let me know.  Perhaps, I need to file a bug report with vloopback, coriander or hal?



Comment 10 Filippo Argiolas 2008-08-02 06:17:25 UTC
I had some feeling that the one in the tutorial was a different camera, thanks for clarifying.

I'm not sure where the bug lies, it could be the kernel driver failing to create the device correctly or hal failing to handle it. I see you already reported the issue to vloopback.
Please could you also file a bug against hal (https://bugs.freedesktop.org/enter_bug.cgi?product=hal)? 
Attach a tarball of /sys/devices/ content there (tar -czvf sysdev.tar.gz /sys/devices/), explain your issue and feel free to point them to this bug.
If you would also CC me to that new bug that would be great, thanks.

So, closing it as NOTGNOME. Reopen if it turns out that cheese could be involved in this issue.
Comment 11 Rob 2008-08-03 13:44:54 UTC
Yes, I will file a bug against hal (but won't be able to get around to it until next week.  I am not near my Linux box now).  

Getting a Firewire webcam to look like a USB Video4Linux webcam is a REAL hack using coriander and vloopback.  In my view, the best solution is for apps like cheese to directly support Firewire webcams.

Is there a way to request a future enhancement to cheese?

Rob
Comment 12 Filippo Argiolas 2008-08-04 09:20:55 UTC
>In my view, the best solution is for apps like cheese to directly 
>support Firewire webcams.

Userspace hacks to make a device work are usually a bad thing. If you have a firewire webcam device it's up to the kernel to make it work transparently as a video device. Applications should be completely unaware of "what kind of webcam you do have" and just use its v4l/v4l2 device.

If your device works as a video4linux device (no matter how it does, kernel support or vloopback/coriander) hal should advertise its capability. 
This is not a cheese task. Either hal or vloopback or coriander or whoever is the responsible to do this thing should do it.
Comment 13 Rob 2008-08-15 00:33:33 UTC
FYI - I have filed a bug against hal.
(see https://bugs.freedesktop.org/show_bug.cgi?id=17143 )