Use test::Packet test::PacketSource classes in neteq_rtpplay
This change replaces the old NETEQTEST_RTPpacket and NETEQTEST_DummyRTPpacket with the new test::Packet class. Note that the Packet class automatically handles "dummy" packets (i.e., packets for which only the header and a length field was stored to file) automatically. There is no need to explicitly signal this to the application any longer. The RTP input file is now handled as a test::PacketSource object. Also adding a new ConvertHeader method to the Packet class. This is needed to extract the header information as an alternative data type. Finally, some dead code was deleted from rtp_analyze.cc (unrelated to the reset of this change). BUG=2692 R=minyue@webrtc.org Review URL: https://webrtc-codereview.appspot.com/21139004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@6862 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
@ -21,6 +21,7 @@
|
||||
namespace webrtc {
|
||||
|
||||
class RtpHeaderParser;
|
||||
struct WebRtcRTPHeader;
|
||||
|
||||
namespace test {
|
||||
|
||||
@ -89,6 +90,10 @@ class Packet {
|
||||
|
||||
const RTPHeader& header() const { return header_; }
|
||||
|
||||
// Copies the packet header information, converting from the native RTPHeader
|
||||
// type to WebRtcRTPHeader.
|
||||
void ConvertHeader(WebRtcRTPHeader* copy_to) const;
|
||||
|
||||
void set_time_ms(double time) { time_ms_ = time; }
|
||||
double time_ms() const { return time_ms_; }
|
||||
bool valid_header() const { return valid_header_; }
|
||||
|
Reference in New Issue
Block a user