video
Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
| Beide Seiten der vorigen RevisionVorhergehende ÜberarbeitungNächste Überarbeitung | Vorhergehende Überarbeitung | ||
| video [2011/02/01 10:07] – admin | video [2011/06/09 13:12] (aktuell) – admin | ||
|---|---|---|---|
| Zeile 39: | Zeile 39: | ||
| *[[http:// | *[[http:// | ||
| - | =====Streaming-Server - Version Januar 2011 ====== | ||
| - | |||
| - | http:// | ||
| - | |||
| - | =====Streaming-Server - Version 03. Februar 2010 ====== | ||
| - | |||
| - | ==== Streaming-Server ==== | ||
| - | |||
| - | *Aktuelle ffmpeg Version von Packman: ffmpeg-0.5.21000svn-0.pm.1.5.i586 | ||
| - | |||
| - | */ | ||
| - | < | ||
| - | Port 31337 | ||
| - | BindAddress 0.0.0.0 | ||
| - | MaxClients 1000 | ||
| - | MaxBandwidth 100000 | ||
| - | # Comment the following, on production use | ||
| - | NoDaemon | ||
| - | |||
| - | <Feed feed1.ffm> | ||
| - | File / | ||
| - | FileMaxSize 100M | ||
| - | #Launch ffmpeg -y -v 9 -f video4linux2 -vc 2 -tvstd PAL -s 480x384 -b 512000 -r 10 -an -i / | ||
| - | Launch ffmpeg -y -v 9 -f video4linux2 -vc 2 -tvstd PAL -s 480x384 -b 256000 -r 15 -an -i /dev/video0 | ||
| - | #Launch ffmpeg -r 10 -s 320x240 -f video4linux2 -i /dev/video0 -vcodec flv http:// | ||
| - | </ | ||
| - | |||
| - | #<Stream stream.flv> | ||
| - | # Feed feed1.ffm | ||
| - | # Format flv | ||
| - | # VideoCodec flv | ||
| - | # VideoFrameRate 2 | ||
| - | # VideoBufferSize 80000 | ||
| - | # VideoBitRate 256 | ||
| - | # VideoQMin 1 | ||
| - | # VideoQMax 5 | ||
| - | # VideoSize 480x384 | ||
| - | # PreRoll 0 | ||
| - | # Noaudio | ||
| - | #</ | ||
| - | |||
| - | ## SWF output | ||
| - | #<Stream stream.swf> | ||
| - | # Feed feed1.ffm | ||
| - | # Format swf | ||
| - | # VideoCodec flv | ||
| - | # VideoFrameRate 15 | ||
| - | # VideoBitRate 200 | ||
| - | # VideoQMin 5 | ||
| - | # VideoQMin 5 | ||
| - | # VideoSize 320x240 | ||
| - | # PreRoll 0 | ||
| - | # Noaudio | ||
| - | #</ | ||
| - | |||
| - | # ASF compatible | ||
| - | <Stream stream.asf> | ||
| - | Feed feed1.ffm | ||
| - | Format asf | ||
| - | VideoFrameRate 15 | ||
| - | VideoSize 352x240 | ||
| - | VideoBitRate 256 | ||
| - | VideoBufferSize 40 | ||
| - | VideoGopSize 30 | ||
| - | AudioBitRate 64 | ||
| - | StartSendOnKey | ||
| - | Noaudio | ||
| - | </ | ||
| - | |||
| - | |||
| - | # SWF output | ||
| - | <Stream stream.swf> | ||
| - | Feed feed1.ffm | ||
| - | Format swf | ||
| - | VideoCodec flv | ||
| - | VideoFrameRate 15 | ||
| - | VideoBitRate 512 | ||
| - | VideoQMin 5 | ||
| - | VideoQMax 9 | ||
| - | VideoSize 480x384 | ||
| - | PreRoll 0 | ||
| - | Noaudio | ||
| - | </ | ||
| - | |||
| - | </ | ||
| - | |||
| - | *Zum Starten: | ||
| - | |||
| - | ffserver & | ||
| - | |||
| - | *Zum Stoppen: | ||
| - | |||
| - | killall ffserver | ||
| - | |||
| - | ==== EINSTEIN ==== | ||
| - | |||
| - | */ | ||
| - | |||
| - | < | ||
| - | < | ||
| - | < | ||
| - | <meta http-equiv=" | ||
| - | <link rel=" | ||
| - | </ | ||
| - | <body style=" | ||
| - | |||
| - | <h1 style=" | ||
| - | |||
| - | < | ||
| - | < | ||
| - | <p> | ||
| - | |||
| - | <object classid=" | ||
| - | | ||
| - | <param name=" | ||
| - | <embed src=" | ||
| - | </ | ||
| - | </ | ||
| - | |||
| - | <!-- | ||
| - | <object class=" | ||
| - | < | ||
| - | < | ||
| - | < | ||
| - | < | ||
| - | </ | ||
| - | --> | ||
| - | |||
| - | </p> | ||
| - | |||
| - | </ | ||
| - | </ | ||
| - | |||
| - | ===== Client ===== | ||
| - | |||
| - | mplayer %%http:// | ||
| =====Streaming /dev/video nach Flash Video====== | =====Streaming /dev/video nach Flash Video====== | ||
| Zeile 212: | Zeile 76: | ||
| ===== mts to avi ===== | ===== mts to avi ===== | ||
| - | *for f in *.mts;do mencoder " | ||
| - | *ffmpeg -i 00007.mts -sameq -f mp4 -vcodec mpeg4 outfile.mp4 | ||
| - | *[[http:// | ||
| - | =====Videostreaming===== | ||
| - | |||
| - | ==== Servervoraussetzungen ==== | ||
| - | |||
| - | *openSUSE 11.1 | ||
| - | *root, uS.... | ||
| - | *Kartenname: | ||
| - | *Treiber bttv | ||
| - | *Soundkarte: | ||
| - | *[[http:// | ||
| - | |||
| - | dmesg | grep bttv => card=54 | ||
| - | | ||
| - | rmmod bt878 bttv | ||
| - | |||
| - | modprobe bttv card=54 | ||
| - | |||
| - | */ | ||
| - | < | ||
| - | options bttv card=54 | ||
| - | </ | ||
| - | |||
| - | ==== Video Kanäle ==== | ||
| - | |||
| - | *0 = Television | ||
| - | *1 = Composite | ||
| - | *2 = s-video | ||
| - | |||
| - | |||
| - | |||
| - | ==== Port-Weiterleitung ==== | ||
| - | |||
| - | <code bash> | ||
| - | #!/bin/bash | ||
| - | |||
| - | iptables -F | ||
| - | iptables -X | ||
| - | iptables -t nat -F | ||
| - | iptables -t nat -X | ||
| - | iptables -t mangle -F | ||
| - | iptables -t mangle -X | ||
| - | iptables -P INPUT ACCEPT | ||
| - | iptables -P FORWARD ACCEPT | ||
| - | iptables -P OUTPUT ACCEPT | ||
| - | |||
| - | echo 1 > / | ||
| - | iptables -F -t nat | ||
| - | iptables -t nat -A PREROUTING -p tcp --dport 31337 -j DNAT --to 192.168.100.40: | ||
| - | iptables -t nat -A POSTROUTING -j MASQUERADE | ||
| - | |||
| - | </ | ||
| - | |||
| - | ==== Alter Gentoo-Server (2008) ==== | ||
| - | |||
| - | *Gentoo 2009 | ||
| - | *PW: TW... | ||
| - | *Wenn nötig X installieren : [[http:// | ||
| - | |||
| - | */ | ||
| - | < | ||
| - | bttv card=54 | ||
| - | </ | ||
| - | |||
| - | *ffmpeg installieren: | ||
| - | < | ||
| - | emerge ffmpeg | ||
| - | </ | ||
| - | |||
| - | */ | ||
| - | < | ||
| - | Port 8090 | ||
| - | BindAddress 0.0.0.0 | ||
| - | MaxHTTPConnections 1000 | ||
| - | MaxClients 1000 | ||
| - | MaxBandwidth 2000 | ||
| - | CustomLog - | ||
| - | NoDaemon | ||
| - | |||
| - | ################################################################## | ||
| - | |||
| - | <Feed feed1.ffm> | ||
| - | File / | ||
| - | FileMaxSize 50M | ||
| - | ACL allow 127.0.0.1 | ||
| - | </ | ||
| - | |||
| - | ################################################################## | ||
| - | |||
| - | # JPEG | ||
| - | |||
| - | <Stream test.jpg> | ||
| - | Feed feed1.ffm | ||
| - | Format jpeg | ||
| - | VideoFrameRate 2 | ||
| - | VideoIntraOnly | ||
| - | VideoSize 480x384 | ||
| - | #NoAudio | ||
| - | Strict -1 | ||
| - | </ | ||
| - | |||
| - | #Flash | ||
| - | |||
| - | <Stream stream.swf> | ||
| - | Feed feed1.ffm | ||
| - | VideoBitRate 256 | ||
| - | VideoFrameRate 25 | ||
| - | VideoBufferSize 80000 | ||
| - | Format swf | ||
| - | VideoFrameRate 25 | ||
| - | VideoSize 480x384 | ||
| - | VideoQMin 3 | ||
| - | VideoQMax 5 | ||
| - | VideoCodec flv | ||
| - | #NoAudio | ||
| - | PreRoll 0 | ||
| - | </ | ||
| - | |||
| - | ################################################################## | ||
| - | # Special streams | ||
| - | |||
| - | # Server status | ||
| - | |||
| - | <Stream stat.html> | ||
| - | Format status | ||
| - | |||
| - | # Only allow local people to get the status | ||
| - | ACL allow localhost 192.168.100.0 | ||
| - | #ACL allow 10.0.0.0 10.0.0.255 | ||
| - | #ACL allow 0.0.0.0 | ||
| - | |||
| - | #FaviconURL http:// | ||
| - | </ | ||
| - | |||
| - | < | ||
| - | URL http:// | ||
| - | </ | ||
| - | |||
| - | </ | ||
| - | |||
| - | *ffserver starten | ||
| - | *ffmpeg | ||
| - | < | ||
| - | ffmpeg -y -v 9 -f video4linux2 -vc 2 -tvstd PAL -s 480x384 -r 25 -i /dev/video0 -vcodec flv http:// | ||
| - | </ | ||
| - | |||
| - | === Stream speichern === | ||
| - | |||
| - | *ffmpeg und Download müssen mehr oder weniger gleichzeitig gestartet werden: | ||
| - | |||
| - | *ffserver und ffmpeg ganz normal wie oben erwähnt ausführen | ||
| - | *In den Ordner wechseln, in den man den Stream speichern will | ||
| - | |||
| - | w3m http:// | ||
| - | |||
| - | *stream.swf mit ENTER auswählen, Download starten | ||
| - | |||
| - | |||
| - | ==== Streaming mit ffmpeg (Ausgabe = Flash-Film = gute Qualität) ==== | ||
| - | |||
| - | */ | ||
| - | |||
| - | < | ||
| - | Port 31337 | ||
| - | #8090 | ||
| - | # bind to all IPs aliased or not | ||
| - | BindAddress 0.0.0.0 | ||
| - | # max number of simultaneous clients | ||
| - | MaxClients 1000 | ||
| - | # max bandwidth per-client (kb/s) | ||
| - | MaxBandwidth 10000 | ||
| - | # Suppress that if you want to launch ffserver as a daemon. | ||
| - | NoDaemon | ||
| - | |||
| - | <Feed feed1.ffm> | ||
| - | File / | ||
| - | FileMaxSize 50M | ||
| - | </ | ||
| - | |||
| - | <Stream stream.swf> | ||
| - | Feed feed1.ffm | ||
| - | Format swf | ||
| - | VideoCodec flv | ||
| - | VideoFrameRate 24 | ||
| - | VideoBufferSize 80000 | ||
| - | VideoBitRate 256 | ||
| - | #VideoQMin 1 | ||
| - | #VideoQMax 5 | ||
| - | VideoSize 352x288 | ||
| - | PreRoll 0 | ||
| - | Noaudio | ||
| - | </ | ||
| - | |||
| - | </ | ||
| - | |||
| - | *ffserver starten und laufen lassen | ||
| - | |||
| - | nb02:/etc # ffserver | ||
| - | |||
| - | *ffmpeg starten und laufen lassen | ||
| - | |||
| - | nb02:/etc # ffmpeg -r 24 -s 352x288 -f video4linux2 -i /dev/video0 http:// | ||
| - | |||
| - | *Zum Anschauen: http:// | ||
| - | |||
| - | */ | ||
| - | |||
| - | < | ||
| - | < | ||
| - | < | ||
| - | < | ||
| - | |||
| - | <embed src=" | ||
| - | |||
| - | </ | ||
| - | </ | ||
| - | |||
| - | </ | ||
| - | |||
| - | ==== Streaming mit VLC (Ausgabe = Windows Media Stream = Schlechtere Qualität) ==== | ||
| - | |||
| - | *vlc -> Medien -> Streaming -> Aufnahmegerät öffnen (Einstellungen durchführen) -> Stream -> | ||
| - | *Outputs: Lokal wiedergeben, | ||
| - | *Profil: windows (wmv,asf) | ||
| - | *Stream (bzw. ALT+S) | ||
| - | |||
| - | *Anschauen etwa mit: | ||
| - | |||
| - | mplayer http:// | ||
| - | |||
| - | * oder im Internet in HTML eingebunden: | ||
| - | < | + | [[http://forum.videolan.org/ |
| - | < | + | |
| - | < | + | |
| - | < | + | |
| - | <object id="Player1" | + | for f in *.mts;do mencoder |
| - | r2"> | + | |
| - | <param name=" | + | |
| - | <param name=" | + | |
| - | <param name=" | + | |
| - | <param name=" | + | |
| - | <param name=" | + | |
| - | <param name=" | + | |
| - | <param name=" | + | |
| - | <param name=" | + | |
| - | <embed type=" | + | |
| - | src=" | + | |
| - | dth=" | + | |
| - | </ | + | |
| - | <a href=""> | + | ffmpeg -i 00007.mts -sameq -f mp4 -vcodec mpeg4 outfile.mp4 |
| - | </ | + | |
| - | </ | + | |
| - | </ | + | |
| =====Allgemeines===== | =====Allgemeines===== | ||
video.1296551241.txt.gz · Zuletzt geändert: von admin
