**Update**
An updated version of this post is –>here (Part 3) <–.
Or to stream via Motion, check out this blog post !
*****
There have been quite a few people wanting to stream a webcam from the Raspberry Pi.
If all you want is to view a webcam stream, without any motion detection, then you’ve come to the right post.
Otherwise, I’ll have a blog post up about motion later on for motion detection.
This guide should get you to the point where you can view the webcam stream from another machine via a web browser, or a media player capable of viewing mjpeg streams – e.g. VLC.
1. Compiling FFMpeg
First thing we need to do is to get a version of ffmpeg that can stream. The version that comes with the current version of Raspbian and Debian have issues streaming, so the sources from deb-multimedia are needed. All the below commands are run as root. If you are not running as root, prepend sudo to all the commands.
**Update**
If you need sound for ffmpeg, you will need to also install the libasound2-dev package which enables ALSA.
– Thanks to fbutler for this
- Add the following lines into /etc/apt/sources.list
deb-src http://www.deb-multimedia.org sid main
deb http://www.deb-multimedia.org wheezy main non-free
- Run
apt-get update
- Run
apt-get install deb-multimedia-keyring
- Remove the second line from /etc/apt/sources.list
deb http://www.deb-multimedia.org wheezy main non-free
- Run
apt-get source ffmpeg-dmo
- You should now have a folder called ffmpeg-dmo-0.11 <-- The version will change as time goes by.
- Change the directory to the folder containing the source. e.g.
cd ffmpeg-dmo-0.11
- Run
./configure
to setup the source. - Run
make && make install
to compile and install ffmpeg - if you are not running as root like I am, then you will need to run the above command with sudo
2. Configuring ffmpeg
Once ffmpeg is installed, we need to create a configuration file to enable ffmpeg to stream to ffserver.
ffserver is what will host the stream.
- We need to create a configuration file for ffserver, we will place it in /etc/ and call it ffserver.conf
Port 80
BindAddress 0.0.0.0
MaxClients 10
MaxBandwidth 50000
NoDaemon<Feed webcam.ffm>
file /tmp/webcam.ffm
FileMaxSize 10M
</Feed><Stream webcam.mjpeg>
Feed webcam.ffm
Format mjpeg
VideoSize 640x480
VideoFrameRate 10
VideoBitRate 2000
VideoQMin 1
VideoQMax 10
</Stream>
The last stanza defines the size of the stream, and bitrate. If the parameters don’t suit each other, then the stream will not be smooth. - Next, the following command needs to be put into a .sh file. This will allow you to start streaming by just running the .sh file. Let’s call it webcam.sh and put it in /usr/sbin as the file needs to be run as root.
ffserver -f /etc/ffserver.conf & ffmpeg -v verbose -r 5 -s 640x480 -f video4linux2 -i /dev/video0 http://localhost/webcam.ffm
- Once the .sh file has been created, and the above code has been placed into it, you need to make the file executable by running chmod +x /usr/sbin/webcam.sh
3. Start Streaming
Once the shell script and configuration file has been created, you can start streaming by running /usr/sbin/webcam.sh
When you run it, you should start seeing lines like this
** 1 dup!2 fps= 5 q=2.6 size= 51136kB time=00:06:56.40 bitrate=1006.0kbits/s dup=359 drop=0
This means that ffmpeg is now streaming, and you should be able to access the stream via the web address of http://<YOUR WEBCAM SERVER>/webcam.mjpeg
** Update of sorts – I continue my webcam experimentation here
If you have found this post useful, please consider donating by pressing on the button below. Donating will help keep this site up and running ๐
In 2.2 i think you have an error in the code. should it not be http://localhost:81/webcam.ffm
I actually changed it slightly from the post you followed ๐
at the top – bind port defines which port ffserver is listening on – so changing that to 80 negates the need to define a port when you’re accessing the stream
Hello, thank you for your guide. I ran into some problems, and I’m hoping you can help me. I’ve been trying to stream from my Pi + webcam for ages now, without success.
First thing I noticed were some errors in the make stage, like “libavcodec/flacdec.c:340:43: warning: โdโ may be used uninitialized in this function [-Wuninitialized]”.
Finally, when all is done, when I try to access the stream via browser (I’m using Chrome), it tries to download a file named webcam.mjpeg.mjpeg ๐
I also have a .asf feed, but when I use VLC to access it, in the console of ffserver/ffmpeg I get:
Codec for stream 0 does not use global headers but container format requires global headers
Codec for stream 1 does not use global headers but container format requires global headers
and VLC fails.
Any help here would be very much appreciated ๐ Oh, I’m using a Mac.
Cheers!
Have you tried using VLC to view the mjpeg stream to see if that works ?
Yes. I’ve got rid of those warnings/errors too, but still no deal.
VLC doesn’t open any stream at all … asf, rm, swf, whatever I configure ffserver with.
I’ve noticed that when I try to access the stream, in the status page of ffserver it states WAIT_FEED for my connection.
I’ve also noticed in other people posts that ffserver reports the input as a connection, but in mine that line doesn’t show. Maybe it’s getting trouble reading my device?
I’m not trying with a Logitech C270. With what webcam did you succeed?
Thanks for your time!
Ups, typo. “I’m _now_ trying with …”
My webcam was a generic one. It uses the uvc driver.
Does /dev/ contain video0 ?
Yeap. I can also manage to user streamer to take pictures, but no video from ffmpeg ๐
Can you run this command, and see if the file it outputs contains video ?
ffmpeg -v verbose -r 5 -s 640×480 -f video4linux2 -i /dev/video0 temp.avi
This should create the temp.avi file, and hopefully it should contain some video.
Let it run for 10 or so seconds, then hit “q” to make it stop, then view the video.
It should tell us whether ffmpeg is actually working or not.
Hi! I had the same problem… I can ran ffserver and ffmpeg commands successfull, but when i tried to get the stream at VLC, i got error like
canno't access
or something like that, and stat.html contains WAIT_FEED.I have no solution for this, but it’s just one time get working successfully, and i didn’t do anything for it. Now it’s working, hope you get same ๐
Hey pfqueiros,
Can you explain how did you capture webcam stream using ffmpeg?
Santoshs-MacBook-Pro:~ Santosh$ ffmpeg -v verbose -r 5 -s 640x480 -f video4linux2 -i /dev/video0 http://localhost/webcam.ffm
ffmpeg version 1.1.1 Copyright (c) 2000-2013 the FFmpeg developers
built on Feb 7 2013 12:31:21 with Apple LLVM version 4.2 (clang-425.0.24) (based on LLVM 3.2svn)
configuration: --prefix=/usr/local/Cellar/ffmpeg/1.1.1 --enable-shared --enable-pthreads --enable-gpl --enable-version3 --enable-nonfree --enable-hardcoded-tables --enable-avresample --cc=cc --host-cflags= --host-ldflags= --enable-libx264 --enable-libfaac --enable-libmp3lame --enable-libxvid
libavutil 52. 13.100 / 52. 13.100
libavcodec 54. 86.100 / 54. 86.100
libavformat 54. 59.106 / 54. 59.106
libavdevice 54. 3.102 / 54. 3.102
libavfilter 3. 32.100 / 3. 32.100
libswscale 2. 1.103 / 2. 1.103
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 2.100 / 52. 2.100
Unknown input format: 'video4linux2'
Santoshs-MacBook-Pro:~ Santosh$
</code
I am having a similar problem. Did you ever receive any reponse? thanks
Try using the part3 guide rather than this one.
why wont mine work > logs included > http://pastebin.com/xjVMpE8z
Hi
I had similar issues to you as well when I first started this.
This line holds the clue
The v4l2 frame is 65496 bytes, but 614400 bytes are expected
I found that I had my bitrate set too low. Try setting it higher and see how you go.
If you could also pastebin your configuration file, that would be helpful also.
my config is the same as above and how do i set the bitrate higher ?
btw “The v4l2 frame is 65496 bytes, but 614400 bytes are expected”
keeps changing to “The v4l2 frame is * bytes, but 614400 bytes are expected”
* = wildcard
and a other webcam gives me this
[video4linux2,v4l2 @ 0x1690520] Buffer len [0] = 118784 != 307200
/dev/video0: Operation not permitted
change videobitrate 2000 to 5000
still
[video4linux2,v4l2 @ 0x1d4e520] The v4l2 frame is 40588 bytes, but 614400 bytes are expected
Whats the other configuration parameters ?
What FPS ?
What resolution ?
this is my config > http://pastebin.com/CdXu3hZA
Try a smaller resolution to start with
320×240 would be a good start.
even with that resolution i still get > [video4linux2,v4l2 @ 0xf36520] The v4l2 frame is 44764 bytes, but 614400 bytes are expected
Do you manage to get any frames / does it last longer than a few seconds when you try to run the script ?
it does not even last a second
Try settings the verbosity to debug, and then try again and see if we can squeeze any more information out of ffmpeg
Are you using a Webcam with compression… I’m having the same problem with a Logitech Quickcam and get:
[video4linux2,v4l2 @ 0x26f04b0] Buffer len [0] = 118784 != 307200
There is a comment about MJPEG compression on the video4linux2 wiki:
http://linuxtv.org/wiki/index.php/UVC_Webcam_Devices
(I don’t yet know how to fix this… ๐ )
I think I have the same problem with the logitech webcam, from what I’ve read it’s plausible that the cam is spitting out compressed MJPEG and V4L can’t handle this. Anyone found a way to ask the camera to spit out uncompressed MJPEG?
v4l2-ctl can control the webcam. Check out the command line arguments and see what you can do there.
I’m getting pretty much the same error but changing the bit rate to 5000 didn’t change a thing
[video4linux2,v4l2 @ 0x2339620] [4]Capabilities: 5000001
[video4linux2,v4l2 @ 0x2339620] Buffer len [0] = 12288 != 25344
/dev/video0: Operation not permitted
anything else I can try?
Try different resolutions as well. What webcam do you have ?
My webcam driver was chaging the resolution to somthing weird (I can’t remember what exactly, I’m in school so I’ll check later) so I changed the res in my /usr/sbin/webcam.sh file and the ffserver.conf file.I’ve got a treally old “creative” one with a really bad resolution.
Try and use v4l2-ctl or uvcdynctrl to detect the resolutions that your webcam can use and try using those resolutions ?
I know some webcams will force a certain fps or resolution so that could be an issue ?
Well, the “make && make install” took about 2-3 hours (that’s certainly worth mentioning) but then I just got an error:
pi@raspberrypi /usr/sbin $ sudo webcam.sh
/usr/sbin/webcam.sh: 1: /usr/sbin/webcam.sh: ffmpeg: not found
pi@raspberrypi /usr/sbin $ /usr/sbin/webcam.sh: 1: /usr/sbin/webcam.sh: ffserver: not found
Does take a while to compile doesn’t it haha.
ffmpeg not found ?
Check the output of make install…are you sure there weren’t any errors ?
Try:
sudo make install
(Worked for me ๐ )
Thanks for that ! I forgot to mention I was running as root in the post. I’ll have to update it.
hi…..after sudo make install i got this error
make: *** [ffmpeg_g] Error 1
Did anything else come up before that ?
Thanks a lot! This worked straight away with a Logitech Pro 9000 webcam.
But would you happen to know how to make ffmpeg read mjpeg data from the webcam instead of raw uncompressed data? I’d like to stream the mjpeg directly – that would lessen the system load a lot.
I’m nor aware of a way to do that, but I’ll look into it. ๐ Thanks for reading ๐
Using this line should let it stream mjpeg directly
ffmpeg -loglevel info -r 10 -vcodec mjpeg -s 320×240 -f video4linux2 -i /dev/video0 http://localhost/webcam.mjpeg
Hey, I really appreciate you made this tutorial. Thank you.
But even though I followed every single step of it, it gives me:
[http @ 0x11704b0] HTTP error 404 Not Found
http://localhost/webcam.ffm: Input/output error
The webcam, Logitech Quickcam 9000 Pro, works out fine, since I recorded an AVI and played it back.
What am I doing wrong?
Thanks,
Lexenstar
Sounds like either ffserver is not running of configuincorrectly. What do you have for in the ffserver.conf file ?
Port 80
BindAddress 0.0.0.0
MaxClients 10
MaxBandwidth 50000
NoDaemon
file /tmp/webam.ffm
FileMaxSize 10M
Feed webcam.ffm
Format mjpeg
VideoSize 640x480
VideoFrameRate 10
VideoBitRate 2000
VideoQMin 1
VideoQMax 10
I also tried changing the port since it sometimes comes up with
Address already in use.
Please delete the other comment, Im sorry.
Looks like you copied my typo of file /tmp/webam.ffm should be /tmp/webcam.ffm
Alright, now its streaming, but when Im going there by browser (Chrome) it just tries (download does not really start) to download the webcam.mjpeg and when I give the link to VLC to open a network stream it just comes up with
main error: open of `192.168.2.139/webcam.mjpeg' failed
The stream seems to be alright, giving out this stuff all the time
*** 7 dup!4 fps=5.1 q=2.6 size= 207616kB time=00:14:06.80 bitrate=2008.5kbits/s dup=3753 drop=0
Add the following bits to the end of the conf file and then try to access 192.168.2.139/status.html
<Stream status.html>
Format status
ACL allow 192.168.2.0 192.168.2.255
</Stream>
see if you can access that
I can, it gives me the table of available streams:
Webcam:
Served conns: 0
bytes: 0
Format: mjpeg
Bitrate kbits/s: 2000
Video kbits/s: 2000
Codec: mjpeg
Audio kbits/s: 0
Feed: webcam.ffm
At least that means that ffserver is running right…
Can you try a different browser to access http://192.168.2.139/webcam.mjpeg ?
Also, when you access using vlc, make sure you have http:// at the beginning or it won’t work.
Firefox and Internet Explorer just keep on loading forever when opening the stream. But everytime I start loading it with some browser the byte-count of webcam.mjpeg goes up a little and a new connection with the state WAIT_FEED comes up in the lowest table.
Sounds like it’s doing what it’s meant to do then.
Try VLC again with “http://192.168.2.139/webcam.mjpeg”
It actually always goes up exactly 66 bytes.
Actually VLC does not come up with an error anymore. But while having the correct address in its taskbar it just wont play, stays black. Pressing play does not do anything. :/
You’ve gotten me stumped then :/ not sure what could be going wrong.
Can you paste the whole entire output from when you start the command until it starts streaming ?
I got it fixed now. I put up a new installation of wheezy. Apparently the typo with “webam” completely confused my little pi… but thanks a lot! Your answers gave me a lot of troubleshooting-exercise ๐
Goodo ! Glad to hear you got it going ๐
It just occurred to me that maybe you still had an ffserver instance running in the background. Perhaps that was causing issues as well !
Port 80
BindAddress 0.0.0.0
MaxClients 10
MaxBandwidth 50000
NoDaemon
file /tmp/webam.ffm
FileMaxSize 10M
Feed webcam.ffm
Format mjpeg
VideoSize 640x480
VideoFrameRate 10
VideoBitRate 2000
VideoQMin 1
VideoQMax 10
I also tried changing the port since it sometimes comes up with
Address already in use
.Already in use, because you have running ffserver from webcam.sh
The webcam.sh file is meant to be run to start streaming.
If the ffmpeg process dies however, either the ffserver process needs to be killed and then webcam.sh run again, or you need to run ffmpeg with the same parameters as the ones in webcam.sh
Same problem solved killing Apache server that uses the same port (the 80)
Or you could configure either apache or ffserver to use a different port
Yep sure, I use for exemple 10080…but at that moment while you swear against the pc beecause nothing works the only verb is TO KILL!
Haha I know how you feel
Cheers for the walk through.
Works a treat for me – I’m using wheezy, logitech webcam pro 9000 and VLC.
Dave.
Awesome, glad I could help ๐
Hello, Thank you for the guide.
I am trying to follow this but when running make on the ffmpeg source I get the following error, any ideas?
pi@raspberrypi ~/ffmpeg-dmo-0.11.1 $ sudo make
LD ffmpeg_g
libavformat/libavformat.a: could not read symbols: Malformed archive
collect2: ld returned 1 exit status
make: *** [ffmpeg_g] Error 1
Perhaps the source didnt download correctly. Try downloading it again ?
Hi,
greatsome that some one put up a guide… for some reason i don’t get it to work… get:
root@hallon01:~# /usr/sbin/webcam.sh
ffserver version 0.11.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Aug 19 2012 23:55:33 with gcc 4.6.3
configuration:
libavutil 51. 54.100 / 51. 54.100
libavcodec 54. 23.100 / 54. 23.100
libavformat 54. 6.100 / 54. 6.100
libavdevice 54. 0.100 / 54. 0.100
libavfilter 2. 77.100 / 2. 77.100
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 0.11.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Aug 19 2012 23:55:33 with gcc 4.6.3
configuration:
libavutil 51. 54.100 / 51. 54.100
libavcodec 54. 23.100 / 54. 23.100
libavformat 54. 6.100 / 54. 6.100
libavdevice 54. 0.100 / 54. 0.100
libavfilter 2. 77.100 / 2. 77.100
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x139d520] [3]Capabilities: 4000001
bind(port 80): Address already in use
[video4linux2,v4l2 @ 0x139d520] Estimating duration from bitrate, this may be in
accurate
Input #0, video4linux2,v4l2, from ‘/dev/video0’:
Duration: N/A, start: 513.068738, bitrate: 24576 kb/s
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 640×480, 24576 kb
/s, 5 tbr, 1000k tbn, 5 tbc
[http @ 0x139d4b0] HTTP error 404 Not Found
http://localhost/webcam.ffm: Input/output error
root@hallon01:~# ls -l /var/www
total 4
-rw-r–r– 1 pi root 177 Aug 4 18:17 index.html
root@hallon01:~#
any suggestions?
…and Sir, keep up the good work ๐
Do you have any other http server running ? Apache or lighthttpd ?
By default they use the same port as the webcam.sh script. You’ll need to change the port that the script uses in order to get it to stream.
And thanks for reading ๐
Thank you for answering…
turn of the apache was helping…
get this when I rus status.html:
ffserver Status
Available Streams
Path Served
Conns
bytes Format Bit rate
kbits/s Video
kbits/s
Codec Audio
kbits/s
Codec Feed
webcam.mjpeg 0 0 mjpeg 2000 2000 mjpeg 0 webcam.ffm
status.html 1 0 – – – –
Feed webcam.ffm
Stream type kbits/s codec Parameters
0 video 2000 mjpeg 640×480, q=1-10, fps=5
Connection Status
Number of connections: 2 / 10
Bandwidth in use: 0k / 50000k
# File IP Proto State Target bits/sec Actual bits/sec Bytes transferred
1 status.html 192.168.1.2 HTTP/1.1 HTTP_WAIT_REQUEST 0 0 0
2 webcam.ffm(input) 127.0.0.1 HTTP/1.1 RECEIVE_DATA 2000k 2064k 20029k
but with:
192.168.1.201/webcam.mjpeg
firefox says: “open with”
and ie says:
do you want to open or save “webcam.mjpeg”…
gush… back to basic, feel so noobish. any help is welcomed.
Sometimes the browser is not setup to handle mjpeg streams. Try streaming it through vlc instead.
Hello !
I have managed to make and install, but trying to run the script I get the following output and error:
ffserver version 0.11.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 1 2012 10:20:36 with gcc 4.6.3
configuration:
libavutil 51. 54.100 / 51. 54.100
libavcodec 54. 23.100 / 54. 23.100
libavformat 54. 6.100 / 54. 6.100
libavdevice 54. 0.100 / 54. 0.100
libavfilter 2. 77.100 / 2. 77.100
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 0.11.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 1 2012 10:20:36 with gcc 4.6.3
configuration:
libavutil 51. 54.100 / 51. 54.100
libavcodec 54. 23.100 / 54. 23.100
libavformat 54. 6.100 / 54. 6.100
libavdevice 54. 0.100 / 54. 0.100
libavfilter 2. 77.100 / 2. 77.100
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x272c520] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x272c520] Estimating duration from bitrate, this may be inaccurate
Input #0, video4linux2,v4l2, from ‘/dev/video0’:
Duration: N/A, start: 1115.553043, bitrate: 24576 kb/s
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 640×480, 24576 kb/s, 5 tbr, 1000k tbn, 5 tbc
[tcp @ 0x272cac0] TCP connection to localhost:80 failed: Connection refused
http://localhost/webcam.ffm: Input/output error
any help greatly appreciated thanks
sounds like ffserver is either not running or runnin on another port
[…] these articles for Streamingย Webcam From The Raspberry Pi How To : Stream A Webcam From The Raspberry Pi ยป The Rantings and Ravings of a Madman How To : Stream A Webcam From The Raspberry Pi Part 2 ยป The Rantings and Ravings of a Madman […]
License: LGPL version 2.1 or later
Creating config.mak and config.h…
config.h is unchanged
libavutil/avconfig.h is unchanged
this is my problem…can u plesae help me…
can you post the entire log please ?
pi@raspberrypi /usr/sbin $ sudo webcam.sh
/usr/sbin/webcam.sh: 1: /usr/sbin/webcam.sh: ffmpeg: not found
pi@raspberrypi /usr/sbin $ /usr/sbin/webcam.sh: 1: /usr/sbin/webcam.sh: ffserver: not found
HI actually this is my problem….
have you compiled ffmpeg and installed it ?
ya i compiled it…
after i run this command “make install” i got this error
collect2: ld returned 1 exit status
make: *** [ffmpeg_g] Error 1
root@raspberrypi:~/ffmpeg-dmo-0.11.1#
I’ve never seen that before…
Can you paste the lines above that as well ?
Hello!
I have webcam Logitech C910. File /dev/video0 is present. I use wheezy. I installed ffmpeg, but when i run webcam.sh has error:
ioctl(VIDIOC_DQBUF): Input/output error
Estimating duration from bitrate, this may be inaccurate
See my full bash command and error: http://pastebin.com/mh1sJrw7
#bind(port 80): Address already in use
Do you have another web server already running ?
Maybe use a different port for ffmpeg.
No. I have clean weezy, only install script noip: http://www.no-ip.com/support/guides/update_clients/setting_up_linux_update_client.html
Then I install ffmpeg follow it instruction
I try change ffmpeg port to 8080 but have same error:
pi@raspberrypi ~ $ sudo /usr/sbin/webcam.sh
ffserver version 0.11.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 17 2012 09:03:41 with gcc 4.6.3
ffmpeg version 0.11.1 configuration:
libavutil 51. 54.100 / 51. 54.100
libavcodec 54. 23.100 / 54. 23.100
libavformat 54. 6.100 / 54. 6.100
Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 17 2012 09:03:41 with gcc 4.6.3
configuration:
libavutil 51. 54.100 / 51. 54.100
libavcodec 54. 23.100 / 54. 23.100
libavformat 54. 6.100 / 54. 6.100
libavdevice 54. 0.100 / 54. 0.100
libavfilter 2. 77.100 / 2. 77.100
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 15.100 / 0. 15.100
libavdevice 54. 0.100 / 54. 0.100
libavfilter 2. 77.100 / 2. 77.100
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x2c1c520] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x2c1c520] ioctl(VIDIOC_DQBUF): No such device
[video4linux2,v4l2 @ 0x2c1c520] Estimating duration from bitrate, this may be inaccurate
Input #0, video4linux2,v4l2, from '/dev/video0':
Duration: N/A, bitrate: 6144 kb/s
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 320x240, 6144 kb/s, 5 tbr, 1000k tbn, 5 tbc
[buffer @ 0x2c1c4c0] w:320 h:240 pixfmt:yuyv422 tb:1/1000000 sar:0/1 sws_param:flags=2
[buffersink @ 0x2c1e900] No opaque field provided
[scale @ 0x2c20e20] w:320 h:240 fmt:yuyv422 sar:0/1 -> w:640 h:480 fmt:yuvj422p sar:0/1 flags:0x4
Output #0, ffm, to 'http://localhost/webcam.ffm':
Metadata:
encoder : Lavf54.6.100
Stream #0:0: Video: mjpeg, yuvj422p, 640x480, q=1-10, 2000 kb/s, 1000k tbn, 5 tbc
Stream mapping:
Stream #0:0 -> #0:0 (rawvideo -> mjpeg)
Press [q] to stop, [?] for help
[video4linux2,v4l2 @ 0x2c1c520] ioctl(VIDIOC_DQBUF): No such device
frame= 0 fps=0.0 q=0.0 Lsize= 4kB time=00:00:00.00 bitrate= 0.0kbits/s
video:0kB audio:0kB global headers:0kB muxing overhead inf%
Output file is empty, nothing was encoded (check -ss / -t / -frames parameters if used)
I change port to 8080.
Error “#bind(port 80): Address already in use” – does not appear
But other error’s is present.
Did you update the rest of the script to use port 8080 rather than port 80 ?
http://localhost:8080/webcam.ffm for example ?
Yes. But cam is not working.
When I connect cam to Windows 7 and run Skype, on the webcam Blue LED is on.
But on weezy this LED is off. Thus Camera does not turn on.
I try this coomand: ffmpeg -loglevel info -r 10 -vcodec mjpeg -s 640ร480 -f video4linux2 -i /dev/video0 http://localhost/webcam.mjpeg
And get this error:
[V4L2 indev @ 0x1fe4d50] Unable to parse option value “640ร480” as image size
[V4L2 indev @ 0x1fe4d50] Error setting option video_size to value 640ร480.
/dev/video0: Invalid argument
Try a different size ?
maybe 320×240 ?
or maybe try vga ?
also, is ffserver setup to use http://localhost/webcam.mjpeg ?
Need to change that to port 8080 also – i.e. http://localhost:8080/webcam.mjpeg
ffserver will need to be setup to use webcam.mjpeg as well for the stream input.
Yes, i’m trying different resolution, but always see this error:
ioctl(VIDIOC_DQBUF): No such device
Example:
pi@raspberrypi ~ $ ffmpeg -an -f video4linux2 -vcodec mjpeg -s 320x240 -r 5 -b 200000 -i /dev/video0 test.avi
ffmpeg version 0.11.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 17 2012 09:03:41 with gcc 4.6.3
configuration:
libavutil 51. 54.100 / 51. 54.100
libavcodec 54. 23.100 / 54. 23.100
libavformat 54. 6.100 / 54. 6.100
libavdevice 54. 0.100 / 54. 0.100
libavfilter 2. 77.100 / 2. 77.100
libswscale 2. 1.100 / 2. 1.100
libswresample 0. 15.100 / 0. 15.100
Please use -b:a or -b:v, -b is ambiguous
[video4linux2,v4l2 @ 0x11d8620] ioctl(VIDIOC_DQBUF): No such device
[video4linux2,v4l2 @ 0x11d8620] Could not find codec parameters (Video: mjpeg, 320x240, 3072 kb/s)
[video4linux2,v4l2 @ 0x11d8620] Estimating duration from bitrate, this may be inaccurate
/dev/video0: could not find codec parameters
Maybe camera is not enough power and I need USB hub with external power for it?
Please use -b:a or -b:v, -b is ambiguous
Don’t use the -b argument.
and try it without -vcodec mjpeg as well.
I try it. And try use mplayer, but see only green area.
I think camera is not enough power. I buy on eBay powered hub. When I recieve it, i try use Logitech C910 with USB Powered Hub.
Hi
Many thanks for the walk-through.
Have compiled, installed and configured ffmpeg as per instructions. All seemed to go well. When I try and run webcam.sh I see the configuration followed by:
[video4linux2,v412 @ 0x173e520] [3]Capabilities: 5000001
[video4linux2,v412 @ 0x173e520] ioctl set time per frame(1/5) failed
/dev/video0: Input/output error
It does appear to open port 80 though as further attempts to run webcam.sh reveal that port 80 is in use.
This is the only thing installed on a clean wheezy image (which has been updated).
Any suggestions gratefully recieved.
Many thanks
Dave
Sounds like the FPS isn’t supported perhaps ?
Try changing fps, or checking what the cam can do with v4l2-ctl
Did you ever get your problem resolved? I have the same exact problem. Here is what I get when I use v4l2-ctl –all
Driver Info (not using libv4l2):
Driver name : pwc
Card type : Logitech QuickCam Pro 4000
Bus info : usb-bcm2708_usb-1.2.6
Driver version: 3.2.27
Capabilities : 0x05000001
Video Capture
Read/Write
Streaming
Format Video Capture:
Width/Height : 640/480
Pixel Format : ‘YU12’
Field : None
Bytes per Line: 960
Size Image : 460800
Colorspace : Unknown (00000000)
Video input : 0 (usb: ok)
I haven’t had much success so far.
I changed to a newer webcam and it works fine now.
this is the error which i got when i run make install command
dec_open2′
/root/ffmpeg-dmo-0.11.1/libavfilter/lavfutils.c:58: undefined reference to `avcodec_alloc_frame’
/root/ffmpeg-dmo-0.11.1/libavfilter/lavfutils.c:70: undefined reference to `avcodec_decode_video2′
/root/ffmpeg-dmo-0.11.1/libavfilter/lavfutils.c:89: undefined reference to `avcodec_close’
libavformat/libavformat.a(allformats.o): In function `av_register_all’:
/root/ffmpeg-dmo-0.11.1/libavformat/allformats.c:49: undefined reference to `avcodec_register_all’
libavformat/libavformat.a(amr.o): In function `amr_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/amr.c:150: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/amr.c:166: undefined reference to `av_free_packet’
libavformat/libavformat.a(anm.o): In function `read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/anm.c:165: undefined reference to `av_log_ask_for_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/anm.c:88: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(ape.o): In function `ape_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/ape.c:392: undefined reference to `av_new_packet’
libavformat/libavformat.a(asfdec.o): In function `ff_asf_parse_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:984: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:987: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:995: undefined reference to `av_packet_new_side_data’
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:1058: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:1042: undefined reference to `av_shrink_packet’
libavformat/libavformat.a(asfdec.o): In function `asf_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:644: undefined reference to `av_free_packet’
libavformat/libavformat.a(asfdec.o): In function `asf_reset_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:1151: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:1151: undefined reference to `av_free_packet’
libavformat/libavformat.a(asfdec.o): In function `asf_read_pts’:
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:1194: undefined reference to `av_free_packet’
libavformat/libavformat.a(asfdec.o): In function `asf_reset_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:1151: undefined reference to `av_free_packet’
libavformat/libavformat.a(asfdec.o):/root/ffmpeg-dmo-0.11.1/libavformat/asfdec.c:1151: more undefined references to `av_free_packet’ follow
libavformat/libavformat.a(asfenc.o): In function `asf_write_header1′:
/root/ffmpeg-dmo-0.11.1/libavformat/asfenc.c:485: undefined reference to `avcodec_find_encoder’
libavformat/libavformat.a(assdec.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/assdec.c:155: undefined reference to `av_new_packet’
libavformat/libavformat.a(assdec.o): In function `read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/assdec.c:111: undefined reference to `av_fast_realloc’
libavformat/libavformat.a(au.o): In function `au_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/au.c:187: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(au.o): In function `au_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/au.c:148: undefined reference to `av_get_bits_per_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/au.c:149: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(avidec.o): In function `avi_read_close’:
/root/ffmpeg-dmo-0.11.1/libavformat/avidec.c:1533: undefined reference to `av_free_packet’
libavformat/libavformat.a(avidec.o): In function `seek_subtitle’:
/root/ffmpeg-dmo-0.11.1/libavformat/avidec.c:1408: undefined reference to `av_free_packet’
libavformat/libavformat.a(avidec.o): In function `avi_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/avidec.c:1216: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/avidec.c:1143: undefined reference to `av_packet_new_side_data’
/root/ffmpeg-dmo-0.11.1/libavformat/avidec.c:1159: undefined reference to `av_free_packet’
libavformat/libavformat.a(avienc.o): In function `avi_write_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/avienc.c:535: undefined reference to `av_init_packet’
libavformat/libavformat.a(avs.o): In function `avs_read_video_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/avs.c:91: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/avs.c:91: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/avs.c:109: undefined reference to `av_free_packet’
libavformat/libavformat.a(bethsoftvid.o): In function `read_frame’:
/root/ffmpeg-dmo-0.11.1/libavformat/bethsoftvid.c:144: undefined reference to `av_fast_realloc’
/root/ffmpeg-dmo-0.11.1/libavformat/bethsoftvid.c:175: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/bethsoftvid.c:188: undefined reference to `av_packet_new_side_data’
/root/ffmpeg-dmo-0.11.1/libavformat/bethsoftvid.c:144: undefined reference to `av_fast_realloc’
/root/ffmpeg-dmo-0.11.1/libavformat/bethsoftvid.c:110: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(bit.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/bit.c:93: undefined reference to `av_new_packet’
libavformat/libavformat.a(bmv.o): In function `bmv_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/bmv.c:100: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/bmv.c:112: undefined reference to `av_new_packet’
libavformat/libavformat.a(c93.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/c93.c:153: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/c93.c:191: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/c93.c:191: undefined reference to `av_free_packet’
libavformat/libavformat.a(cafenc.o): In function `caf_write_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/cafenc.c:203: undefined reference to `av_fast_realloc’
libavformat/libavformat.a(cafenc.o): In function `caf_write_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/cafenc.c:153: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(cdg.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/cdg.c:59: undefined reference to `av_free_packet’
libavformat/libavformat.a(cdxl.o): In function `cdxl_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/cdxl.c:137: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/cdxl.c:145: undefined reference to `av_shrink_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/cdxl.c:142: undefined reference to `av_free_packet’
libavformat/libavformat.a(dfa.o): In function `dfa_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/dfa.c:103: undefined reference to `av_free_packet’
libavformat/libavformat.a(dsicin.o): In function `cin_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/dsicin.c:185: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/dsicin.c:203: undefined reference to `av_shrink_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/dsicin.c:199: undefined reference to `av_free_packet’
libavformat/libavformat.a(dv.o): In function `dv_frame_offset’:
/root/ffmpeg-dmo-0.11.1/libavformat/dv.c:406: undefined reference to `avpriv_dv_codec_profile’
libavformat/libavformat.a(dv.o): In function `dv_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/dv.c:500: undefined reference to `avpriv_dv_frame_profile’
libavformat/libavformat.a(dv.o): In function `avpriv_dv_produce_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/dv.c:357: undefined reference to `avpriv_dv_frame_profile’
/root/ffmpeg-dmo-0.11.1/libavformat/dv.c:389: undefined reference to `av_init_packet’
libavformat/libavformat.a(dv.o): In function `dv_extract_audio_info’:
/root/ffmpeg-dmo-0.11.1/libavformat/dv.c:247: undefined reference to `av_init_packet’
libavformat/libavformat.a(dvenc.o): In function `dv_init_mux’:
/root/ffmpeg-dmo-0.11.1/libavformat/dvenc.c:316: undefined reference to `avpriv_dv_codec_profile’
libavformat/libavformat.a(dxa.o): In function `dxa_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/dxa.c:175: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/dxa.c:196: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/dxa.c:201: undefined reference to `av_free_packet’
libavformat/libavformat.a(electronicarts.o): In function `ea_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/electronicarts.c:525: undefined reference to `av_log_ask_for_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/electronicarts.c:526: undefined reference to `av_free_packet’
libavformat/libavformat.a(ffmdec.o): In function `ffm_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/ffmdec.c:426: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/ffmdec.c:441: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/ffmdec.c:430: undefined reference to `av_free_packet’
libavformat/libavformat.a(filmstripdec.o): In function `read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/filmstripdec.c:58: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(flacdec.o): In function `flac_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/flacdec.c:52: undefined reference to `avpriv_flac_parse_block_header’
/root/ffmpeg-dmo-0.11.1/libavformat/flacdec.c:92: undefined reference to `avpriv_flac_parse_streaminfo’
libavformat/libavformat.a(flacenc.o): In function `flac_write_trailer’:
/root/ffmpeg-dmo-0.11.1/libavformat/flacenc.c:97: undefined reference to `avpriv_flac_is_extradata_valid’
libavformat/libavformat.a(flacenc_header.o): In function `ff_flac_write_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/flacenc_header.c:37: undefined reference to `avpriv_flac_is_extradata_valid’
libavformat/libavformat.a(flic.o): In function `flic_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/flic.c:236: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/flic.c:220: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/flic.c:249: undefined reference to `av_free_packet’
libavformat/libavformat.a(flvdec.o): In function `flv_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/flvdec.c:662: undefined reference to `av_packet_new_side_data’
/root/ffmpeg-dmo-0.11.1/libavformat/flvdec.c:632: undefined reference to `avpriv_mpeg4audio_get_config’
libavformat/libavformat.a(flvenc.o): In function `flv_write_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/flvenc.c:424: undefined reference to `avcodec_get_name’
libavformat/libavformat.a(g723_1.o): In function `g723_1_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/g723_1.c:58: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/g723_1.c:68: undefined reference to `av_free_packet’
libavformat/libavformat.a(gsmdec.o): In function `gsm_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/gsmdec.c:47: undefined reference to `av_free_packet’
libavformat/libavformat.a(gxf.o): In function `gxf_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/gxf.c:510: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(gxf.o): In function `gxf_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/gxf.c:395: undefined reference to `avpriv_frame_rate_tab’
libavformat/libavformat.a(hls.o): In function `hls_read_seek’:
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:709: undefined reference to `av_free_packet’
libavformat/libavformat.a(hls.o): In function `reset_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:151: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:151: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:151: undefined reference to `av_init_packet’
libavformat/libavformat.a(hls.o): In function `free_variant_list’:
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:131: undefined reference to `av_free_packet’
libavformat/libavformat.a(hls.o): In function `reset_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:151: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:151: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:151: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:151: undefined reference to `av_init_packet’
libavformat/libavformat.a(hls.o): In function `hls_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/hls.c:540: undefined reference to `avcodec_copy_context’
libavformat/libavformat.a(icodec.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/icodec.c:138: undefined reference to `av_new_packet’
libavformat/libavformat.a(icodec.o): In function `read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/icodec.c:109: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(idcin.o): In function `idcin_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/idcin.c:266: undefined reference to `av_packet_new_side_data’
libavformat/libavformat.a(idroqdec.o): In function `roq_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/idroqdec.c:190: undefined reference to `av_new_packet’
libavformat/libavformat.a(iff.o): In function `iff_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/iff.c:367: undefined reference to `av_new_packet’
libavformat/libavformat.a(iff.o): In function `iff_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/iff.c:241: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(img2dec.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/img2dec.c:335: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/img2dec.c:335: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/img2dec.c:351: undefined reference to `av_free_packet’
libavformat/libavformat.a(ipmovie.o): In function `load_ipmovie_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/ipmovie.c:158: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/ipmovie.c:191: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/ipmovie.c:164: undefined reference to `av_packet_new_side_data’
libavformat/libavformat.a(isom.o): In function `ff_mp4_read_dec_config_descr’:
/root/ffmpeg-dmo-0.11.1/libavformat/isom.c:442: undefined reference to `avpriv_mpeg4audio_get_config’
/root/ffmpeg-dmo-0.11.1/libavformat/isom.c:446: undefined reference to `avpriv_mpa_freq_tab’
libavformat/libavformat.a(isom.o): In function `ff_mov_read_chan’:
/root/ffmpeg-dmo-0.11.1/libavformat/isom.c:503: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(iv8.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/iv8.c:95: undefined reference to `av_free_packet’
libavformat/libavformat.a(jacosubdec.o): In function `jacosub_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/jacosubdec.c:287: undefined reference to `av_new_packet’
libavformat/libavformat.a(jvdec.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/jvdec.c:162: undefined reference to `av_new_packet’
libavformat/libavformat.a(latmenc.o): In function `latm_decode_extradata’:
/root/ffmpeg-dmo-0.11.1/libavformat/latmenc.c:63: undefined reference to `avpriv_mpeg4audio_get_config’
libavformat/libavformat.a(latmenc.o): In function `latm_write_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/latmenc.c:187: undefined reference to `avpriv_copy_bits’
/root/ffmpeg-dmo-0.11.1/libavformat/latmenc.c:189: undefined reference to `avpriv_align_put_bits’
libavformat/libavformat.a(latmenc.o): In function `latm_write_frame_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/latmenc.c:123: undefined reference to `avpriv_copy_bits’
/root/ffmpeg-dmo-0.11.1/libavformat/latmenc.c:129: undefined reference to `avpriv_copy_pce_data’
/root/ffmpeg-dmo-0.11.1/libavformat/latmenc.c:119: undefined reference to `avpriv_copy_bits’
libavformat/libavformat.a(latmenc.o): In function `latm_write_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/latmenc.c:185: undefined reference to `avpriv_copy_bits’
libavformat/libavformat.a(lxfdec.o): In function `get_packet_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/lxfdec.c:135: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(lxfdec.o): In function `lxf_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/lxfdec.c:339: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/lxfdec.c:346: undefined reference to `av_free_packet’
libavformat/libavformat.a(matroskadec.o): In function `matroska_parse_block’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskadec.c:2059: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/matroskadec.c:2032: undefined reference to `av_new_packet’
libavformat/libavformat.a(matroskadec.o): In function `matroska_merge_packets’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskadec.c:1172: undefined reference to `av_grow_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/matroskadec.c:1176: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(matroskadec.o): In function `matroska_clear_queue’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskadec.c:1827: undefined reference to `av_free_packet’
libavformat/libavformat.a(matroskadec.o): In function `matroska_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskadec.c:1724: undefined reference to `avpriv_mpeg4audio_sample_rates’
libavformat/libavformat.a(matroskadec.o): In function `matroska_clear_queue’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskadec.c:1827: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/matroskadec.c:1827: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/matroskadec.c:1827: undefined reference to `av_free_packet’
libavformat/libavformat.a(matroskaenc.o): In function `mkv_query_codec’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskaenc.c:1299: undefined reference to `avcodec_get_type’
libavformat/libavformat.a(matroskaenc.o): In function `mkv_copy_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskaenc.c:1188: undefined reference to `av_fast_realloc’
libavformat/libavformat.a(matroskaenc.o): In function `mkv_write_trailer’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskaenc.c:1286: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(matroskaenc.o): In function `mkv_write_tracks’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskaenc.c:534: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(matroskaenc.o): In function `mkv_write_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskaenc.c:978: undefined reference to `av_init_packet’
libavformat/libavformat.a(matroskaenc.o): In function `get_aac_sample_rates’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskaenc.c:451: undefined reference to `avpriv_mpeg4audio_get_config’
libavformat/libavformat.a(matroskaenc.o): In function `put_xiph_codecpriv’:
/root/ffmpeg-dmo-0.11.1/libavformat/matroskaenc.c:431: undefined reference to `avpriv_split_xiph_headers’
libavformat/libavformat.a(microdvddec.o): In function `microdvd_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/microdvddec.c:121: undefined reference to `av_new_packet’
libavformat/libavformat.a(mm.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/mm.c:162: undefined reference to `av_new_packet’
libavformat/libavformat.a(mov.o): In function `mov_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/mov.c:2966: undefined reference to `av_packet_new_side_data’
libavformat/libavformat.a(mov.o): In function `mov_read_mdhd’:
/root/ffmpeg-dmo-0.11.1/libavformat/mov.c:807: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(mov.o): In function `mov_read_dac3′:
/root/ffmpeg-dmo-0.11.1/libavformat/mov.c:598: undefined reference to `avpriv_ac3_channel_layout_tab’
libavformat/libavformat.a(mov.o): In function `mov_read_dec3′:
/root/ffmpeg-dmo-0.11.1/libavformat/mov.c:626: undefined reference to `avpriv_ac3_channel_layout_tab’
libavformat/libavformat.a(mov.o): In function `ff_mov_read_stsd_entries’:
/root/ffmpeg-dmo-0.11.1/libavformat/mov.c:1461: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(movenc.o): In function `mov_write_audio_tag’:
/root/ffmpeg-dmo-0.11.1/libavformat/movenc.c:644: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(movenc.o): In function `mov_get_codec_tag’:
/root/ffmpeg-dmo-0.11.1/libavformat/movenc.c:900: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(movenc.o): In function `mov_write_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/movenc.c:3203: undefined reference to `av_get_bits_per_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/movenc.c:3190: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(movenc.o): In function `mov_create_chapter_track’:
/root/ffmpeg-dmo-0.11.1/libavformat/movenc.c:3063: undefined reference to `avcodec_alloc_context3′
libavformat/libavformat.a(movenchint.o): In function `ff_mov_init_hinting’:
/root/ffmpeg-dmo-0.11.1/libavformat/movenchint.c:40: undefined reference to `avcodec_alloc_context3′
libavformat/libavformat.a(movenchint.o): In function `ff_mov_add_hinted_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/movenchint.c:429: undefined reference to `av_init_packet’
libavformat/libavformat.a(mp3dec.o): In function `mp3_parse_vbr_tags’:
/root/ffmpeg-dmo-0.11.1/libavformat/mp3dec.c:96: undefined reference to `avpriv_mpegaudio_decode_header’
libavformat/libavformat.a(mp3dec.o): In function `mp3_read_probe’:
/root/ffmpeg-dmo-0.11.1/libavformat/mp3dec.c:59: undefined reference to `avpriv_mpa_decode_header’
libavformat/libavformat.a(mp3enc.o): In function `mp3_write_xing’:
/root/ffmpeg-dmo-0.11.1/libavformat/mp3enc.c:158: undefined reference to `avpriv_mpegaudio_decode_header’
/root/ffmpeg-dmo-0.11.1/libavformat/mp3enc.c:158: undefined reference to `avpriv_mpegaudio_decode_header’
/root/ffmpeg-dmo-0.11.1/libavformat/mp3enc.c:158: undefined reference to `avpriv_mpegaudio_decode_header’
/root/ffmpeg-dmo-0.11.1/libavformat/mp3enc.c:158: undefined reference to `avpriv_mpegaudio_decode_header’
/root/ffmpeg-dmo-0.11.1/libavformat/mp3enc.c:158: undefined reference to `avpriv_mpegaudio_decode_header’
libavformat/libavformat.a(mp3enc.o):/root/ffmpeg-dmo-0.11.1/libavformat/mp3enc.c:158: more undefined references to `avpriv_mpegaudio_decode_header’ follow
libavformat/libavformat.a(mp3enc.o): In function `mp3_write_xing’:
/root/ffmpeg-dmo-0.11.1/libavformat/mp3enc.c:165: undefined reference to `avpriv_mpa_freq_tab’
libavformat/libavformat.a(mp3enc.o): In function `mp3_write_packet_internal’:
/root/ffmpeg-dmo-0.11.1/libavformat/mp3enc.c:282: undefined reference to `avpriv_mpegaudio_decode_header’
libavformat/libavformat.a(mp3enc.o): In function `mp3_queue_flush’:
/root/ffmpeg-dmo-0.11.1/libavformat/mp3enc.c:328: undefined reference to `av_free_packet’
libavformat/libavformat.a(mpc.o): In function `mpc_read_seek’:
/root/ffmpeg-dmo-0.11.1/libavformat/mpc.c:219: undefined reference to `av_free_packet’
libavformat/libavformat.a(mpc.o): In function `mpc_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/mpc.c:154: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/mpc.c:168: undefined reference to `av_free_packet’
libavformat/libavformat.a(mpegts.o): In function `mpegts_raw_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/mpegts.c:2034: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/mpegts.c:2039: undefined reference to `av_free_packet’
libavformat/libavformat.a(mpegts.o): In function `mpegts_get_dts’:
/root/ffmpeg-dmo-0.11.1/libavformat/mpegts.c:2157: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/mpegts.c:2153: undefined reference to `av_init_packet’
libavformat/libavformat.a(mpegts.o): In function `new_pes_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/mpegts.c:661: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/mpegts.c:675: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(mpegts.o): In function `parse_MP4SLDescrTag’:
/root/ffmpeg-dmo-0.11.1/libavformat/mpegts.c:1133: undefined reference to `av_log_missing_feature’
libavformat/libavformat.a(mpegts.o): In function `ff_parse_mpeg2_descriptor’:
/root/ffmpeg-dmo-0.11.1/libavformat/mpegts.c:1357: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(mpegtsenc.o): In function `mpegts_write_packet_internal’:
/root/ffmpeg-dmo-0.11.1/libavformat/mpegtsenc.c:1024: undefined reference to `avpriv_mpv_find_start_code’
libavformat/libavformat.a(mtv.o): In function `mtv_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/mtv.c:117: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(mxfdec.o): In function `mxf_read_primer_pack’:
/root/ffmpeg-dmo-0.11.1/libavformat/mxfdec.c:409: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(mxfdec.o): In function `mxf_decrypt_triplet’:
/root/ffmpeg-dmo-0.11.1/libavformat/mxfdec.c:396: undefined reference to `av_shrink_packet’
libavformat/libavformat.a(mxfdec.o): In function `mxf_get_d10_aes3_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/mxfdec.c:335: undefined reference to `av_shrink_packet’
libavformat/libavformat.a(mxfdec.o): In function `mxf_read_packet_old’:
/root/ffmpeg-dmo-0.11.1/libavformat/mxfdec.c:2036: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(mxfdec.o): In function `mxf_get_d10_aes3_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/mxfdec.c:335: undefined reference to `av_shrink_packet’
libavformat/libavformat.a(mxfenc.o): In function `mxf_interleave_get_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/mxfenc.c:1850: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/mxfenc.c:1825: undefined reference to `av_free_packet’
libavformat/libavformat.a(mxfenc.o): In function `mxf_write_generic_sound_common’:
/root/ffmpeg-dmo-0.11.1/libavformat/mxfenc.c:898: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(mxg.o): In function `mxg_update_cache’:
/root/ffmpeg-dmo-0.11.1/libavformat/mxg.c:108: undefined reference to `av_fast_realloc’
libavformat/libavformat.a(ncdec.o): In function `nc_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/ncdec.c:86: undefined reference to `av_free_packet’
libavformat/libavformat.a(network.o): In function `ff_tls_init’:
/root/ffmpeg-dmo-0.11.1/libavformat/network.c:70: undefined reference to `avpriv_lock_avformat’
/root/ffmpeg-dmo-0.11.1/libavformat/network.c:97: undefined reference to `avpriv_unlock_avformat’
libavformat/libavformat.a(network.o): In function `ff_tls_deinit’:
/root/ffmpeg-dmo-0.11.1/libavformat/network.c:102: undefined reference to `avpriv_lock_avformat’
/root/ffmpeg-dmo-0.11.1/libavformat/network.c:120: undefined reference to `avpriv_unlock_avformat’
libavformat/libavformat.a(nsvdec.o): In function `nsv_read_close’:
/root/ffmpeg-dmo-0.11.1/libavformat/nsvdec.c:739: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/nsvdec.c:741: undefined reference to `av_free_packet’
libavformat/libavformat.a(nutdec.o): In function `decode_frame’:
/root/ffmpeg-dmo-0.11.1/libavformat/nutdec.c:815: undefined reference to `av_new_packet’
libavformat/libavformat.a(nutenc.o): In function `find_expected_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/nutenc.c:77: undefined reference to `avpriv_mpa_freq_tab’
/root/ffmpeg-dmo-0.11.1/libavformat/nutenc.c:77: undefined reference to `avpriv_mpa_bitrate_tab’
libavformat/libavformat.a(nuv.o): In function `nuv_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/nuv.c:220: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/nuv.c:235: undefined reference to `av_shrink_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/nuv.c:231: undefined reference to `av_free_packet’
libavformat/libavformat.a(oggdec.o): In function `ogg_read_page’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggdec.c:261: undefined reference to `av_log_missing_feature’
libavformat/libavformat.a(oggdec.o): In function `ogg_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggdec.c:637: undefined reference to `av_new_packet’
libavformat/libavformat.a(oggenc.o): In function `ogg_write_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggenc.c:416: undefined reference to `avpriv_split_xiph_headers’
/root/ffmpeg-dmo-0.11.1/libavformat/oggenc.c:416: undefined reference to `avpriv_split_xiph_headers’
libavformat/libavformat.a(oggenc.o): In function `ogg_build_flac_headers’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggenc.c:293: undefined reference to `avpriv_flac_is_extradata_valid’
libavformat/libavformat.a(oggparsedirac.o): In function `dirac_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsedirac.c:40: undefined reference to `avpriv_dirac_parse_sequence_header’
libavformat/libavformat.a(oggparseflac.o): In function `flac_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggparseflac.c:59: undefined reference to `avpriv_flac_parse_streaminfo’
libavformat/libavformat.a(oggparsetheora.o): In function `theora_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsetheora.c:75: undefined reference to `avcodec_set_dimensions’
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsetheora.c:85: undefined reference to `avcodec_set_dimensions’
libavformat/libavformat.a(oggparsevorbis.o): In function `vorbis_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsevorbis.c:340: undefined reference to `avpriv_vorbis_parse_frame’
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsevorbis.c:306: undefined reference to `avpriv_vorbis_parse_reset’
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsevorbis.c:309: undefined reference to `avpriv_vorbis_parse_frame’
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsevorbis.c:318: undefined reference to `avpriv_vorbis_parse_frame’
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsevorbis.c:335: undefined reference to `avpriv_vorbis_parse_reset’
libavformat/libavformat.a(oggparsevorbis.o): In function `fixup_vorbis_headers’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsevorbis.c:184: undefined reference to `av_xiphlacing’
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsevorbis.c:185: undefined reference to `av_xiphlacing’
libavformat/libavformat.a(oggparsevorbis.o): In function `vorbis_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/oggparsevorbis.c:280: undefined reference to `avpriv_vorbis_parse_extradata’
libavformat/libavformat.a(omadec.o): In function `oma_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/omadec.c:315: undefined reference to `av_log_ask_for_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/omadec.c:359: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(pcm.o): In function `ff_pcm_read_seek’:
/root/ffmpeg-dmo-0.11.1/libavformat/pcm.c:36: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(pcmdec.o): In function `raw_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/pcmdec.c:44: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(pmpdec.o): In function `pmp_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/pmpdec.c:134: undefined reference to `av_fast_malloc’
/root/ffmpeg-dmo-0.11.1/libavformat/pmpdec.c:128: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(psxstr.o): In function `str_read_close’:
/root/ffmpeg-dmo-0.11.1/libavformat/psxstr.c:291: undefined reference to `av_free_packet’
libavformat/libavformat.a(psxstr.o): In function `str_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/psxstr.c:266: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/psxstr.c:219: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/psxstr.c:220: undefined reference to `av_new_packet’
libavformat/libavformat.a(rawdec.o): In function `ff_raw_read_partial_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rawdec.c:115: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rawdec.c:125: undefined reference to `av_shrink_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rawdec.c:122: undefined reference to `av_free_packet’
libavformat/libavformat.a(rawdec.o): In function `ff_raw_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/rawdec.c:69: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(rawvideodec.o): In function `rawvideo_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rawvideodec.c:33: undefined reference to `avpicture_get_size’
libavformat/libavformat.a(riff.o): In function `ff_put_wav_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/riff.c:436: undefined reference to `av_get_audio_frame_duration’
/root/ffmpeg-dmo-0.11.1/libavformat/riff.c:442: undefined reference to `av_get_bits_per_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/riff.c:454: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(riff.o): In function `ff_parse_specific_params’:
/root/ffmpeg-dmo-0.11.1/libavformat/riff.c:682: undefined reference to `av_get_audio_frame_duration’
libavformat/libavformat.a(rmdec.o): In function `ff_rm_free_rmstream’:
/root/ffmpeg-dmo-0.11.1/libavformat/rmdec.c:130: undefined reference to `av_free_packet’
libavformat/libavformat.a(rmdec.o): In function `rm_read_audio_stream_info’:
/root/ffmpeg-dmo-0.11.1/libavformat/rmdec.c:264: undefined reference to `av_new_packet’
libavformat/libavformat.a(rmdec.o): In function `ff_rm_free_rmstream’:
/root/ffmpeg-dmo-0.11.1/libavformat/rmdec.c:130: undefined reference to `av_free_packet’
libavformat/libavformat.a(rmdec.o): In function `rm_assemble_video_frame’:
/root/ffmpeg-dmo-0.11.1/libavformat/rmdec.c:652: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rmdec.c:666: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rmdec.c:667: undefined reference to `av_new_packet’
libavformat/libavformat.a(rmdec.o): In function `ff_rm_retrieve_cache’:
/root/ffmpeg-dmo-0.11.1/libavformat/rmdec.c:849: undefined reference to `av_new_packet’
libavformat/libavformat.a(rmdec.o): In function `rm_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rmdec.c:909: undefined reference to `av_free_packet’
libavformat/libavformat.a(rpl.o): In function `rpl_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rpl.c:326: undefined reference to `av_free_packet’
libavformat/libavformat.a(rsodec.o): In function `rso_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rsodec.c:77: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(rsodec.o): In function `rso_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/rsodec.c:50: undefined reference to `av_get_bits_per_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/rsodec.c:52: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(rtpdec.o): In function `rtp_parse_packet_internal’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec.c:569: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec.c:547: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec.c:565: undefined reference to `av_new_packet’
libavformat/libavformat.a(rtpdec_amr.o): In function `amr_handle_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_amr.c:104: undefined reference to `av_new_packet’
libavformat/libavformat.a(rtpdec_asf.o): In function `asfrtp_parse_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_asf.c:274: undefined reference to `av_free_packet’
libavformat/libavformat.a(rtpdec_h263.o): In function `ff_h263_handle_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_h263.c:75: undefined reference to `av_new_packet’
libavformat/libavformat.a(rtpdec_h263_rfc2190.o): In function `h263_handle_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_h263_rfc2190.c:188: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_h263_rfc2190.c:108: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(rtpdec_h264.o): In function `h264_handle_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_h264.c:193: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_h264.c:295: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_h264.c:250: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_h264.c:300: undefined reference to `av_new_packet’
libavformat/libavformat.a(rtpdec_latm.o): In function `latm_parse_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_latm.c:97: undefined reference to `av_new_packet’
libavformat/libavformat.a(rtpdec_latm.o): In function `parse_fmtp’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_latm.c:159: undefined reference to `av_log_missing_feature’
libavformat/libavformat.a(rtpdec_mpeg4.o): In function `aac_parse_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_mpeg4.c:185: undefined reference to `av_new_packet’
libavformat/libavformat.a(rtpdec_qcelp.o): In function `return_stored_frame’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qcelp.c:190: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qcelp.c:178: undefined reference to `av_new_packet’
libavformat/libavformat.a(rtpdec_qcelp.o): In function `store_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qcelp.c:138: undefined reference to `av_new_packet’
libavformat/libavformat.a(rtpdec_qdm2.o): In function `qdm2_restore_block’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qdm2.c:198: undefined reference to `av_new_packet’
libavformat/libavformat.a(rtpdec_qt.o):/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qt.c:55: more undefined references to `av_new_packet’ follow
libavformat/libavformat.a(rtpdec_qt.o): In function `qt_rtp_parse_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qt.c:227: undefined reference to `av_log_missing_feature’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qt.c:179: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qt.c:205: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qt.c:214: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qt.c:100: undefined reference to `av_log_missing_feature’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qt.c:164: undefined reference to `av_log_missing_feature’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_qt.c:175: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(rtpdec_svq3.o): In function `svq3_parse_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_svq3.c:100: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_svq3.c:95: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(rtpdec_vp8.o): In function `prepare_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_vp8.c:41: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_vp8.c:41: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_vp8.c:41: undefined reference to `av_init_packet’
libavformat/libavformat.a(rtpdec_vp8.o): In function `vp8_handle_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_vp8.c:63: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(rtpdec_xiph.o): In function `parse_packed_headers’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_xiph.c:296: undefined reference to `av_xiphlacing’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_xiph.c:297: undefined reference to `av_xiphlacing’
libavformat/libavformat.a(rtpdec_xiph.o): In function `xiph_handle_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_xiph.c:205: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_xiph.c:142: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_xiph.c:95: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_xiph.c:159: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpdec_xiph.c:197: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(rtpenc.o): In function `rtp_write_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpenc.c:94: undefined reference to `avcodec_get_name’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpenc.c:131: undefined reference to `av_get_audio_frame_duration’
libavformat/libavformat.a(rtpenc.o): In function `rtp_write_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpenc.c:463: undefined reference to `av_packet_get_side_data’
libavformat/libavformat.a(rtpenc_chain.o): In function `ff_rtp_chain_mux_open’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpenc_chain.c:64: undefined reference to `avcodec_copy_context’
libavformat/libavformat.a(rtpenc_mpv.o): In function `ff_rtp_send_mpegvideo’:
/root/ffmpeg-dmo-0.11.1/libavformat/rtpenc_mpv.c:59: undefined reference to `avpriv_mpv_find_start_code’
/root/ffmpeg-dmo-0.11.1/libavformat/rtpenc_mpv.c:59: undefined reference to `avpriv_mpv_find_start_code’
libavformat/libavformat.a(sapdec.o): In function `sap_fetch_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/sapdec.c:222: undefined reference to `avcodec_copy_context’
/root/ffmpeg-dmo-0.11.1/libavformat/sapdec.c:218: undefined reference to `av_free_packet’
libavformat/libavformat.a(sapdec.o): In function `sap_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/sapdec.c:173: undefined reference to `avcodec_copy_context’
libavformat/libavformat.a(sdp.o): In function `xiph_extradata2config’:
/root/ffmpeg-dmo-0.11.1/libavformat/sdp.c:271: undefined reference to `avpriv_split_xiph_headers’
libavformat/libavformat.a(sdp.o): In function `extradata2psets’:
/root/ffmpeg-dmo-0.11.1/libavformat/sdp.c:169: undefined reference to `av_bitstream_filter_init’
/root/ffmpeg-dmo-0.11.1/libavformat/sdp.c:185: undefined reference to `av_bitstream_filter_filter’
/root/ffmpeg-dmo-0.11.1/libavformat/sdp.c:186: undefined reference to `av_bitstream_filter_close’
/root/ffmpeg-dmo-0.11.1/libavformat/sdp.c:181: undefined reference to `av_bitstream_filter_close’
/root/ffmpeg-dmo-0.11.1/libavformat/sdp.c:172: undefined reference to `avpriv_mpeg4audio_sample_rates’
libavformat/libavformat.a(segafilm.o): In function `film_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/segafilm.c:272: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/segafilm.c:262: undefined reference to `av_new_packet’
libavformat/libavformat.a(sierravmd.o): In function `vmd_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/sierravmd.c:251: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/sierravmd.c:262: undefined reference to `av_free_packet’
libavformat/libavformat.a(siff.o): In function `siff_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/siff.c:209: undefined reference to `av_new_packet’
libavformat/libavformat.a(smacker.o): In function `smacker_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/smacker.c:338: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/smacker.c:324: undefined reference to `av_new_packet’
libavformat/libavformat.a(smjpegdec.o): In function `smjpeg_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/smjpegdec.c:55: undefined reference to `av_log_ask_for_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/smjpegdec.c:80: undefined reference to `av_log_ask_for_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/smjpegdec.c:103: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(smjpegenc.o): In function `smjpeg_write_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/smjpegenc.c:70: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(spdifdec.o): In function `spdif_get_offset_and_codec’:
/root/ffmpeg-dmo-0.11.1/libavformat/spdifdec.c:95: undefined reference to `av_log_missing_feature’
/root/ffmpeg-dmo-0.11.1/libavformat/spdifdec.c:60: undefined reference to `avpriv_aac_parse_header’
libavformat/libavformat.a(spdifdec.o): In function `spdif_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/spdifdec.c:184: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/spdifdec.c:182: undefined reference to `av_log_ask_for_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/spdifdec.c:199: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/spdifdec.c:191: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/spdifdec.c:216: undefined reference to `av_log_missing_feature’
/root/ffmpeg-dmo-0.11.1/libavformat/spdifdec.c:210: undefined reference to `av_free_packet’
libavformat/libavformat.a(spdifenc.o): In function `spdif_write_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/spdifenc.c:526: undefined reference to `av_fast_malloc’
libavformat/libavformat.a(spdifenc.o): In function `spdif_header_dts’:
/root/ffmpeg-dmo-0.11.1/libavformat/spdifenc.c:311: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(spdifenc.o): In function `spdif_header_dts4′:
/root/ffmpeg-dmo-0.11.1/libavformat/spdifenc.c:228: undefined reference to `av_fast_malloc’
libavformat/libavformat.a(spdifenc.o): In function `spdif_header_truehd’:
/root/ffmpeg-dmo-0.11.1/libavformat/spdifenc.c:417: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(spdifenc.o): In function `spdif_header_eac3′:
/root/ffmpeg-dmo-0.11.1/libavformat/spdifenc.c:122: undefined reference to `av_fast_realloc’
libavformat/libavformat.a(spdifenc.o): In function `spdif_header_aac’:
/root/ffmpeg-dmo-0.11.1/libavformat/spdifenc.c:355: undefined reference to `avpriv_aac_parse_header’
libavformat/libavformat.a(srtdec.o): In function `srt_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/srtdec.c:86: undefined reference to `av_new_packet’
libavformat/libavformat.a(swfenc.o): In function `swf_write_audio’:
/root/ffmpeg-dmo-0.11.1/libavformat/swfenc.c:451: undefined reference to `av_get_audio_frame_duration’
libavformat/libavformat.a(thp.o): In function `thp_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/thp.c:182: undefined reference to `av_free_packet’
libavformat/libavformat.a(tiertexseq.o): In function `seq_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/tiertexseq.c:255: undefined reference to `av_new_packet’
libavformat/libavformat.a(vocdec.o): In function `ff_voc_get_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/vocdec.c:98: undefined reference to `av_get_bits_per_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/vocdec.c:98: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(vqf.o): In function `vqf_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/vqf.c:223: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/vqf.c:235: undefined reference to `av_free_packet’
libavformat/libavformat.a(wc3movie.o): In function `wc3_read_close’:
/root/ffmpeg-dmo-0.11.1/libavformat/wc3movie.c:289: undefined reference to `av_free_packet’
libavformat/libavformat.a(wc3movie.o): In function `wc3_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/wc3movie.c:101: undefined reference to `av_init_packet’
libavformat/libavformat.a(westwood_aud.o): In function `wsaud_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/westwood_aud.c:153: undefined reference to `av_new_packet’
libavformat/libavformat.a(westwood_aud.o): In function `wsaud_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/westwood_aud.c:117: undefined reference to `av_log_ask_for_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/westwood_aud.c:106: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(wv.o): In function `wv_read_seek’:
/root/ffmpeg-dmo-0.11.1/libavformat/wv.c:358: undefined reference to `av_free_packet’
libavformat/libavformat.a(wv.o): In function `wv_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/wv.c:265: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/wv.c:313: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/wv.c:308: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/wv.c:286: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/wv.c:293: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/wv.c:272: undefined reference to `av_free_packet’
libavformat/libavformat.a(xmv.o): In function `xmv_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/xmv.c:145: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(xwma.o): In function `xwma_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/xwma.c:90: undefined reference to `av_log_ask_for_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/xwma.c:106: undefined reference to `av_log_ask_for_sample’
libavformat/libavformat.a(yop.o): In function `yop_read_seek’:
/root/ffmpeg-dmo-0.11.1/libavformat/yop.c:201: undefined reference to `av_free_packet’
libavformat/libavformat.a(yop.o): In function `yop_read_close’:
/root/ffmpeg-dmo-0.11.1/libavformat/yop.c:176: undefined reference to `av_free_packet’
libavformat/libavformat.a(yop.o): In function `yop_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/yop.c:134: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/yop.c:169: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/yop.c:163: undefined reference to `av_shrink_packet’
libavformat/libavformat.a(yuv4mpeg.o): In function `yuv4_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/yuv4mpeg.c:518: undefined reference to `avpicture_get_size’
libavformat/libavformat.a(yuv4mpeg.o): In function `yuv4_write_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/yuv4mpeg.c:189: undefined reference to `avcodec_get_chroma_sub_sample’
libavformat/libavformat.a(4xm.o): In function `fourxm_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/4xm.c:296: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/4xm.c:305: undefined reference to `av_free_packet’
libavformat/libavformat.a(a64.o): In function `a64_write_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/a64.c:130: undefined reference to `av_new_packet’
libavformat/libavformat.a(a64.o): In function `a64_write_trailer’:
/root/ffmpeg-dmo-0.11.1/libavformat/a64.c:162: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(ac3dec.o): In function `ac3_eac3_probe’:
/root/ffmpeg-dmo-0.11.1/libavformat/ac3dec.c:48: undefined reference to `avpriv_ac3_parse_header’
libavformat/libavformat.a(act.o): In function `read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/act.c:122: undefined reference to `av_new_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/act.c:120: undefined reference to `av_new_packet’
libavformat/libavformat.a(adtsenc.o): In function `ff_adts_decode_extradata’:
/root/ffmpeg-dmo-0.11.1/libavformat/adtsenc.c:40: undefined reference to `avpriv_mpeg4audio_get_config’
/root/ffmpeg-dmo-0.11.1/libavformat/adtsenc.c:72: undefined reference to `avpriv_copy_pce_data’
libavformat/libavformat.a(adxdec.o): In function `adx_read_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/adxdec.c:51: undefined reference to `av_free_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/adxdec.c:55: undefined reference to `av_free_packet’
libavformat/libavformat.a(adxdec.o): In function `adx_read_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/adxdec.c:90: undefined reference to `avpriv_adx_decode_header’
libavformat/libavformat.a(aiffdec.o): In function `get_aiff_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/aiffdec.c:124: undefined reference to `av_get_bits_per_sample’
/root/ffmpeg-dmo-0.11.1/libavformat/aiffdec.c:155: undefined reference to `av_get_audio_frame_duration’
libavformat/libavformat.a(aiffenc.o): In function `aiff_write_header’:
/root/ffmpeg-dmo-0.11.1/libavformat/aiffenc.c:82: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(audiointerleave.o): In function `ff_audio_interleave_init’:
/root/ffmpeg-dmo-0.11.1/libavformat/audiointerleave.c:60: undefined reference to `av_get_bits_per_sample’
libavformat/libavformat.a(audiointerleave.o): In function `ff_interleave_new_audio_packet’:
/root/ffmpeg-dmo-0.11.1/libavformat/audiointerleave.c:87: undefined reference to `av_new_packet’
libavformat/libavformat.a(id3v2.o): In function `ff_id3v2_parse’:
/root/ffmpeg-dmo-0.11.1/libavformat/id3v2.c:660: undefined reference to `av_fast_malloc’
/root/ffmpeg-dmo-0.11.1/libavformat/id3v2.c:671: undefined reference to `av_fast_malloc’
libavformat/libavformat.a(id3v2.o): In function `ff_id3v2_parse_apic’:
/root/ffmpeg-dmo-0.11.1/libavformat/id3v2.c:801: undefined reference to `av_init_packet’
/root/ffmpeg-dmo-0.11.1/libavformat/id3v2.c:813: undefined reference to `av_destruct_packet’
libavformat/libavformat.a(mms.o): In function `ff_mms_asf_header_parser’:
/root/ffmpeg-dmo-0.11.1/libavformat/mms.c:104: undefined reference to `av_fast_realloc’
collect2: ld returned 1 exit status
make: *** [ffmpeg_g] Error 1
root@raspberrypi:~/ffmpeg-dmo-0.11.1#
Can’t say I know what that means…
Perhaps try a make clean and then do a make && make install as root ?
Followed the instructions to the letter, but I’m getting the following when attempting to stream the cam:
[NULL @ 0x2ce1520] Requested output format ‘video4linux2’ is not a suitable output format
Ideas? qv4l2 shows the webcam and I can see the content there, so I know the camera is working and detected.
Can you paste the entire command you used ?
I’m getting a page not found every time I try to leave a comment. This is a test post.
Not sure why…this post seems to have worked.
Every time I try to post my code, I get a 404 page not found error.
So instead, I’ll post the URL of the file in my Dropbox
https://dl.dropbox.com/u/566712/Raspberry%20Pi%20webcam%20errors.txt
Not sure why you get the 404 but i’ll look into it. In regards to the script, it needs to be run as root or sudo in order for it to open up the lower ports. Higher ports do not have the same limitation though.
OK, I moved everything to port 8080. I issue webcam.sh and it prints what you see below and totally hangs the SSH session.
ffserver version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 29 2012 23:28:12 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 29 2012 23:28:12 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x2407620] [3]Capabilities: 4000001
Change the verbosity to debug and see what you get.
OK. This is what I get. The camera is detected properly when I use ‘lsusb’.
video4linux2,v4l2 @ 0x1296620] Estimating duration from bitrate, this may be inaccurate
Input #0, video4linux2,v4l2, from ‘/dev/video0’:
Duration: N/A, bitrate: 24576 kb/s
Stream #0:0, 0, 1/1000000: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 640×480, 1/5, 24576 kb/s, 5 tbr, 1000k tbn, 5 tbc
[ffm @ 0x12988e0] Format ffm probed with size=2048 and score=101
[AVIOContext @ 0x1296d30] Statistics: 4096 bytes read, 0 seeks
[buffer @ 0x12988e0] Setting entry with key ‘video_size’ to value ‘640×480’
[buffer @ 0x12988e0] Setting entry with key ‘pix_fmt’ to value ‘1’
[buffer @ 0x12988e0] Setting entry with key ‘time_base’ to value ‘1/5’
[buffer @ 0x12988e0] Setting entry with key ‘pixel_aspect’ to value ‘0/1’
[buffer @ 0x12988e0] Setting entry with key ‘sws_param’ to value ‘flags=2’
[buffer @ 0x12988e0] Setting entry with key ‘frame_rate’ to value ‘5/1’
[graph 0 input from stream 0:0 @ 0x129bcb0] w:640 h:480 pixfmt:yuyv422 tb:1/5 fr:5/1 sar:0/1 sws_param:flags=2
[scaler for output stream 0:0 @ 0x12989d0] picking yuvj422p out of 2 ref:yuyv422 alpha:0
[graph 0 input from stream 0:0 @ 0x129bcb0] TB:0.200000 FRAME_RATE:5.000000 SAMPLE_RATE:nan
[scaler for output stream 0:0 @ 0x12989d0] w:640 h:480 fmt:yuyv422 sar:0/1 -> w:640 h:480 fmt:yuvj422p sar:0/1 flags:0x4
[mjpeg @ 0x129c460] detected 1 logical cores
[mjpeg @ 0x129c460] intra_quant_bias = 96 inter_quant_bias = 0
Output #0, ffm, to ‘http://localhost:8000/webcam.ffm’:
Metadata:
encoder : Lavf54.29.104
Stream #0:0, 0, 1/1000000: Video: mjpeg, yuvj422p, 640×480, 1/5, q=1-10, 2000 kb/s, 1000k tbn, 5 tbc
Stream mapping:
Stream #0:0 -> #0:0 (rawvideo -> mjpeg)
Press [q] to stop, [?] for help
[video4linux2,v4l2 @ 0x1296620] ioctl(VIDIOC_DQBUF): Input/output error
/dev/video0: Input/output error
[output stream 0:0 @ 0x12aabc0] EOF on sink link output stream 0:0:default.
No more output streams to write to, finishing.
frame= 0 fps=0.0 q=0.0 Lsize= 4kB time=00:00:00.00 bitrate= 0.0kbits/s
video:0kB audio:0kB subtitle:0 global headers:0kB muxing overhead inf%
Output file is empty, nothing was encoded (check -ss / -t / -frames parameters if used)
pi@raspberrypi /usr/sbin $
What’s the command you’re running to start streaming ?
ioctl(VIDIOC_DQBUF): Input/output error
Not sure what that means but that seems to be the issue…
Try recording to a file via ffmpeg and see if that works.
I am using a “Logitech, Inc. HD Webcam C910” with Pi. When I run the script webcam.sh, all seems to run well, but when I access the stream via the web address (with Firefox) I obtain this message “This feed is already being received” What happens? I try too with VLC, but it doesn’t work.
This is my console output:
ffserver version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 29 2012 20:39:30 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Sep 29 2012 20:39:30 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x13e9620] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x13e9620] Estimating duration from bitrate, this may be inaccurate
Input #0, video4linux2,v4l2, from ‘/dev/video0’:
Duration: N/A, start: 119.414098, bitrate: 73728 kb/s
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 640×480, 73728 kb/s, 15 tbr, 1000k tbn, 15 tbc
[graph 0 input from stream 0:0 @ 0x13ebb50] w:640 h:480 pixfmt:yuyv422 tb:1/15 fr:15/1 sar:0/1 sws_param:flags=2
[graph 0 input from stream 0:0 @ 0x13ebb50] TB:0.066667 FRAME_RATE:15.000000 SAMPLE_RATE:nan
[scaler for output stream 0:0 @ 0x13ef030] w:640 h:480 fmt:yuyv422 sar:0/1 -> w:640 h:480 fmt:yuvj422p sar:0/1 flags:0x4
Output #0, ffm, to ‘http://localhost/webcam.ffm’:
Metadata:
encoder : Lavf54.29.104
Stream #0:0: Video: mjpeg, yuvj422p, 640×480, q=1-10, 2000 kb/s, 1000k tbn, 15 tbc
Stream mapping:
Stream #0:0 -> #0:0 (rawvideo -> mjpeg)
Press [q] to stop, [?] for help
frame= 89 fps=4.4 q=1.6 Lsize= 592kB time=00:00:05.93 bitrate= 817.4kbits/s
Not sure…Never seen that before.
How do you open it with VLC ?
Do you connect your webcam Webcam C910 to Raspberry Pi direct or via USB Hub?
I have same webcam , but it’s don’t work with Raspberry (see my comment 17)
Hello
I’m not quite Sure but I think you have to apt-get update once again after 1.3 (apt-get install deb-multimedia-keyring) ..
Greetings Volker
I think you are right actually.
[…] ist muss Dieser neu installiert und compiliert werden. Genauere Informationen hierzu bitte unter Dieser URLย nachlesen. Es ist hier noch anzumerken, Punkt 1.2 (apt-get update) zu einer Fehlermeldung fรผhrt, […]
Tried to follow your steps. FFMpeg is up to version 1.0 now.
But when compiling I get an error- here is a screenshot:
http://postimage.org/image/fa0dq3skv/
Can’t say I’ve seen that before.
Are you compiling with swap activated ? Try activating the swap and trying again.
Sorry, bit of a linux noob – can you be more verbose?
Run the command “free” and paste up what you get. That will tell us whether you already have the swap file or swap partition enabled already
Think my previous issue was caused by a dodgy sd card. Tried a diff card and got a different error:
http://postimage.org/image/zdq8ncj2n/
lol can’t say I’ve seen that error either.
Same thing I guess, check to see if swap space / file is enabled.
Did you copy the files from the old SD card or is this a new download of the source ?
Maybe it needs a make clean if they’re old files.
Its a new download of source.
Ill try those things tonight when I get home. This looks like a more “proper” error though. And seems to be a compile error rather than the “Bus Error” I got last time
Thanks for this great walkthrough! I got my pi up and running with a quickcam 9000. The only thing is that I get 1-2 fps average, and there’s a 3-10 second delay, depending on the different settings I’ve tried. Is there any way to improve this? I’m hoping to rig up my pi with a battery and long-range wifi adapter and use it for aerial views from an RC glider plane.
I’ve tried:
ffmpeg -loglevel info -r 10 -vcodec mjpeg -s 320ร240 -f video4linux2 -i /dev/video0 http://localhost/webcam.ffm
But it gives me: /dev/video0: Could not find codec parameters
And i’ve also tried this that I found somewhere:
ffmpeg -r 25 -s 320×240 -f video4linux2 -i /dev/video0 -f rawvideo http://localhost/webcam.ffm
But it gives: av_interleaved_write_frame(): Connection reset by peer.
Any help would be appreciated, thanks!
Thanks for reading !
If you can check the capabilities of the webcam via v4l2-ctrl or uvcdynctrl to see what’s native to the webcam, you may be able to use optimised settings for lower cpu usage.
Otherwise you may have to just try and tweak the settings as all webcams are different so what works for me may not work for you.
Also try bumping up the loglevel to verbose so you can see if the cam is running into any buffer over flow errors or anything which may be slowing things down.
You could also try using the tool mjpeg-streamer and see how you go with that.
here’s my output on the raspi… it just kinda stops forever at the end of this…
pi@raspberrypi ~ $ /usr/sbin/webcam.sh
ffserver version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Oct 3 2012 09:24:54 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Oct 3 2012 09:24:54 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x2215620] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x2215620] The driver changed the time per frame from 1/5 to 1/30
Are you running ffmpeg with the verbose paramter ? Try with the debug flag also to see if more information comes up.
Sounds like the fps you’re trying to use is not supported. Some webcams are picky about these things, so you might need tl try a different fps
Also you can try to run just the ffmpeg part of the webcam.sh file but replace http://localhost/webcam.ffm with temp.avi and see what that says.
running in verbose mode generates the same results. outputting to temp.avi also outputs the same results as below, stopping at the same place. You can see below that I’ve switched framrate to 30 – but it still freezes at the same point.
ffmpeg -v verbose -r 30 -s 320x240 -f video4linux2 -i /dev/video0 http://localhost:8080/webcam.ffm
ffmpeg version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Oct 3 2012 09:24:54 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x255d620] [3]Capabilities: 4000001
This is debug mode (i tried it with both -r 30 & -r 5 as well as 640×480 and 320×240)
pi@raspberrypi ~ $ ffmpeg -v debug -r 30 -s 640x480 -f video4linux2 -i /dev/video0 /home/pete/temp.avi -debug
ffmpeg version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Oct 3 2012 09:24:54 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x1dc5620] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x1dc5620] The V4L2 driver set input_id: 0, input: Camera 1
[video4linux2,v4l2 @ 0x1dc5620] Setting time per frame to 1/30
It just doesn’t go any further.
What webcam are you using ?
You might need to use v4l2-ctl to discover what resolutions and fps your webcam supports and set ffmpeg to that manually.
One step forward two steps back…
Ok, so I discovered that it was my USB hub that was preventing me from going forward. By plugging my webcam directly into the board, i’m able to proceed further.
pi@raspberrypi ~ $ ffmpeg -v verbose -r 30 -s 320x240 -f video4linux2 -i /dev/video0 http://localhost:8080/webcam.ffm
ffmpeg version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Oct 3 2012 09:24:54 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x1867620] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x1867620] Estimating duration from bitrate, this may be inaccurate
Input #0, video4linux2,v4l2, from '/dev/video0':
Duration: N/A, start: 488.703831, bitrate: 36864 kb/s
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 320x240, 36864 kb/s, 30 tbr, 1000k tbn, 30 tbc
[tcp @ 0x1867da0] TCP connection to localhost:8080 failed: Connection refused
http://localhost:8080/webcam.ffm: Input/output error
When I tried to just output to temp.avi, it ran for only a few secs.
pi@raspberrypi ~ $ ffmpeg -v verbose -r 30 -s 320x240 -f video4linux2 -i /dev/video0 temp.avi
ffmpeg version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Oct 3 2012 09:24:54 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x2acc620] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x2acc620] The v4l2 frame is 736 bytes, but 153600 bytes are expected
[video4linux2,v4l2 @ 0x2acc620] Estimating duration from bitrate, this may be inaccurate
Input #0, video4linux2,v4l2, from '/dev/video0':
Duration: N/A, bitrate: 36864 kb/s
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 320x240, 36864 kb/s, 30 tbr, 1000k tbn, 30 tbc
[graph 0 input from stream 0:0 @ 0x2ad0c30] w:320 h:240 pixfmt:yuyv422 tb:1/30 fr:30/1 sar:0/1 sws_param:flags=2
[format @ 0x2ad0de0] auto-inserting filter 'auto-inserted scaler 0' between the filter 'Parsed_null_0' and the filter 'format'
[graph 0 input from stream 0:0 @ 0x2ad0c30] TB:0.033333 FRAME_RATE:30.000000 SAMPLE_RATE:nan
[auto-inserted scaler 0 @ 0x2ad12e0] w:320 h:240 fmt:yuyv422 sar:0/1 -> w:320 h:240 fmt:yuv420p sar:0/1 flags:0x4
Output #0, avi, to 'temp.avi':
Metadata:
ISFT : Lavf54.29.104
Stream #0:0: Video: mpeg4 (FMP4 / 0x34504D46), yuv420p, 320x240, q=2-31, 200 kb/s, 30 tbn, 30 tbc
Stream mapping:
Stream #0:0 -> #0:0 (rawvideo -> mpeg4)
Press [q] to stop, [?] for help
The v4l2 frame is 8316 bytes, but 153600 bytes are expectedbitrate= 403.5kbits/s
/dev/video0: Invalid data found when processing input
No more output streams to write to, finishing.
frame= 93 fps= 17 q=3.3 Lsize= 152kB time=00:00:03.10 bitrate= 401.2kbits/s
video:144kB audio:0kB subtitle:0 global headers:0kB muxing overhead 5.393825%
Please note, I also tried to use v4l2-ctl
pi@raspberrypi ~ $ v4l2-ctl
-bash: v4l2-ctl: command not found
Thanks for your help.
P
V4l2-ctl is a program that normally needs installing via apt-get. It shows you the capabilities of your webcam.
I would try and install that, then use it to find out what resolutions and fps the cam supports.
pi@raspberrypi ~ $ sudo apt-get install v4l2-ctl
Reading package lists… Done
Building dependency tree
Reading state information… Done
E: Unable to locate package v4l2-ctl
Might need to do a apt-cache search v4l2, can’t remember the exact package name sorry !
pi@raspberrypi ~ $ v4l2-ctl –all
Driver Info (not using libv4l2):
Driver name : uvcvideo
Card type : USB2.0 Camera
Bus info : usb-bcm2708_usb-1.2.6
Driver version: 3.2.27
Capabilities : 0x04000001
Video Capture
Streaming
Format Video Capture:
Width/Height : 320/240
Pixel Format : ‘YUYV’
Field : None
Bytes per Line: 640
Size Image : 153600
Colorspace : SRGB
Crop Capability Video Capture:
Bounds : Left 0, Top 0, Width 320, Height 240
Default : Left 0, Top 0, Width 320, Height 240
Pixel Aspect: 1/1
Video input : 0 (Camera 1: ok)
Streaming Parameters Video Capture:
Capabilities : timeperframe
Frames per second: 30.000 (30/1)
Read buffers : 0
and sorry, still getting:
Input #0, video4linux2,v4l2, from ‘/dev/video0’:
Duration: N/A, start: 9148.847836, bitrate: 36864 kb/s
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 320×240, 36864 kb/s, 30 tbr, 1000k tbn, 30 tbc
[tcp @ 0x10add80] TCP connection to localhost:8080 failed: Connection refused
http://localhost:8080/webcam.mjpeg: Input/output error
with no other known server running (well except ssh).
Cheers,
P
Ok, made some learnings…
sudo apt-get install v4l-utils
Gets the v4l2-ctl – and
v4l2-ctl --all
gets the info about the webcam.
I’m still getting this error every few minutes…
“The v4l2 frame is 367 bytes, but 153600 bytes are expected
/dev/video0: Invalid data found when processing input
No more output streams to write to, finishing.”
Here’s the pastebin of my v4l2-ctl: http://pastebin.com/NqGxTjtP
Should I tune my output better? or is there a way to ignore or force ffserver to accept these wonky frame byte numbers?
I get the same issue depending on the webcam. I haven’t been able to resolve this issue as of yet so my workaround was to have a script run every few minutes to check to see whether ffmpeg was running and if it wasn’t, it would run ffmpeg again
Mine fails every minute or so…
What does your script look like that checks and runs again?
Cheers,
P
Something along the lines of this – I’m writing it from the top of my head so this probably won’t work, but you can always give it a shot
Hopefully I still have the proper script that I was using at home, otherwise I’ll just write up another one ๐
#!/bin/bash
ffmpeg=`ps aux | grep ffmpeg | wc -l`
if [[ $ffmpeg -ne 1 ]]; do
run ffmpeg command that you want to use
fi
^ and then schedule that to run every minute or 5 minutes or whatever via cron.
I think the bigger solution is here:
http://web.archiveorange.com/archive/v/yR2T4eDRCIV1ZzyRoBve
I just don’t know what I’m supposed to do with it…
Can you make sense of it?
That looks like some patching that was applied to the ffmpeg code.
Being from 3 years ago, I would assume that the necessary changes have already made it into the ffmpeg code base, but I could be mistaken.
I’ll have a closer look when I get home.
Edit – Actually I think that the code on that page has definitely been applied as ffmpeg can capture mjpeg streams from webcams.
Thanks so much for your help, we just want to include a tag here that says “ignore errors,” or skip “errors”.
I’ve been hanging out in the ffmpeg irc room in freenode and I still don’t have the answer.
I’m sure between us we’ll figure it out.
Thank you for your guide, but I’m getting some errors:
pi@raspberrypi ~/ffmpeg-dmo $ ./startstreaming.sh
ffserver version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Oct 24 2012 21:56:05 with gcc 4.6 (Debian 4.6.3-8+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
ffmpeg version 1.0 Copyright (c) 2000-2012 the FFmpeg developers
built on Oct 24 2012 21:56:05 with gcc 4.6 (Debian 4.6.3-8+rpi1)
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libswresample 0. 15.100 / 0. 15.100
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x1c48620] [3]Capabilities: 5000001
[video4linux2,v4l2 @ 0x1c48620] Cannot find a proper format for codec_id 0, pix_fmt -1.
/dev/video0: Input/output error
Any ideas?
What commands are in the startstreaming.sh file ? Are you using a vcodec option ? May have to remove that…
I’m using the same command you wrote in your guide
Maybe need the vcodec option then. Also may need to check what your webcam supports.
I’m not sure about which vcodec option I should use.
Running v4l-info outputs:
video capture
VIDIOC_ENUM_FMT(0,VIDEO_CAPTURE)
index : 0
type : VIDEO_CAPTURE
flags : 0
description : "PJPG"
pixelformat : 0x47504a50 [PJPG]
VIDIOC_G_FMT(VIDEO_CAPTURE)
type : VIDEO_CAPTURE
fmt.pix.width : 640
fmt.pix.height : 480
fmt.pix.pixelformat : 0x47504a50 [PJPG]
fmt.pix.field : NONE
fmt.pix.bytesperline : 640
fmt.pix.sizeimage : 115790
fmt.pix.colorspace : JPEG
fmt.pix.priv : 0
I guess try PJPG ? Never seen that before…also try mjpeg
Same error with -vcodec mjpeg (PJPG outputs ‘Unknown decoder’).
I think my webcam sucks…
I get an error of
Cannot read file ‘ffmpeg2pass-0.log’: No such file or directory
Error reading log file ‘ffmpeg2pass-0.log’ for pass-2 encoding
Segmentation fault
Did you compile ffmpeg from sources from deb-multimedia.org ?
Yes, I did.
Can you paste the output when you run the script file ? and also the script file itself as well ?
Perhaps it’s not catching the error when it can’t read the log file.
[…] http://sirlagz.net/2012/08/04/how-to-stream-a-webcam-from-the-raspberry-pi/ http://www.raspberrypi.org/phpBB3/viewtopic.php?f=29&t=9226 Posteado en: conocimiento libre, […]
Iam beginner and I have a question
8. Run make && make install to compile and install ffmpeg
That’s means I should just write in sudo:
sudo make && make install
?
Sudo make && make install
It worked fine for me! Thank you very much for this post!!
What sort of frame rate have you managed with the Raspberry Pi managing the streaming?
From what I recall, I had 5 fps with very little delay. I haven’t played around with my webcams in a little while though so things will probably have improved.
I’ve followed the above but I get the following errors
/usr/sbin/webcam.sh: line 1: ffserver: command not found
/usr/sbin/webcam.sh: line 1: ffmpeg: command not found
regards
Stevie P a real noob to all this
Did you run sudo make && sudo make install from inside the ffmpeg source directory ?
when i enter sudo make install i get the error:
make *** no targets. stop.
sorry i meant sudo make && make isnstall
Was thay run from inside the source directoey ?
i ran it from cd ffmpeg-dmo-0.11
it is a newer version though
Please help I’ve been trying to get this to work for over a week now,
when I run it I get the following
ffserver version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[NULL @ 0x141c620] Requested output format ‘video4linux2’ is not a suitable output format
pipe:: Invalid argument
sorry to post this again but it never posted all the text last time
root@raspberrypi:/home/pi# sudo /usr/sbin/webcam.sh
ffserver version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[NULL @ 0x1621620] Requested output format ‘video4linux2’ is not a suitable output format
pipe:: Invalid argument
root@raspberrypi:/home/pi#
Can you also paste what’s inside webcam.sh ?
Hi I had made a typo in the webcam.sh -i
but I have a new fault, please understand this is very very new to me lol it hard work at 1st but getting there
root@raspberrypi:/home/pi# /usr/sbin/webcam.sh
ffserver version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x1e3a620] Cannot open video device /dev/video0 : No such file or directory
/dev/video0: No such file or directory
root@raspberrypi:/home/pi#
could this be down to my webcam ? I’m not sure if its recognised, there is no name on it
should I look at getting another cam ?
thank you very much for your help
Hi, does your webcam work at all? Please post:
# lsusb
# ls -l /dev/video*
You have to do it as root, so do
# sudo -s
at first.
Chris
Hi Chris
found one of the problems, it was down to my powered usb hub changed it and it now see’s the cam, but I now get the same problem as Joaquรญn
root@raspberrypi:/home/pi# /usr/sbin/webcam.sh
ffserver version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x2531620] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x2531620] Cannot find a proper format for codec_id 0, pix_fmt -1.
/dev/video0: Input/output error
root@raspberrypi:/home/pi#
sorry i forgot this info
root@raspberrypi:/home/pi# sudo -s lsusb
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp.
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp.
Bus 001 Device 008: ID 05e3:0604 Genesys Logic, Inc. USB 1.1 Hub
Bus 001 Device 013: ID eb1a:2571 eMPIA Technology, Inc. M035 Compact Web Cam
Bus 001 Device 012: ID 04f2:0111 Chicony Electronics Co., Ltd KU-9908 Keyboard
Bus 001 Device 011: ID 1c4f:0003 SiGma Micro HID controller
root@raspberrypi:/home/pi# sudo -s ls -l /dev/video*
crw-rw—T+ 1 root video 81, 0 Dec 22 07:55 /dev/video0
root@raspberrypi:/home/pi#
never chaged anything but now got a slightly different fault
root@raspberrypi:/home/pi# /usr/sbin/webcam.sh
ffserver version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x2b6d620] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x2b6d620] The V4L2 driver changed the video from 640×480 to 352×288
[video4linux2,v4l2 @ 0x2b6d620] ioctl set time per frame(1/5) failed
/dev/video0: Input/output error
root@raspberrypi:/home/pi#
tried another cam but this time I used the usb ports on the pi, this is what I got
cam is a creative labs VF0604
root@raspberrypi:/home/pi# /usr/sbin/webcam.sh
ffserver version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
ffmpeg version 1.0.1 Copyright (c) 2000-2012 the FFmpeg developers
built on Dec 10 2012 23:25:31 with gcc 4.6 (Debian 4.6.3-8)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x25cb620] [3]Capabilities: 4000001
[video4linux2,v4l2 @ 0x25cb620] ioctl set time per frame(1/5) failed
/dev/video0: Input/output error
root@raspberrypi:/home/pi#
On what version of whezzy are you running this?
I have bin struggling for days to get it fixed. I always get an error at “sudo make && make install”
Last time I got this error message: “libavformat/bit.d:1: *** missing separator. Stop.”
Other times, something different…
I’m running this from the ffmpeg source folder.
Anyway, tried to ignore the error (worth trying: :)) and continue, but when I’m trying to run webcam.sh I get the fallowing error:
” /usr/sbin/webcam.sh: line 1: ffserver: command not found
/usr/sbin/webcam.sh: line 1: ffmpeg: command not found “
I fallowed the tutorial step by step, but I’m quite new in Linux so I might done some very beginner mistakes…
I was running it on quite an old version of Raspbian when I was doing this.
You may need to download the source again, sounds like the version of the source you have may have missing things.
The version I have for ffmpeg is 1.0.1
Where did you download that from ? The deb-multimedia site via apt-get ?
Maybe try getting the source from ffmpeg directly ?
Yes.
Could you give me an alternative source?
I tried again with a fresh raspbian.
After about 2 hours instaling with “make && make install” i got the fallowing error:
”
mkdir: cannot create directory ‘/usr/local/share/man/man1’ : Permission denied
make: *** [install-man] Error 1
“
Did you run the commands as root or use sudo ?
Yes.
Did anyone else succeeded wit version 1.0.1 of ffmpeg from deb-multimedia?
Which one ?
I will try it later today.
Which version of raspbian did you use ?
Sorry, I run the comands with sudo.
Whezzy 18/10 I think from raspberrypi.org.
Thanks!
I get the same error, any fix for it (yes, I’m running with sudo)
Well, I posted that comment too soon, doing sudo bash before doing it seemed to fix it
Hey Lagz great tutorial I’ve been reading through and decided to try it out myself (after spending a week figuring out that I had to do “sudo make && sudo make install” in order to get past step 9 :p ) I just have one problem with it
After I get everything working I find that the fps of my stream is very poor (1-3 fps) for a resolution of 320×240
frame= 111 fps=1.7 q=1.6 size= 424kB time=00:00:22.20 bitrate= 153.5kbits/s
I’ve checked and my webcam can support mjpeg up to 30fps on that resolution but I can’t seem to make it run faster, I even removed ‘VideoFrameRate’ to check if that command is even being noticed and the same happened. The only thing that changes this is if I completely remove (I’ve tried increasing it too with no change) “-r 5” in which the fps shoots up to 20+ but there’s a lot of dup errors and the stream still looks poor fps wise most of the time with some welcome spikes in fps.
Any ideas on what could be wrong?
That seems to be an issue with some webcams.
Have you tried an intermediate value for -r ? like say 10 or 15 ?
Also, what bitrate have you got set in the ffserv config file ?
Also, what do you mean by dup errors ?
Edit – After a quick google, try adding -vsync 0 to the command line and see how you go.
Edit 2 – I have also edited the post with some hopefully better instructions now lol.
I’ve managed to get it to work with -r set to 30, it seems that my webcam doesn’t like to update frames unless there is actual activity in the frame. Still sticks to 10fps but I can’t complain ๐
Worked great for me, although I was using a laptop, not a R pi. I just ended up needing to change one thing, I took out out the “-v verbose” because it was giving me an error. Thanks for the article!
Thanks for reading !
[…] pi How To : Stream A Webcam From The Raspberry Pi How To : Stream A Webcam From The Raspberry Pi Part 2 How To : Streaming 2 Webcams From The […]
Any ideas why do I get this error?
ffserver version 1.0.2 Copyright (c) 2000-2012 the FFmpeg developers
built on Jan 23 2013 00:01:41 with gcc 4.6 (Debian 4.6.3-12+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
ffmpeg version 1.0.2 Copyright (c) 2000-2012 the FFmpeg developers
built on Jan 23 2013 00:01:41 with gcc 4.6 (Debian 4.6.3-12+rpi1)
configuration:
libavutil 51. 73.101 / 51. 73.101
libavcodec 54. 59.100 / 54. 59.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
libavformat 54. 29.104 / 54. 29.104
libavdevice 54. 2.101 / 54. 2.101
libavfilter 3. 17.100 / 3. 17.100
libswscale 2. 1.101 / 2. 1.101
libswresample 0. 15.100 / 0. 15.100
[video4linux2,v4l2 @ 0x29a9620] [3]Capabilities: 5000001
[video4linux2,v4l2 @ 0x29a9620] Cannot find a proper format for codec_id 0, pix_fmt -1.
/dev/video0: Input/output error
Is that the newest version of ffmpeg ?
Tried specifying pixel format ?
Yes.
I tried with 640×340 and also 320×240, same results.
Now a stupid question…. do I need some sort of driver before?
I use a Logitech Quickcam Chat webcamera.
If you can see /dev/video0 then the driver is already present. Have you got a gui installed ? Perhaps try using guvcview and see if that can view your webcam ?
libavcodec/libavcodec.a(allcodecs.o): In function `avcodec_register_all’:
/home/pi/ffmpeg-dmo-1.0.3/libavcodec/allcodecs.c:506: undefined reference to `ff_mmvideo_decoder’
collect2: ld returned 1 exit status
make: *** [ffmpeg_g] Error 1
im getting this error when i run make && and make install you have any idea why this is happening..????
I tried your exact steps, and I get
[mjpeg @ 0x1233c20] me_method is only allowed to be set to zero and epzs; for hex,umh,full and other ses dia_size
What does that mean, and how do I fix it?
To be honest, I have no idea what that stuff means…
Have you tried other resolutions / formats ?
Hi can someone help me i have followed the instructions without to much difficulty bet i now get this odd error message
Missing audio stream which is required by this ffm
And the ffserver.conf file is exactly as the one at the start of this post.
This is the output on my command line
can someone tell me either how to fix this without sound or by telling me how to make the sound work if it really wants to use the sounds it can i was wanting to try and make the sound thing work after the stream is up and stable.
The kicker is i have had it working for a day then after a pi reboot it did this ๐
Please help
Did you copy and paste the config file or retype it out ?
Can you paste the config file anyway just so we can verify that it’s correct ?
I copied and pasted it in here is the code from my http://pastebin.com/CbwZ1Msx
I thought ffserver.conf was exactly the same ?
Remove these lines –
AudioBitRate 32
AudioChannels 2
AudioSampleRate 44100
So with these lines taken out and this command to run it all my output looks like this http://pastebin.com/zzi4tcWR
none of my post worked so here is the code http://pastebin.com/GULHfnad
http://pastebin.com/8iJpTKXL is my cammand line and output
but vlc is net letting me play the stream.
Please help
Could not install the packages..
Error 404 shown while downliading some packages.
I do have a stable net connection still what might be the problem?
Use Part 3 rather than this post’s instructions as they’re more up to date.
Can you explain how did you capture webcam stream using ffmpeg?
Santoshs-MacBook-Pro:~ Santosh$ ffmpeg -v verbose -r 5 -s 640×480 -f video4linux2 -i /dev/video0 http://localhost/webcam.ffm
ffmpeg version 1.1.1 Copyright (c) 2000-2013 the FFmpeg developers
built on Feb 7 2013 12:31:21 with Apple LLVM version 4.2 (clang-425.0.24) (based on LLVM 3.2svn)
configuration: –prefix=/usr/local/Cellar/ffmpeg/1.1.1 –enable-shared –enable-pthreads –enable-gpl –enable-version3 –enable-nonfree –enable-hardcoded-tables –enable-avresample –cc=cc –host-cflags= –host-ldflags= –enable-libx264 –enable-libfaac –enable-libmp3lame –enable-libxvid
libavutil 52. 13.100 / 52. 13.100
libavcodec 54. 86.100 / 54. 86.100
libavformat 54. 59.106 / 54. 59.106
libavdevice 54. 3.102 / 54. 3.102
libavfilter 3. 32.100 / 3. 32.100
libswscale 2. 1.103 / 2. 1.103
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 2.100 / 52. 2.100
Unknown input format: ‘video4linux2’
Santoshs-MacBook-Pro:~ Santosh$
[…] How To : Stream A Webcam From The Raspberry Pi ยป The Rantings and Ravings of a Madman […]
hi,
i tried this 5 times with 08/2012 wheezy, with 12/2012 debian, each time with fresh setup
everytime when i get to the point “sudo apt-get update”
– i get errors (non-veryfied files, stuff not found, lists not loaded …) and wheezy gets completely whamboozled, need to set it up again! ๐
…
is this still up-to date??
…
any help appreciated!!
This how to should still work, but part 3 is more up to date so I would go by that post instead
okay, that installation worked flawless, thx!
No problems ๐
Iโve followed your tutorial closely, and read the extensive comments. But I’m stymied and can’t get ffmpeg to fly. Here are my errors:
Run from root:
pi@raspberrypi ~ $ sudo webcam.sh
ffmpeg version 1.2.2 Copyright (c) 2000-2013 the FFmpeg developersffserver version 1.2.2 Copyright (c) 2000-2013 the FFmpeg developers
built on Aug 4 2013 03:22:18 with gcc 4.6 (Debian 4.6.3-14+rpi1)
built on Aug 4 2013 03:22:18 with gcc 4.6 (Debian 4.6.3-14+rpi1)
configuration:
configuration:
libavutil 52. 18.100 / 52. 18.100
libavcodec 54. 92.100 / 54. 92.100
libavutil 52. 18.100 / 52. 18.100
libavcodec 54. 92.100 / 54. 92.100
libavformat 54. 63.104 / 54. 63.104
libavdevice 54. 3.103 / 54. 3.103
libavfilter 3. 42.103 / 3. 42.103
libswscale 2. 2.100 / 2. 2.100
libavformat 54. 63.104 / 54. 63.104
libavdevice 54. 3.103 / 54. 3.103
libavfilter 3. 42.103 / 3. 42.103
libswscale 2. 2.100 / 2. 2.100
libswresample 0. 17.102 / 0. 17.102
/etc/ffserver.conf:42: libswresample 0. 17.102 / 0. 17.102
Incorrect keyword: ‘ffmpeg’
[video4linux2,v4l2 @ 0x1e7e4b0] fd:3 capabilities:4000001
Incorrect config file – exiting.
[video4linux2,v4l2 @ 0x1e7e4b0] Estimating duration from bitrate, this may be inaccurate
Input #0, video4linux2,v4l2, from ‘/dev/video0’:
Duration: N/A, start: 50810.587146, bitrate: 24576 kb/s
Stream #0:0: Video: rawvideo (YUY2 / 0x32595559), yuyv422, 640×480, 24576 kb/s, 5 fps, 5 tbr, 1000k tbn, 1000k tbc
Missing audio stream which is required by this ffm
Here is my ffserver.conf:
Port 80
BindAddress 0.0.0.0
MaxClients 10
MaxBandwidth 50000
NoDaemon
file /tmp/webcam.ffm
FileMaxSize 10M
Feed webcam.ffm
Format mjpeg
VideoSize 640×480
VideoFrameRate 10
VideoBitRate 2000
VideoQMin 1
VideoQMax 10
Here is my webcam.sh:
ffserver -f /etc/ffserver.conf & ffmpeg -v verbose -r 5 -s 640×480 -f video4linux2 -i /dev/video0 http://localhost/webcam.ffm
Thanks for your great work. Any help is much appreciated.
Charles H, another big noob
Is your configuration file *exactly* how it is there ? Or did WordPress strip some tags that were in there initially ?
/etc/ffserver.conf:42: libswresample 0. 17.102 / 0. 17.102
Incorrect keyword: โffmpegโ
[video4linux2,v4l2 @ 0x1e7e4b0] fd:3 capabilities:4000001
Incorrect config file โ exiting.
It looks like the configuration file isn’t correct and that could be causing the issue
Hello SirLagz,
I should have sent the conf code in pastebin since WP did strip out some of the tags. Here’s my config file exactly:
http://pastebin.com/hfRkD8sk
Thanks for your reply and help.
Charles
No problems
Is that pastebin missing the last line of the file ?