How to fix the upside down webcam problem in linux

Thanks to this post, i had been suffering from this problem since a year.

A Quick How to:
In terminal, type

sudo apt-get install aptitute
sudo add-apt-repository ppa:libv4l
sudo aptitude update
sudo aptitude install gtk-v4l
sudo aptitude install libv4l-0

Now, locate the file using this command:

locate v4l1compat.so

copy the output, for my case it was,

/usr/lib/i386-linux-gnu/libv4l/v4l1compat.so

For ubuntu 64 bit, the output could be,

/usr/lib/i386-linux-gnu/libv4l/v4l1compat.so
/usr/lib32/i386-linux-gnu/libv4l/v4l1compat.so

For ubuntu 32 bit, type

sudo su
echo -e '#!/bin/sh\nLD_PRELOAD=/usr/lib/i386-linux-gnu/libv4l/v4l1compat.so $1\nexit 0' > /bin/webcamWrapper
chmod +x /bin/webcamWrapper
exit

IMPORTANT: check if the PRELOAD path is same as what you had in the output of the locate command, if not, change it accoudingly.

Now run skype or any other app which uses the webcam using the following command from the termial:

webcamWrapper skype
webcamWrapper vlc

For ubuntu 64 bit, type

sudo su
echo -e '#!/bin/sh\nLD_PRELOAD=/usr/lib/i386-linux-gnu/libv4l/v4l1compat.so $1\nexit 0' > /bin/webcamWrapper
echo -e '#!/bin/sh\nLD_PRELOAD=/usr/lib32/i386-linux-gnu/libv4l/v4l1compat.so $1\nexit 0' > /bin/webcamWrapper32
chmod +x /bin/webcamWrapper
chmod +x /bin/webcamWrapper32
exit

IMPORTANT: check if the PRELOAD path is same as what you had in the output of the locate command, if not, change it accoudingly.

Now run skype or any other app which uses the webcam using the following command from the termial:

webcamWrapper32 skype
webcamWrapper amsn

This was a problem specially with the asus laptops. With this fix, the only problem is, the terminal has to be kept running, until the application runs. If termial is closed, the apllication will be closed too.
So, creating ta launcher script might easily solve the problem. But i don’t know how, as i am only a beginner. Maybe, one day i will learn how to.

3 responses to “How to fix the upside down webcam problem in linux

  1. Pingback: [solved] Webcam Upside down problem in Skype Ubuntu | Quak Quaks of the Ugly Duckling·

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s