GNOME Bugzilla – Bug 685655
opencv: added OpenCV-based hand gesture detection plugin
Last modified: 2014-11-17 09:25:18 UTC
Created attachment 225985 [details] source codes of the hand detection plugin This plugin uses OpenCV to deploy natural hand gesture detections for operations of multimedia playbacks, i.e. using a fist gesture to control the position of media playback or a closed palm to stop media playing. This plugin has implemented the detection of two hand gestures - fist and closed palm. When the gesture is detected, a message is sent to main bus, and a simulated mouse event is sent upstream. In the future when Gstreamer core is updated with hand gesture upstream events, this plugin will use the new event routine for navigation. This plugin can be reached in github in https://github.com/yandol/GstHanddetect.
Any chance you could port it to 1.0 ?
ready to port this plugin to 1.0, but will have a double-check before that.
Hi Andol, happy to see this here :).. please have a look through the opencv plugins which are already ported to 1.0 in git master..It won't be difficult for you to port handdetect to 1.0 ... Anyway congrats for the Gsoc-project completion...
I have ported it to 1.0 . It is just a basic port to make it work with 1.0 ,since the plugin needs few more fixes and some more proper structuring.(I can do it later when i get time or someone else can do :)..) But i think nothing is preventing to push it to plugins-bad. --plugin ported to 1.0 --example is working fine, which is added to plugins-bad/test/examples (renamed to gsthanddtect_test.c) --fist.xml and palm.xml are installing to OPENCV_PREFIX/share/opencv/haarcascades. Attaching 2 patches.
Created attachment 234554 [details] [review] opencv: Add handdetect plugin, Initial implementation.
Created attachment 234555 [details] [review] opencv: port handdtect plugin to 1.0.
Hi, what's the source of the fist.xml and palm.xml files? Do they really need to ship with the plugin and be installed by us? If so, it seems wrong to install them into an opencv path. Either opencv ships this, then we should require it and error out if the files needed aren't there, or we install them into our ownprefix. Please also make sure all .c and .h files contain proper licenses. I believe the example doesn't have a proper license header.
Hi Tim, Yup we have to install it into our own prefix then since palm.xml and fist.xml are not from opencv. Andol's main task in gsoc was to create those palm.xml and fist.xml which was a time consuming process. Actually i was thinking to install it to gstreamer prefix then changed my mind :)..Will update that(not now..).. Thanks..
Hi Tim, Can i add AS_AC_EXPAND(DATADIR, $datadir) AC_DEFINE_UNQUOTED(GST_DATADIR, "$DATADIR", [data dir]) to plugins-bad configure.ac?? (to get the $datadir path in gsthanddetect.c) or at least I need the prefix var. So that i can add something like, #define HAAR_CASCADES_DIR GST_PREFIX "/share/gstreamer-"GST_API_VERSION"/opencv_haarcascades to gsthanddetect.
Created attachment 234822 [details] [review] opencv: port handdtect plugin to 1.0
It would be good if you can change the "Version" from 0.10.x to git.
Is there any major issue which is preventing this to push ???
No major issues :) Pushed now, many thanks! commit dec865b2ff4a68b5d63d104f3c8f33f9c37e1219 Author: Tim-Philipp Müller <tim@centricular.net> Date: Fri Mar 1 00:10:46 2013 +0000 opencv: use pkgdatadir locally to construct path for custom haar cascades https://bugzilla.gnome.org/show_bug.cgi?id=685655 commit 757e7c25bfe6479eafbca72643662903614d696c Author: Sreerenj Balachandran <sreerenj.balachandran@intel.com> Date: Wed Jan 30 14:37:18 2013 +0200 opencv: port handdetect element to 1.0 and add to build https://bugzilla.gnome.org/show_bug.cgi?id=685655 commit 7faa44057e0802fc5a98eda8798cb0e0a42a1972 Author: Andol Li <andol@andol.info> Date: Sun Jan 27 19:05:27 2013 +0200 opencv: add handdetect plugin, initial implementation The handdetect plugin is for detecting hand gestures using opencv. It was created in the course of the Google Summer of Code. https://bugzilla.gnome.org/show_bug.cgi?id=685655 Could still use some clean-ups (e.g. property names, split super-long string constants, etc.).
Sreerenj, you added a license to the source code, and when doing that added an GPLv3 header instead of an LGPLv2+ header. Was that on purpose? Could you please relicense your contributions as LGPLv2+ like the rest of GStreamer (by stating so here in the bug)?
(In reply to comment #14) > Sreerenj, you added a license to the source code, and when doing that added an > GPLv3 header instead of an LGPLv2+ header. Was that on purpose? > > Could you please relicense your contributions as LGPLv2+ like the rest of > GStreamer (by stating so here in the bug)? Do you mean the header with in the source code? Most probably I just copied the same header which has been used in other opencv files.. Do you want to change the copyright header message in all ext/opencv/*.{c.h}?
> Do you mean the header with in the source code? Yes. > Most probably I just copied the same header which has been used in other opencv > files.. > Do you want to change the copyright header message in all ext/opencv/*.{c.h}? No, just tests/examples/opencv/
Created attachment 290839 [details] [review] relicense the sample code under LGPLv2+
Comment on attachment 290839 [details] [review] relicense the sample code under LGPLv2+ Thanks! commit b8a2f46a88805ff6f6c48d55c46b964b4aef4495 Author: Sreerenj Balachandran <sreerenj.balachandran@intel.com> Date: Mon Nov 17 11:10:35 2014 +0200 examples: relicense opencv gsthanddetect_test to LGPLv2+ The GPL3 license header was copy'n'pasted from a neighbouring source file by mistake, the original code was not GPL3 licensed, but fell under the default GStreamer license, which is LGPLv2+. https://bugzilla.gnome.org/show_bug.cgi?id=685655