2

I have a Raspberry Pi (model B) running raspbian wheezy on a 16gb SD card. I also have a 32gb flash storage attached on the usb. I'm trying to stream a video (h264 encoded mp4 file 1280x720) over the ethernet from that flash storage.
I'm using ffmpeg+ffserver. Here is ffserver.conf (relevant parts):

...
MaxBandwidth 10000
<Feed feed1.ffm>
...
FileMaxSize 100M
ACL allow 127.0.0.1
</Feed>
...
<Stream test.flv>
Feed feed1.ffm
Format flv
VideoSize 288x176 #made small just for testing
NoAudio
</Stream>
....

I start the ffserver, then call ffmpeg with this command:

ffmpeg -re -an -i /mnt/u32/main.mp4 -r 25 -bit_rate 300k http://localhost:8090/feed1.ffm

And I'm getting fps 3-5 at most. Naturally when I try to view the stream on another computer it's very choppy and virtually unusable.

Am I missing some settings? Or perhaps there is another streaming solution that leverages the GPU instead of just the CPU as ffmpeg does? I'm even open to suggestions about other boards (e.g. a pandaboard? or clustering several RPi's?) Also, I'm flexible about the output format.

ierdna
  • 5,753
  • 7
  • 50
  • 84
  • What are you streaming to? Can't you just copy the file over ethernet (SMB / SSH) and decode at the other end? – Terence Eden Dec 23 '12 at 22:12
  • the file is about 6gb and i'm streaming to an ipad. i know i'll need to use HLS eventually, but for now i'm starting simple, just trying to stream it to a browser. – ierdna Jan 14 '13 at 17:00
  • 1
    Currently I don't believe that there is an FFMPEG fork that utilizes the raspberry pi's GPU, which is generally the core of its touted video out features. This thread http://www.raspberrypi.org/phpBB3/viewtopic.php?f=31&t=17500 seems to be most current/relevant. – mrmagooey Jan 29 '13 at 02:38

1 Answers1

0

Try it with the rtmp-nginx module. I succeed to stream it pretty well with ffmpeg. The appropiate codec to use for stream video is h264. I made a python script that runs ffmpeg and streams it with nginx, maybe it will help you. It may be also possible to use the hardware encoding with ffmpeg now.

Cristian Gabor
  • 322
  • 1
  • 3
  • 13