diff options
author | Damian Minkov <damencho@jitsi.org> | 2007-10-10 14:23:10 +0000 |
---|---|---|
committer | Damian Minkov <damencho@jitsi.org> | 2007-10-10 14:23:10 +0000 |
commit | c41b0b6e691571c44eafebf9f04199b42ace53b5 (patch) | |
tree | 6e5a30a7b88cfcc158ba9892fff53e3b62e2e98e /src/net/java | |
parent | d3d2bf68b4d7a38b67819cbdc4b9f5618511d9cb (diff) | |
download | jitsi-c41b0b6e691571c44eafebf9f04199b42ace53b5.zip jitsi-c41b0b6e691571c44eafebf9f04199b42ace53b5.tar.gz jitsi-c41b0b6e691571c44eafebf9f04199b42ace53b5.tar.bz2 |
Buffer size contributed by Thomas Hofer and some javadoc fix
Diffstat (limited to 'src/net/java')
-rw-r--r-- | src/net/java/sip/communicator/impl/media/MediaControl.java | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/net/java/sip/communicator/impl/media/MediaControl.java b/src/net/java/sip/communicator/impl/media/MediaControl.java index f864283..9854ea0 100644 --- a/src/net/java/sip/communicator/impl/media/MediaControl.java +++ b/src/net/java/sip/communicator/impl/media/MediaControl.java @@ -169,6 +169,7 @@ public class MediaControl * Returns the duration of the output data source. Usually this will be * DURATION_UNKNOWN, but if the current data source is set to an audio * file, then this value will be of some use. + * @return the output duration */ public javax.media.Time getOutputDuration() { @@ -497,13 +498,14 @@ public class MediaControl //Changing buffer size. The default buffer size (for javasound) //is 125 milliseconds - 1/8 sec. On MacOS this leeds to exception and - // no audio capture. 130 value of buffer fix the problem. + // no audio capture. 30 value of buffer fix the problem and is ok + // when using some pstn gateways Control ctl = (Control) dataSource.getControl("javax.media.control.BufferControl"); if(ctl != null) { - ((BufferControl)ctl).setBufferLength(130);//buffers in + ((BufferControl)ctl).setBufferLength(30);//buffers in } sourceProcessor = Manager.createProcessor(dataSource); @@ -907,7 +909,7 @@ public class MediaControl private VideoFormat assertSize(VideoFormat sourceFormat) { int width, height; - Dimension size = ( (VideoFormat) sourceFormat).getSize(); + Dimension size = sourceFormat.getSize(); Format jpegFmt = new Format(VideoFormat.JPEG_RTP); Format h263Fmt = new Format(VideoFormat.H263_RTP); if (sourceFormat.matches(jpegFmt)) |