org.mobicents.media.server.impl.rtp
Class RtpClock

java.lang.Object
  extended by org.mobicents.media.server.impl.rtp.RtpClock
Direct Known Subclasses:
AudioClock, VideoClock

public abstract class RtpClock
extends java.lang.Object

Author:
kulikov

Field Summary
protected  long now
           
 
Constructor Summary
RtpClock()
           
 
Method Summary
 org.mobicents.media.Format getFormat()
           
abstract  long getTime(long timestamp)
          Returns the time in milliseconds
abstract  long getTimestamp(long time)
          Calculates RTP timestamp
 boolean isSynchronized()
           
protected  long now()
           
 void reset()
           
 void setFormat(org.mobicents.media.Format format)
           
 void synchronize(long initial)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

now

protected long now
Constructor Detail

RtpClock

public RtpClock()
Method Detail

getFormat

public org.mobicents.media.Format getFormat()

setFormat

public void setFormat(org.mobicents.media.Format format)

synchronize

public void synchronize(long initial)

isSynchronized

public boolean isSynchronized()

now

protected long now()

reset

public void reset()

getTime

public abstract long getTime(long timestamp)
Returns the time in milliseconds

Parameters:
timestamp - the rtp timestamp
Returns:
the time in milliseconds

getTimestamp

public abstract long getTimestamp(long time)
Calculates RTP timestamp

Parameters:
time - the time in milliseconds
Returns:
rtp timestamp.


Copyright © 2010. All Rights Reserved.