4

I have an application which captures live video from an HD camera and streams it to a video streaming server. I currently use Adobe Flash Media Live Encoder(FMLE) to sent the captured video stream to the server.

The problem is FMLE has no support for linux. I came acroos VLCJ and Xuggler as possible alternatives to FMLE and also that these provide better control over the encoded media such that we can put in optional motion detectors, filters etc. Is it possible to use the video capture support support of VLCJ and the processing support of xuggler for my application. I mean is there any common interfaces in which i can present the captured stream from vlcj to Xuggler?

user2156721
  • 41
  • 1
  • 3

1 Answers1

0

There's no existing nice interface that links both libraries (that I'm aware of), but you may be able to pipe raw data between the two.

VLCJ's DirectMediaPlayer has a render callback which provides a hook into the raw pixel data (see here for a particular example.) Usually this is used for direct pixel manipulation on the Java layer (such as making the video grayscale in the above example) but there's no real reason why you shouldn't be able to pipe the data to Xuggler's IBuffer, then in turn wrap that into an IVideoPicture (and from there you're in Xuggler land.)

I've never tried doing something like this myself, so there may be a few extra hoops you have to jump through - but in principle it certainly seems possible. The main issue would, I think be speed if you need it in real-time; doing this all on the CPU for HD video is no small ask of your processor.

Michael Berry
  • 70,193
  • 21
  • 157
  • 216