Friday, January 14, 2011

GNOME Outreach Program for Women - week 4

This week was mostly an exploration/learning week.

Releasing a Cheese new version

I learned how to create a Cheese release. The release was 2.91.3 and scheduled for Monday 10, to enter the GNOME 2.91.5 Development Release, scheduled for Wednesday 12. ( http://live.gnome.org/TwoPointNinetyone )

The steps to do this (specific to Cheese) are:

  • Update to last version:
    $ git pull
  • Check that you don't have any modified files:
    $ git status
  • Edit configure.ac and and set the release version in the line:
    AC_INIT(cheese, 2.91.3)
    If libcheese api changed, also change the line:
    CHEESE_LT_VERSION=18.0.0
  • Update the NEWS file:
    $ tools/mantainer.sh -n 2.91.2
    (Use previous version as parameter to see what changed) (I had to change the first line from #!/bin/sh to #!/bin/bash, depends on your system).
  • Tidy up the generated NEWS file, deleting the lines containing translation commits and technical commits intended for developers. Leave only "new feature/fix" commits and group similar commits in single bullet points.
  • Create the tarball:
    $ ./autogen.sh (with your usual flags)
    $ make && make distcheck
  • Upload the tarball (I bumped into some errors here and couldn't create the tarball, so Daniel Siegel uploaded his instead).
    $ scp cheese-2.91.3.tar.gz (user)@master.gnome.org
    Then ssh into master.gnome.org and call install-module.
    $ install-module cheese-2.91.3.tar.gz
  • Tag the new release: (set the tag message to something like "tagged for 2.91.3 release").
    $ git tag -a 2.91.3
    $ git push origin 2.91.3
  • Create the announcement mail and send it to gnome-announce-list and cheese-list:
    $ tools/mantainer.sh -m
  • Update the Cheese website:
    Get gnomeweb-wml from git if you don't have it and run
    $ gnomeweb-wml/projects.gnome.org/cheese/update.pl
    and commit the changes.

Finished! A more generic step by step for releasing is here: http://live.gnome.org/MaintainersCorner/Releasing


The following day I rebuilt Cheese from scratch using jhbuild, skipping gobject-introspection which had some problems, and could finally generate a tarball, so next time I'll be more prepared.

Building Cheese from scratch
  • Remove .la files from /usr/lib if you have any. (http://live.gnome.org/GnomeShell/RemovingLaFiles)
  • $ jhbuild build cheese (my .jhbuildrc file is here: http://pastie.org/1462382 )
  • Get directly from their git repositories these packages:
    • - libcanberra
    • - vala
    • - dconf
    • - clutter-gst
    • - gst-plugins-bad
  • Build and install them. When configuring dconf, use VALAC=/path/to/installed/bin/valac if you installed vala in a different prefix.

This week I also started playing with the idea of creating a new effect, or adding existing effects from frei0r plugins. I looked at frei0r code gallery, especially http://frei0r.dyne.org/gallery?filter=facedetect

I also installed OpenCV and ran the examples. Here is the result for facedetect.cpp :

Cool huh? It also detects two faces at the same time, and even faces using the cheese "stretch" effect!! =P


 (not very "glasses-compatible" tee-hee! x)

Note: the "cheese effect" picture is just that, a picture taken with cheese and then used as input for ./facedetect, it's not the effect already working inside cheese! ;)

Well, we'll see what happens these next weeks, I still have to decide what to focus on, but this effect could be one option.

8 comments:

Mike Sheldon said...

You might be interested in taking a look at the new opencv plugins in gst-plugins-bad, they already include a facedetect element which might make life simpler for you when it comes to cheese integration.

Keep up the good work :)

Anonymous said...

How is it with dark-skinned people? Various commercial webcam packages have been (rightfully, in my opinion) blasted for not testing for this before a release, and i think the open source world can do better :)

MrDaniel said...

Hiya.

Is there a VAPI file available for OpenCV?

Kind regards,

Daniel

Mike Sheldon said...

eqlovelace: OpenCV makes use of Haar cascades for face detection. This relies heavily upon detecting local contrast/intensity changes, which doesn't work terribly well for people with darker skin unless they're very well lit.

However I think that's really something that needs to be addressed by the OpenCV project rather than within Cheese, as it's something that would be beneficial to many sub-projects and is by no means a simple task.

Alexander Shopov said...

I have posted some links to various face detection effects used in Logitech's Quickcam software in the comments to this post:

http://blog.fujii.eti.br/?p=33

Do you believe this can be done for cheese?

Kind regards:
al_shopov

Unknown said...

@Mike cool I din't know that, I will start looking into it these days.

@eqlovelace I know right? :D Here is a guy talking about his direct experience, two million views already http://www.youtube.com/watch?v=t4DT3tQqgRM

But I agree with Mike Sheldon, not that it doesn't interest me, but it sure would take a lot of time to research, implement and test. (Even the testing part would be hard, there is not that many dark-skinned people in Buenos Aires, more like light brown hehe!)

@John I have no idea, are you trying to access OpenCV from vala? Would it be hard to create a .vapi file with the OpenCV exported methods? I never did that from scratch, I don't know if you can pick some methods and use only those, or you have to add each and every one of them to the .vapi file.

Unknown said...

@Alexander Shopov I'll paste your comment here to make it easier:

"Video effects are quite nice.
However there are some things lacking in them, do you know whether someone is working on them?
First is avatars – animated 3d (or 2d) figures that move synchronously with you face.
The second is face accessories – pictures are overlaid on your face.
You can see both here: http://www.youtube.com/watch?v=r7Gn2TyEyHw
The last one is overlaying parts of your face (eyes, mouth) on a picture – video masks.
http://www.youtube.com/watch?v=UNASbm-zXvE

I saw these effects in Logitech’s WebCam Controller software.

Kind regards:
al_shopov"


I just started working these last days trying to add .svg image overlays over cheese video preview, and I plan on testing the OpenCV face detection plugins too. If I succeed, then it can be refined to try and do all that fun stuff you mention. I'd like to have those features too, that's why I chose them over other tasks. Want to help? If you code you are more than welcome to start playing with cheese, and we need .svg graphics too if you have talent designing ;)

Alexander Shopov said...

Sadly I am mainly a Java programmer, plus I am the coordinator of the Bulgarian Gnome translation team and in the following months have other tasks. However the effects are very cool. Keep on the good work.
Kind regards:
al_shopov