Webvideo, FFmpeg und Drupal

3,852 views

Published on

Presented at the Drupal Meetup Frankfurt/Rhein-Main, Germany http://groups.drupal.org/node/274393

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
3,852
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
11
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Webvideo, FFmpeg und Drupal

  1. 1. Webvideo, FFmpeg und Drupal Walter Ebert Drupal Meetup Frankfurt/Rhein-Main 10. Januar 2013
  2. 2. http://get.adobe.com/de/flashplayer/http://www.longtailvideo.com/players/
  3. 3. HTML5<video width="640" height="360" src="video.mp4" />
  4. 4. HTML5<video width="640" height="360" src="video.mp4" />
  5. 5. http://quirksmode.org/html5/tests/video.html
  6. 6. Video for Everybody<video width="640" height="360" controls> <source src="video.mp4" type="video/mp4" /> <source src="video.webm" type="video/webm" /> <source src="video.ogv" type="video/ogg" /> <object width="640" height="360" type="application/x-shockwave-flash" data="player.swf"> <param name="movie" value="player.swf" /> <param name="flashvars" value="controlbar=over&amp;image=video.jpg&amp;file=video.mp4" /> <img src="video.jpg" width="640" height="360" alt="Video Title" title="No video playback capabilities, please download the video below" /> </object></video><p><strong>Download Video:</strong>Closed Format: <a href="video.mp4">"MP4"</a>Open Format: <a href="video.webm">"WebM"</a>Open Format: <a href="video.ogv">"Ogg"</a></p> http://camendesign.com/code/video_for_everybody
  7. 7. Webvideo-Formate• Ogg Theora• WebM• H.264 b.z.w. MPEG-4 Part 10 AVC (Advanced Video Coding)
  8. 8. http://ffmpeg.org/
  9. 9. http://libav.org/
  10. 10. FFmpeg InfoUnterstütze Dateiformateffmpeg -formatsUnterstütze Codecsffmpeg -codecsHILFE!Getting help: -h -- print basic options -h long -- print more options -h full -- print all options (including all format andcodec specific options, very long) See man ffmpeg for detailed description of the options.
  11. 11. MP4/H.264ffmpeg -i input.avi -vcodec libx264 -acodec libfaac output.mp4ffmpeg -i input.avi -c:v libx264 -c:a aac -strict experimental output.mp4Video: Audio:h264 (internal) aac (internal)libx264 libfaac libvo_aacenc http://ffmpeg.org/trac/ffmpeg/wiki/x264EncodingGuide
  12. 12. FehlermeldungStream mapping: Stream #0:0 -> #0:0 (h264 -> libx264) Stream #0:1 -> #0:1 (aac -> aac)Error while opening encoder for outputstream #0:1 - maybe incorrect parameterssuch as bit_rate, rate, width or height
  13. 13. WebMffmpeg -i input.avi -c:a libvorbis -c:v libvpx output.webm
  14. 14. Ogg Theoraffmpeg -i input.avi -q:v 8 -c:a libvorbis -c:v libtheora output.ogvffmpeg2theora input.avi http://v2v.cc/~j/ffmpeg2theora/
  15. 15. 2-Pass Encodingffmpeg -y -i input.avi -pass 1 -c:v libx264 -an -f mp4 /dev/nullffmpeg -i input.avi -pass 2 -b:v 1M -c:v libx264 -c:a libfaac output.mp4
  16. 16. Presetsffmpeg -i input.avi -vpre libx264-ipod320 output.mp4ls /usr/share/ffmpeg/libvpx-1080p.ffpreset libvpx-720p50_60.ffpresetlibx264-ipod320.ffpreset libvpx-1080p50_60.ffpresetlibvpx-360p.ffpreset libvpx-720p.ffpresetlibx264-ipod640.ffpreset
  17. 17. FFmpeg Video > Bilderffmpeg -i video.mp4 -r .05 %4d.jpgffmpeg -i video.mp4 -r 5 -t 2 -pix_fmt gray -f image2 %4d.pngffmpeg -i video.mp4 -ss 1 -vframes 1 second1.jpgffmpeg -i video.mp4 -ss 00:00:01 -vframes 1 second1.jpg
  18. 18. Bildqualität definierenffmpeg -i input.avi -vb 1M output.mp4ffmpeg -i input.avi -b:v 1M output.mp4ffmpeg -i input.avi -qscale 10 output.mp4ffmpeg -i input.avi -q:v 10 output.mp4ffmpeg -i input.avi -qmin 10 -qmax 50 output.mp4
  19. 19. MP4 moov atom Alt: ffmpeg -i input.avi -c:a libfaac -c:v libx264 tmp.mp4 qt-faststart tmp.mp4 output.mp4 Neu: ffmpeg -i input.avi -c:a libfaac -c:v libx264 -movflags faststart output.mp4http://www.adobe.com/devnet/video/articles/mp4_movie_atom.html
  20. 20. http://ffmpeg-php.sourceforge.net/
  21. 21. High Efficiency Video Coding (HEVC) H.265 http://phenix.int-evry.fr/jct/news/news.php?id=33
  22. 22. http://videola.tv/https://github.com/Videola/videola
  23. 23. http://mediamosa.org/https://github.com/mediamosa/mediamosa
  24. 24. https://drupal.org/project/video
  25. 25. https://code.google.com/p/phpvideotoolkit/downloads/list
  26. 26. Video-PlayerJW Playerhttp://drupal.org/project/jw_playerFlowplayer APIhttp://drupal.org/project/flowplayerVideo.jshttp://drupal.org/project/videojs
  27. 27. http://popcornjs.org/ https://popcorn.webmaker.org/https://drupal.org/project/popcornjs
  28. 28. Walter Ebert @wltrd walterebert.deslideshare.net/walterebert drupal.org/user/699574

×