[GnomeMeeting-devel-list] V4L device detection
- From: PUYDT Julien <julien puydt laposte net>
- To: GnomeMeeting Devel Liste <gnomemeeting-devel-list gnome org>
- Subject: [GnomeMeeting-devel-list] V4L device detection
- Date: Thu, 12 Feb 2004 09:05:50 +0100
Hi,
this is a hack to make it possible for the V4L plugin to detect the
devices each time refresh is clicked.
It fixes the following problem:
* start gm with your webcam;
* your webcam is in the list;
* disconnect your webcam (or remove its driver from the kernel);
* refresh
* the webcam is still here!
I call it a hack because it makes the detection do things it wasn't
designed to do. I think that would need a clean rewrite.
Snark
diff -ur pwlib-cvs-20040210.CVS/plugins/vidinput_v4l/vidinput_v4l.cxx pwlib-cvs-20040210.CVS.patched/plugins/vidinput_v4l/vidinput_v4l.cxx
--- pwlib-cvs-20040210.CVS/plugins/vidinput_v4l/vidinput_v4l.cxx 2004-02-06 23:24:08.000000000 +0100
+++ pwlib-cvs-20040210.CVS.patched/plugins/vidinput_v4l/vidinput_v4l.cxx 2004-02-12 08:51:22.000000000 +0100
@@ -338,6 +338,7 @@
PString entry;
PStringList devlist;
+ inputDeviceNames.RemoveAll (); // flush the previous run
if (procvideo.Exists()) {
if (procvideo.Open(PFileInfo::RegularFile)) {
do {
@@ -500,8 +501,8 @@
{
PWaitAndSignal m(mutex);
PStringList result;
- for (PINDEX i = 0; i < userKey.GetSize(); i++)
- result += userKey.GetKeyAt(i);
+ for (PINDEX i = 0; i < inputDeviceNames.GetSize(); i++)
+ result += GetUserFriendly (inputDeviceNames[i]);
return result;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]