A Discrete-Event Network Simulator
API
delay-jitter-estimation.h
Go to the documentation of this file.
1 /* -*- Mode:C++; c-file-style:"gnu"; indent-tabs-mode:nil; -*- */
2 /*
3  * Copyright (c) 2007 INRIA
4  *
5  * This program is free software; you can redistribute it and/or modify
6  * it under the terms of the GNU General Public License version 2 as
7  * published by the Free Software Foundation;
8  *
9  * This program is distributed in the hope that it will be useful,
10  * but WITHOUT ANY WARRANTY; without even the implied warranty of
11  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12  * GNU General Public License for more details.
13  *
14  * You should have received a copy of the GNU General Public License
15  * along with this program; if not, write to the Free Software
16  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17  *
18  * Authors: Mathieu Lacage <mathieu.lacage@sophia.inria.fr>
19  */
20 #ifndef DELAY_JITTER_ESTIMATION_H
21 #define DELAY_JITTER_ESTIMATION_H
22 
23 #include "ns3/nstime.h"
24 #include "ns3/packet.h"
25 
26 namespace ns3 {
27 
35 {
36 public:
38 
49  static void PrepareTx (Ptr<const Packet> packet);
57  void RecordRx (Ptr<const Packet> packet);
58 
62  Time GetLastDelay (void) const;
69  uint64_t GetLastJitter (void) const;
70 
71 private:
76 };
77 
78 } // namespace ns3
79 
80 #endif /* DELAY_JITTER_ESTIMATION_H */
Simulation virtual time values and global simulation resolution.
Definition: nstime.h:102
High precision numerical type, implementing Q64.64 fixed precision.
Definition: int64x64-128.h:45
void RecordRx(Ptr< const Packet > packet)
static void PrepareTx(Ptr< const Packet > packet)
Every class exported by the ns3 library is enclosed in the ns3 namespace.
Time m_previousRxTx
Previous Rx or Tx time.
Time m_delay
Delay estimation.
Time m_previousRx
Previous Rx time.
quick and dirty delay and jitter estimation
uint64_t GetLastJitter(void) const
The jitter is calculated using the RFC 1889 (RTP) jitter definition.
int64x64_t m_jitter
Jitter estimation.