How do I watch my webcams feed in linux
In windows I can open "My Computer" and click on the "Webcam" icon to get a feed from my webcam. I can also take snapshots of that feed.
Can I do the same in Ubuntu? Without installing any extra applications like Photobooth.
linux ubuntu video
add a comment |
In windows I can open "My Computer" and click on the "Webcam" icon to get a feed from my webcam. I can also take snapshots of that feed.
Can I do the same in Ubuntu? Without installing any extra applications like Photobooth.
linux ubuntu video
3
mplayer tv://device=/dev/video
– Stefan
Oct 20 '10 at 7:13
@Stefan: can you? that's too simple!
– phunehehe
Oct 20 '10 at 8:47
"Without installing any extra applications". That's a pretty weird and severe constraint. I would just install something like cheese.
– Wim Coenen
Oct 20 '10 at 9:43
@phunene, well it works for me.... sometimes
– Stefan
Oct 20 '10 at 13:40
@phunehehe: Yes, we can ;-)
– echox
Oct 20 '10 at 17:36
add a comment |
In windows I can open "My Computer" and click on the "Webcam" icon to get a feed from my webcam. I can also take snapshots of that feed.
Can I do the same in Ubuntu? Without installing any extra applications like Photobooth.
linux ubuntu video
In windows I can open "My Computer" and click on the "Webcam" icon to get a feed from my webcam. I can also take snapshots of that feed.
Can I do the same in Ubuntu? Without installing any extra applications like Photobooth.
linux ubuntu video
linux ubuntu video
asked Oct 20 '10 at 7:06
foxfox
4262511
4262511
3
mplayer tv://device=/dev/video
– Stefan
Oct 20 '10 at 7:13
@Stefan: can you? that's too simple!
– phunehehe
Oct 20 '10 at 8:47
"Without installing any extra applications". That's a pretty weird and severe constraint. I would just install something like cheese.
– Wim Coenen
Oct 20 '10 at 9:43
@phunene, well it works for me.... sometimes
– Stefan
Oct 20 '10 at 13:40
@phunehehe: Yes, we can ;-)
– echox
Oct 20 '10 at 17:36
add a comment |
3
mplayer tv://device=/dev/video
– Stefan
Oct 20 '10 at 7:13
@Stefan: can you? that's too simple!
– phunehehe
Oct 20 '10 at 8:47
"Without installing any extra applications". That's a pretty weird and severe constraint. I would just install something like cheese.
– Wim Coenen
Oct 20 '10 at 9:43
@phunene, well it works for me.... sometimes
– Stefan
Oct 20 '10 at 13:40
@phunehehe: Yes, we can ;-)
– echox
Oct 20 '10 at 17:36
3
3
mplayer tv://device=/dev/video
– Stefan
Oct 20 '10 at 7:13
mplayer tv://device=/dev/video
– Stefan
Oct 20 '10 at 7:13
@Stefan: can you? that's too simple!
– phunehehe
Oct 20 '10 at 8:47
@Stefan: can you? that's too simple!
– phunehehe
Oct 20 '10 at 8:47
"Without installing any extra applications". That's a pretty weird and severe constraint. I would just install something like cheese.
– Wim Coenen
Oct 20 '10 at 9:43
"Without installing any extra applications". That's a pretty weird and severe constraint. I would just install something like cheese.
– Wim Coenen
Oct 20 '10 at 9:43
@phunene, well it works for me.... sometimes
– Stefan
Oct 20 '10 at 13:40
@phunene, well it works for me.... sometimes
– Stefan
Oct 20 '10 at 13:40
@phunehehe: Yes, we can ;-)
– echox
Oct 20 '10 at 17:36
@phunehehe: Yes, we can ;-)
– echox
Oct 20 '10 at 17:36
add a comment |
5 Answers
5
active
oldest
votes
Since you want an answer "without installing any extra applications like Photobooth," I've tried to give a solution that doesn't depend on very much. Also I'm assuming that your webcam uses "Video4Linux2" and that it is /dev/video0
. If this is a modern webcam and if you only have one, these are pretty good assumptions.
From the command line:
$ gst-launch-0.10 v4l2src device=/dev/video0 ! xvimagesink
Note that "v4l2src" contains a lowercase L and not the number 1. On your system the command may be gst-launch
or something starting with gst-launch
but with a different version number. Tab completion should help you find the exact command name. This tool is in the gstreamer0.10-tools
package on my Ubuntu system, which is a dependency of libgstreamer, which is a dependency of a large number of the apps on my Ubuntu system and is likely present in the default installation.
Other Applications
If you don't mind installing other applications, here is how you can do this in a few other applications. All of them can easily be installed via apt-get
or another package manager of your choosing:
VLC:$ vlc v4l2:///dev/video0
Also, you can do this from the VLC GUI by going to File->Open Capture Device
mplayer:mplayer tv://device=/dev/video01
(from Stefan in the comments)
Cheese: This is a photobooth-like app that is very simple to use.
VLC is so flexible
– Andrew
Nov 28 '18 at 4:45
Note that Cheese is super easy to use and comes pre-installed with Ubuntu I believe, which is nice. One can just search for it in the programs menu and launch it from there.
– Gabriel Staples
Jan 30 at 18:11
add a comment |
Or you can try mpv command
mpv /dev/video0
add a comment |
guvcview
This program is ideal for screencasts, as it can show just the camera on a window and nothing else:
sudo apt-get install guvcview
guvcview
Then just use any screen recorder to make a feed. recordmydesktop
works fine.
Tested on Ubuntu 18.04.
Related questions:
- https://askubuntu.com/questions/536563/screen-recorder-webcam
- https://askubuntu.com/questions/48245/webcam-apps-and-ways-of-checking-if-webcam-is-working
add a comment |
A slightly different syntax worked for me using mplayer:
mplayer -tv device=/dev/video1 tv://
I am using a plugged-in webcam (not the built-in). So I changed /dev/video0
to /dev/video1
. But Stefan's syntax above seemed to default to the built-in because of an argument parsing error. See marked lines in the output:
baxelrod@it6598 ~ $ mplayer tv://device=/dev/video1
MPlayer 1.2.1 (Debian), built with gcc-5.3.1 (C) 2000-2016 MPlayer Team
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.
Playing tv://device=/dev/video1.
The filename option must be an integer: dev/video1 <--
Struct tv, field filename parsing error: dev/video1 <--
TV file format detected.
...
Selected device: Integrated Camera <--
...
When I use the syntax I posted, I don't get the error lines, and I get this instead:
Selected device: UVC Camera (046d:081b)
add a comment |
ffplay /dev/video0 is one of the simpler methods, and will work provided you have ffmpeg installed.
New contributor
add a comment |
Your Answer
StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);
StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});
function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});
}
});
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f3304%2fhow-do-i-watch-my-webcams-feed-in-linux%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
5 Answers
5
active
oldest
votes
5 Answers
5
active
oldest
votes
active
oldest
votes
active
oldest
votes
Since you want an answer "without installing any extra applications like Photobooth," I've tried to give a solution that doesn't depend on very much. Also I'm assuming that your webcam uses "Video4Linux2" and that it is /dev/video0
. If this is a modern webcam and if you only have one, these are pretty good assumptions.
From the command line:
$ gst-launch-0.10 v4l2src device=/dev/video0 ! xvimagesink
Note that "v4l2src" contains a lowercase L and not the number 1. On your system the command may be gst-launch
or something starting with gst-launch
but with a different version number. Tab completion should help you find the exact command name. This tool is in the gstreamer0.10-tools
package on my Ubuntu system, which is a dependency of libgstreamer, which is a dependency of a large number of the apps on my Ubuntu system and is likely present in the default installation.
Other Applications
If you don't mind installing other applications, here is how you can do this in a few other applications. All of them can easily be installed via apt-get
or another package manager of your choosing:
VLC:$ vlc v4l2:///dev/video0
Also, you can do this from the VLC GUI by going to File->Open Capture Device
mplayer:mplayer tv://device=/dev/video01
(from Stefan in the comments)
Cheese: This is a photobooth-like app that is very simple to use.
VLC is so flexible
– Andrew
Nov 28 '18 at 4:45
Note that Cheese is super easy to use and comes pre-installed with Ubuntu I believe, which is nice. One can just search for it in the programs menu and launch it from there.
– Gabriel Staples
Jan 30 at 18:11
add a comment |
Since you want an answer "without installing any extra applications like Photobooth," I've tried to give a solution that doesn't depend on very much. Also I'm assuming that your webcam uses "Video4Linux2" and that it is /dev/video0
. If this is a modern webcam and if you only have one, these are pretty good assumptions.
From the command line:
$ gst-launch-0.10 v4l2src device=/dev/video0 ! xvimagesink
Note that "v4l2src" contains a lowercase L and not the number 1. On your system the command may be gst-launch
or something starting with gst-launch
but with a different version number. Tab completion should help you find the exact command name. This tool is in the gstreamer0.10-tools
package on my Ubuntu system, which is a dependency of libgstreamer, which is a dependency of a large number of the apps on my Ubuntu system and is likely present in the default installation.
Other Applications
If you don't mind installing other applications, here is how you can do this in a few other applications. All of them can easily be installed via apt-get
or another package manager of your choosing:
VLC:$ vlc v4l2:///dev/video0
Also, you can do this from the VLC GUI by going to File->Open Capture Device
mplayer:mplayer tv://device=/dev/video01
(from Stefan in the comments)
Cheese: This is a photobooth-like app that is very simple to use.
VLC is so flexible
– Andrew
Nov 28 '18 at 4:45
Note that Cheese is super easy to use and comes pre-installed with Ubuntu I believe, which is nice. One can just search for it in the programs menu and launch it from there.
– Gabriel Staples
Jan 30 at 18:11
add a comment |
Since you want an answer "without installing any extra applications like Photobooth," I've tried to give a solution that doesn't depend on very much. Also I'm assuming that your webcam uses "Video4Linux2" and that it is /dev/video0
. If this is a modern webcam and if you only have one, these are pretty good assumptions.
From the command line:
$ gst-launch-0.10 v4l2src device=/dev/video0 ! xvimagesink
Note that "v4l2src" contains a lowercase L and not the number 1. On your system the command may be gst-launch
or something starting with gst-launch
but with a different version number. Tab completion should help you find the exact command name. This tool is in the gstreamer0.10-tools
package on my Ubuntu system, which is a dependency of libgstreamer, which is a dependency of a large number of the apps on my Ubuntu system and is likely present in the default installation.
Other Applications
If you don't mind installing other applications, here is how you can do this in a few other applications. All of them can easily be installed via apt-get
or another package manager of your choosing:
VLC:$ vlc v4l2:///dev/video0
Also, you can do this from the VLC GUI by going to File->Open Capture Device
mplayer:mplayer tv://device=/dev/video01
(from Stefan in the comments)
Cheese: This is a photobooth-like app that is very simple to use.
Since you want an answer "without installing any extra applications like Photobooth," I've tried to give a solution that doesn't depend on very much. Also I'm assuming that your webcam uses "Video4Linux2" and that it is /dev/video0
. If this is a modern webcam and if you only have one, these are pretty good assumptions.
From the command line:
$ gst-launch-0.10 v4l2src device=/dev/video0 ! xvimagesink
Note that "v4l2src" contains a lowercase L and not the number 1. On your system the command may be gst-launch
or something starting with gst-launch
but with a different version number. Tab completion should help you find the exact command name. This tool is in the gstreamer0.10-tools
package on my Ubuntu system, which is a dependency of libgstreamer, which is a dependency of a large number of the apps on my Ubuntu system and is likely present in the default installation.
Other Applications
If you don't mind installing other applications, here is how you can do this in a few other applications. All of them can easily be installed via apt-get
or another package manager of your choosing:
VLC:$ vlc v4l2:///dev/video0
Also, you can do this from the VLC GUI by going to File->Open Capture Device
mplayer:mplayer tv://device=/dev/video01
(from Stefan in the comments)
Cheese: This is a photobooth-like app that is very simple to use.
edited Oct 20 '10 at 20:01
answered Oct 20 '10 at 15:33
Steven DSteven D
32.6k898108
32.6k898108
VLC is so flexible
– Andrew
Nov 28 '18 at 4:45
Note that Cheese is super easy to use and comes pre-installed with Ubuntu I believe, which is nice. One can just search for it in the programs menu and launch it from there.
– Gabriel Staples
Jan 30 at 18:11
add a comment |
VLC is so flexible
– Andrew
Nov 28 '18 at 4:45
Note that Cheese is super easy to use and comes pre-installed with Ubuntu I believe, which is nice. One can just search for it in the programs menu and launch it from there.
– Gabriel Staples
Jan 30 at 18:11
VLC is so flexible
– Andrew
Nov 28 '18 at 4:45
VLC is so flexible
– Andrew
Nov 28 '18 at 4:45
Note that Cheese is super easy to use and comes pre-installed with Ubuntu I believe, which is nice. One can just search for it in the programs menu and launch it from there.
– Gabriel Staples
Jan 30 at 18:11
Note that Cheese is super easy to use and comes pre-installed with Ubuntu I believe, which is nice. One can just search for it in the programs menu and launch it from there.
– Gabriel Staples
Jan 30 at 18:11
add a comment |
Or you can try mpv command
mpv /dev/video0
add a comment |
Or you can try mpv command
mpv /dev/video0
add a comment |
Or you can try mpv command
mpv /dev/video0
Or you can try mpv command
mpv /dev/video0
answered Jul 4 '18 at 17:52
hungptithungptit
1412
1412
add a comment |
add a comment |
guvcview
This program is ideal for screencasts, as it can show just the camera on a window and nothing else:
sudo apt-get install guvcview
guvcview
Then just use any screen recorder to make a feed. recordmydesktop
works fine.
Tested on Ubuntu 18.04.
Related questions:
- https://askubuntu.com/questions/536563/screen-recorder-webcam
- https://askubuntu.com/questions/48245/webcam-apps-and-ways-of-checking-if-webcam-is-working
add a comment |
guvcview
This program is ideal for screencasts, as it can show just the camera on a window and nothing else:
sudo apt-get install guvcview
guvcview
Then just use any screen recorder to make a feed. recordmydesktop
works fine.
Tested on Ubuntu 18.04.
Related questions:
- https://askubuntu.com/questions/536563/screen-recorder-webcam
- https://askubuntu.com/questions/48245/webcam-apps-and-ways-of-checking-if-webcam-is-working
add a comment |
guvcview
This program is ideal for screencasts, as it can show just the camera on a window and nothing else:
sudo apt-get install guvcview
guvcview
Then just use any screen recorder to make a feed. recordmydesktop
works fine.
Tested on Ubuntu 18.04.
Related questions:
- https://askubuntu.com/questions/536563/screen-recorder-webcam
- https://askubuntu.com/questions/48245/webcam-apps-and-ways-of-checking-if-webcam-is-working
guvcview
This program is ideal for screencasts, as it can show just the camera on a window and nothing else:
sudo apt-get install guvcview
guvcview
Then just use any screen recorder to make a feed. recordmydesktop
works fine.
Tested on Ubuntu 18.04.
Related questions:
- https://askubuntu.com/questions/536563/screen-recorder-webcam
- https://askubuntu.com/questions/48245/webcam-apps-and-ways-of-checking-if-webcam-is-working
edited Dec 23 '18 at 17:29
answered Dec 5 '16 at 23:33
Ciro Santilli 新疆改造中心 六四事件 法轮功Ciro Santilli 新疆改造中心 六四事件 法轮功
5,22024443
5,22024443
add a comment |
add a comment |
A slightly different syntax worked for me using mplayer:
mplayer -tv device=/dev/video1 tv://
I am using a plugged-in webcam (not the built-in). So I changed /dev/video0
to /dev/video1
. But Stefan's syntax above seemed to default to the built-in because of an argument parsing error. See marked lines in the output:
baxelrod@it6598 ~ $ mplayer tv://device=/dev/video1
MPlayer 1.2.1 (Debian), built with gcc-5.3.1 (C) 2000-2016 MPlayer Team
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.
Playing tv://device=/dev/video1.
The filename option must be an integer: dev/video1 <--
Struct tv, field filename parsing error: dev/video1 <--
TV file format detected.
...
Selected device: Integrated Camera <--
...
When I use the syntax I posted, I don't get the error lines, and I get this instead:
Selected device: UVC Camera (046d:081b)
add a comment |
A slightly different syntax worked for me using mplayer:
mplayer -tv device=/dev/video1 tv://
I am using a plugged-in webcam (not the built-in). So I changed /dev/video0
to /dev/video1
. But Stefan's syntax above seemed to default to the built-in because of an argument parsing error. See marked lines in the output:
baxelrod@it6598 ~ $ mplayer tv://device=/dev/video1
MPlayer 1.2.1 (Debian), built with gcc-5.3.1 (C) 2000-2016 MPlayer Team
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.
Playing tv://device=/dev/video1.
The filename option must be an integer: dev/video1 <--
Struct tv, field filename parsing error: dev/video1 <--
TV file format detected.
...
Selected device: Integrated Camera <--
...
When I use the syntax I posted, I don't get the error lines, and I get this instead:
Selected device: UVC Camera (046d:081b)
add a comment |
A slightly different syntax worked for me using mplayer:
mplayer -tv device=/dev/video1 tv://
I am using a plugged-in webcam (not the built-in). So I changed /dev/video0
to /dev/video1
. But Stefan's syntax above seemed to default to the built-in because of an argument parsing error. See marked lines in the output:
baxelrod@it6598 ~ $ mplayer tv://device=/dev/video1
MPlayer 1.2.1 (Debian), built with gcc-5.3.1 (C) 2000-2016 MPlayer Team
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.
Playing tv://device=/dev/video1.
The filename option must be an integer: dev/video1 <--
Struct tv, field filename parsing error: dev/video1 <--
TV file format detected.
...
Selected device: Integrated Camera <--
...
When I use the syntax I posted, I don't get the error lines, and I get this instead:
Selected device: UVC Camera (046d:081b)
A slightly different syntax worked for me using mplayer:
mplayer -tv device=/dev/video1 tv://
I am using a plugged-in webcam (not the built-in). So I changed /dev/video0
to /dev/video1
. But Stefan's syntax above seemed to default to the built-in because of an argument parsing error. See marked lines in the output:
baxelrod@it6598 ~ $ mplayer tv://device=/dev/video1
MPlayer 1.2.1 (Debian), built with gcc-5.3.1 (C) 2000-2016 MPlayer Team
mplayer: could not connect to socket
mplayer: No such file or directory
Failed to open LIRC support. You will not be able to use your remote control.
Playing tv://device=/dev/video1.
The filename option must be an integer: dev/video1 <--
Struct tv, field filename parsing error: dev/video1 <--
TV file format detected.
...
Selected device: Integrated Camera <--
...
When I use the syntax I posted, I don't get the error lines, and I get this instead:
Selected device: UVC Camera (046d:081b)
answered Mar 14 '18 at 18:01
BenBen
1012
1012
add a comment |
add a comment |
ffplay /dev/video0 is one of the simpler methods, and will work provided you have ffmpeg installed.
New contributor
add a comment |
ffplay /dev/video0 is one of the simpler methods, and will work provided you have ffmpeg installed.
New contributor
add a comment |
ffplay /dev/video0 is one of the simpler methods, and will work provided you have ffmpeg installed.
New contributor
ffplay /dev/video0 is one of the simpler methods, and will work provided you have ffmpeg installed.
New contributor
New contributor
answered 6 mins ago
Henry WilsonHenry Wilson
1
1
New contributor
New contributor
add a comment |
add a comment |
Thanks for contributing an answer to Unix & Linux Stack Exchange!
- Please be sure to answer the question. Provide details and share your research!
But avoid …
- Asking for help, clarification, or responding to other answers.
- Making statements based on opinion; back them up with references or personal experience.
To learn more, see our tips on writing great answers.
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f3304%2fhow-do-i-watch-my-webcams-feed-in-linux%23new-answer', 'question_page');
}
);
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Sign up or log in
StackExchange.ready(function () {
StackExchange.helpers.onClickDraftSave('#login-link');
});
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Sign up using Google
Sign up using Facebook
Sign up using Email and Password
Post as a guest
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
Required, but never shown
3
mplayer tv://device=/dev/video
– Stefan
Oct 20 '10 at 7:13
@Stefan: can you? that's too simple!
– phunehehe
Oct 20 '10 at 8:47
"Without installing any extra applications". That's a pretty weird and severe constraint. I would just install something like cheese.
– Wim Coenen
Oct 20 '10 at 9:43
@phunene, well it works for me.... sometimes
– Stefan
Oct 20 '10 at 13:40
@phunehehe: Yes, we can ;-)
– echox
Oct 20 '10 at 17:36