How to speed up of NetAnim Animation

68 views
Skip to first unread message

William

unread,
Jan 15, 2016, 9:36:44 AM1/15/16
to ns-3-users
Dear members,

I am using netanim-3.106. I wanna speed up netanim animation. LTE animation with 120 UEs and 10 HeNB and 2 Network nodes was implemented. File size of xml getting after simulation was 105MB. Max speed of NetAnim by moving speed bar to the max speed was configured. But I felt the speed of this animation is too slow and the speed of count number incremeant was very slow.
please, let me know how to speed up of NetAnim animation more....


Br,

William.

John Abraham

unread,
Jan 15, 2016, 1:40:03 PM1/15/16
to ns-3-...@googlegroups.com
Yes, unfortunately it has way too many packets to animate and Wall-clock time is not always == simulation time.

In theory it should be possible to skip over some events and make it appear to go faster, by manipulating
TimeValue<AnimEvent*>::TimeValueIteratorPair_t pp = m_events.getNext (result);
m_currentTime = pp.first->first;

may be do an extra 
pp = m_events.getNext (result);
pp = m_events.getNext (result);
pp = m_events.getNext (result);
pp = m_events.getNext (result);

But I am not sure. I can check on it when I'm back in town.




--
Posting to this group should follow these guidelines https://www.nsnam.org/wiki/Ns-3-users-guidelines-for-posting
---
You received this message because you are subscribed to the Google Groups "ns-3-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ns-3-users+...@googlegroups.com.
To post to this group, send email to ns-3-...@googlegroups.com.
Visit this group at https://groups.google.com/group/ns-3-users.
For more options, visit https://groups.google.com/d/optout.

John Abraham

unread,
Jan 19, 2016, 10:28:56 AM1/19/16
to ns-3-...@googlegroups.com
I got to check this.

in animatormode.cpp

you could replace

  TimeValue<AnimEvent*>::TimeValueIteratorPair_t pp = m_events.getNext (result);

with

  TimeValue<AnimEvent*>::TimeValueIteratorPair_t pp = m_events.getNext (result);
  if (m_currentTime > 1)
    {
      int num_skip_events = 4;
      for(int i = 0; i < num_skip_events; ++i)
        pp = m_events.getNext (result);
    }

where we process only 1 in 4 events. This could potentially speed it up.However please note, it might skip over important events like a moved node or a node which changed color etc.


Reply all
Reply to author
Forward
0 new messages