ffmpeg for screen capture?
Asked Answered
E

2

4

So I have an Applet that captures the screen, and sound from the computer's microphone, the screenshots are then encoded to ScreenVideo2, and the sound is encoded to AAC.

How can I use ffmpeg to mux this, frame by frame, and then send the muxed output to a wowza media server?

if it cant be done with ffmpeg, can you kindly provide any suggestions?

Euphrosyne answered 16/4, 2012 at 19:23 Comment(2)
This ScreenVideo2? It seems server-side. How are you getting the screen-shots & sound from the client to the server?Pandora
nope, this ScreenVideo2: the screenshots are taken with the clasic Robot and encoded with this, and audio is taken from a TargetDataLine and then processed into AAC, then I use flazr to send those to the server but I do it sequencially, but it should be muxed into one.Euphrosyne
S
1

which OS? Under Linux, you might want to consider http://kde-apps.org/content/show.php/FDesktopRecorder?content=147844

The central core of the script is something like:

Records the screen:

ffmpeg -f alsa -ac 2 -i pulse -f x11grab -r 30 -s $(xwininfo -root | \
  grep 'geometry' | awk '{print $2;}') -i :0.0 -acodec flac -vcodec libx264 \
  -vpre lossless_ultrafast -threads 0 -y output.mkv

Record a window:

#!/bin/sh INFO=$(xwininfo -frame) WIN_GEO=$(echo $INFO | \
  grep -oEe 'geometry [0-9]+x[0-9]+' | \
  grep -oEe '[0-9]+x[0-9]+')WIN_XY=$(echo $INFO | \
  grep -oEe 'Corners:\s+\+[0-9]+\+[0-9]+' | grep -oEe '[0-9]+\+[0-9]+' | \
  sed -e 's/\+/,/' ) ffmpeg -f alsa -ac 2 -i pulse -f x11grab -r 30 \
  -s $WIN_GEO -i :0.0+$WIN_XY -acodec flac -vcodec libx264 \
  -vpre lossless_ultrafast -threads 0 -y output-single.mkv
Striate answered 16/4, 2012 at 20:48 Comment(1)
it should be multiplataform, we are talking about an applet :sEuphrosyne
J
0

Xuggler can do that for you. I'm not exactly sure if it's working in Applets. It is able to encode frames by using ffmpeg in the background. It's actively developed right now and has good support via its mailing list.

Jacie answered 17/4, 2012 at 14:5 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.