[ns] where is the packet header offset set when a new packet is generated?

2008-10-31 Thread matt Wood
Dear all, In NS2, the packet header must be accessed through its offset. But I can not find where the offset_ is initialized. Please look and see if my understanding of this issue is right or not: In the RTPAgent, it is directly use hdr_cmn::access(p) to access the header part. When the

Re: [ns] where is the packet header offset set when a new packet is generated?

2008-10-31 Thread Teerawat Issariyakul
Packet construction is fairly subtle. In fact it consist of three phases: 1) At the compilation (when you type make): In this phase, NS2 allocate the memory for all TclClasses. PacketHeaderClass defined in file ~ns/common/packet.h,cc is one of them. In the constructor of this class, the