tina fey fakes jobs :)

2009 Linux Kernel Summit

What I am surprise on? Look, a piece of perl script...


2009 Linux Kernel Summit

Hi folks,


       It's time to start kicking off the 2009 Kernel Summit planning


process.  This year, the Kernel Summit will be held in Tokyo, Japan,


on October 18-20, just before the 1st annual Japan Linux Sympsium.


       As in previous years, I've set up a e-mail discussion list for


people who are interested in making suggestions for this year's kernel


summit.  In the probably hopeless attempt to avoid the list address


getting instantly harvested by spammers from all of the LKML archives,


the list submission address and subscription URL can be found by


executing the following perl script:


print "ksummit-" . $AD . "-discuss" . $at . "lists.linux-foundation.org\n";
print "http://lists.linux-foundation.org/mailman/listinfo/ksummit-" . $AD . "-discuss\n";

This year's program committee is:

       James Bottomley
       Jonathon Corbet
       Dirk Hohndel
       Dave Jones
       Greg Kroah-Hartman
       Chris Mason
       Andrew Morton
       Theodore Ts'o
       Arjan van de Ven

If you have any questions, please feel to contact me or the entire
kernel summit program committee.  Our contact e-mail address can be
found by taking the output from the above perl script and running it
through the command: "sed -e 's/discuss/pc/'".

We'll give people a few days to subscribe before we kick off discussion
on the the new kernel summit mailing list.


                                               - Ted

P.S.  Note that we are aware that given the economic conditions this
year, getting travel funding may be particularly difficult.  For that
reason, we have budgeted extra money for travel scholarships, and we
will be working with various Linux Foundation corporate members who have
historically sent many kernel developers to the Kernel Summit to try to
make sure that everyone who gets an invitation will be able to attend.


how HR/programmer reads your resume


what's twitter?

Why People Seem to Have Free Time

is this a bug in libjpeg source code?

Just for a work task, I need use libjpeg to compress my YUV data into a jpeg file.

I ran "sudo apt-get source libjpeg62" from my Ubuntu and read the code.

I need to set color space parameters into the structure libjpeg needs.

But it seems something wrong here:

354 /*
355  * Select an appropriate JPEG colorspace for in_color_space.
356  */

358 GLOBAL(void)
359 jpeg_default_colorspace (j_compress_ptr cinfo)
360 {
361   switch (cinfo->in_color_space) {
362   case JCS_GRAYSCALE:
363     jpeg_set_colorspace(cinfo, JCS_GRAYSCALE);
364     break;
365   case JCS_RGB:
366     jpeg_set_colorspace(cinfo, JCS_YCbCr);
367     break;
368   case JCS_YCbCr:
369     jpeg_set_colorspace(cinfo, JCS_YCbCr);
370     break;

371   case JCS_CMYK:
372     jpeg_set_colorspace(cinfo, JCS_CMYK); /* By default, no translation */
373     break;
374   case JCS_YCCK:
375     jpeg_set_colorspace(cinfo, JCS_YCCK);
376     break;
377   case JCS_UNKNOWN:
378     jpeg_set_colorspace(cinfo, JCS_UNKNOWN);
379     break;
380   default:
382   }
383 }

Pls red highlight code lines.

I absolutely believe here is a but because they pass same parameter with two different cases.

I can proof by following code of jpeg_set_colorspace().

425   case JCS_RGB:
426     cinfo->write_Adobe_marker = TRUE; /* write Adobe marker to flag RGB */
427     cinfo->num_components = 3;
428     SET_COMP(0, 0x52 /* 'R' */, 1,1, 0, 0,0);
429     SET_COMP(1, 0x47 /* 'G' */, 1,1, 0, 0,0);
430     SET_COMP(2, 0x42 /* 'B' */, 1,1, 0, 0,0);
431     break;
432   case JCS_YCbCr:
433     cinfo->write_JFIF_header = TRUE; /* Write a JFIF marker */
434     cinfo->num_components = 3;
435     /* JFIF specifies component IDs 1,2,3 */
436     /* We default to 2x2 subsamples of chrominance */
437     SET_COMP(0, 1, 2,2, 0, 0,0);
438     SET_COMP(1, 2, 1,1, 1, 1,1);
439     SET_COMP(2, 3, 1,1, 1, 1,1);
440     break;

They use different matrix.

I tried to submit this bug to author but I can't find out his email address.

Wikipedia.org mentioned the libjpeg's profile but no email address.

Developed by Independent JPEG Group
Latest release 6b / 27 March 1998
Written in C
Type library
License Free, can be used in commercial applications without royalty, with acknowledgement.
Website ijg.org

If someone know that pls let me know. If I am wrong pls let me know.

stranger gtk thread issue

For a new task from my job, I need write a GTK application. It's fresh new to me. Yes, I have some years experience on Window$ application development. I have almost used everything of MFC in the past. I guess most UI frameworks are similar. MVC, window,

msg, archive, etc. But at least cocoa is quite different to MFC in something "work style". Just look at sample code of GTK, it is also something different to MFC. Whatever, a new domain is always interesting.


Back to the subject, I wrote a piece of code from scratch. Today, I want to add thread support for more complicated functions.

But I always got a segment fault on g_thread_init(NULL). And I just use a piece of official code from gnome.org it still fails.

main (int argc, char *argv[])
  GtkWidget *window;

  g_thread_init (NULL);
  gdk_threads_init ();
  gtk_init (&argc, &argv);

  window = gtk_window_new (GTK_WINDOW_TOPLEVEL);
  gtk_widget_show (window);

  gdk_threads_enter ();
  gtk_main ();
  gdk_threads_leave ();

  return 0;


My compile command line is easy too.


gcc -o hell hell.c  \
        `pkg-config --cflags --libs gtk+-2.0 gthread`

After many many try and many many failures, I have to look at a large Makefile of another open source software's source code tree. After remove libraries one by one from about thirty libraries, I locate the root cause is --

I need use ghread-2.0 rather than gthread.

arm has dual-core too

shocking on OpenCV

For an internal project, I just study opencv library this night.

Tried to retrieve source code from cvs respository from sf.net but failed as it does not allow anonymous to access it anymore.

Once time I almost gave up it with my mac. i turned on my linux desktop and hope can do it with my ubuntu. But I remember

that my two cameras with OV chip do not work with my ubuntu and I have not tried to fix it.

Back to my mac, i downloaded prebuilt dmg file but have no idea about how to install it. It includes a sample code so call FaceTracking and a OpenCV.framework. After many tries to place framework folder to somewhere, I got it. Just copy

framework folder on a place which FaceTracking also be placed. I compiled it by XCode and run it.

It works excellent. I never expect it work so good like what I see. The main window shows my head which my camera always capturing. and once my face turn to a right angel then the facetracking will recognize my face correctly.

It's so wonderful. I have not been so excited long time.