Home || Visual Search || Applications || Architecture || Important Messages || OGL || Src

virtual int Impala::Core::Trec::Thread::GetShotAtWhileSkipping ( int  shot,
int  offset,
Thread skipthese 
) [inline, virtual]

Definition at line 71 of file Thread.h.

References Contains(), GetLength(), GetShot(), GetShotAt(), and GetShotPosition().

Referenced by Impala::Visualization::RotorBrowser::RotorBrowserContext::GetRelative().

00072     {
00073         if (offset == 0)
00074             return GetShotAt(shot, offset);
00075 
00076         int pos = GetShotPosition(shot);
00077         if (pos == -1)
00078             return -1;
00079 
00080         int dir = 1;
00081         if (offset < 0)
00082         {
00083             dir = -1;
00084             offset = -offset;
00085         }
00086         int len = GetLength();
00087         while (offset > 0)
00088         {
00089             pos += dir;
00090             if ((pos < 0) || (pos >= len))
00091                 return -1;
00092             int shot = GetShot(pos);
00093             if (!skipthese->Contains(shot))
00094                 offset--;
00095         }
00096         return GetShot(pos);
00097     }

Here is the call graph for this function:


Generated on Thu Jan 13 09:21:30 2011 for ImpalaSrc by  doxygen 1.5.1