|
|
|
|
@ -13,6 +13,7 @@
|
|
|
|
|
|
|
|
|
|
import net.java.sip.communicator.impl.neomedia.codec.*;
|
|
|
|
|
import net.java.sip.communicator.impl.neomedia.codec.video.*;
|
|
|
|
|
import net.java.sip.communicator.service.neomedia.control.*;
|
|
|
|
|
import net.sf.fmj.media.*;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
@ -58,6 +59,12 @@ public class JNIDecoder
|
|
|
|
|
*/
|
|
|
|
|
private int height;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* The <tt>KeyFrameControl</tt> used by this <tt>JNIDecoder</tt> to
|
|
|
|
|
* control its key frame-related logic.
|
|
|
|
|
*/
|
|
|
|
|
private KeyFrameControl keyFrameControl;
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Array of output <tt>VideoFormat</tt>s.
|
|
|
|
|
*/
|
|
|
|
|
@ -281,6 +288,12 @@ public synchronized int process(Buffer inBuffer, Buffer outBuffer)
|
|
|
|
|
|
|
|
|
|
if (!got_picture[0])
|
|
|
|
|
{
|
|
|
|
|
if ((inBuffer.getFlags() & Buffer.FLAG_RTP_MARKER) != 0)
|
|
|
|
|
{
|
|
|
|
|
if (keyFrameControl != null)
|
|
|
|
|
keyFrameControl.requestKeyFrame();
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
outBuffer.setDiscard(true);
|
|
|
|
|
return BUFFER_PROCESSED_OK;
|
|
|
|
|
}
|
|
|
|
|
@ -354,4 +367,18 @@ public Format setInputFormat(Format format)
|
|
|
|
|
reset();
|
|
|
|
|
return setFormat;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
|
* Sets the <tt>KeyFrameControl</tt> to be used by this
|
|
|
|
|
* <tt>DePacketizer</tt> as a means of control over its key frame-related
|
|
|
|
|
* logic.
|
|
|
|
|
*
|
|
|
|
|
* @param keyFrameControl the <tt>KeyFrameControl</tt> to be used by this
|
|
|
|
|
* <tt>DePacketizer</tt> as a means of control over its key frame-related
|
|
|
|
|
* logic
|
|
|
|
|
*/
|
|
|
|
|
public void setKeyFrameControl(KeyFrameControl keyFrameControl)
|
|
|
|
|
{
|
|
|
|
|
this.keyFrameControl = keyFrameControl;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|