classcore_1_1Tracklet.tex 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220
  1. \hypertarget{classcore_1_1Tracklet}{}\section{core\+:\+:Tracklet Class Reference}
  2. \label{classcore_1_1Tracklet}\index{core\+::\+Tracklet@{core\+::\+Tracklet}}
  3. {\ttfamily \#include $<$Tracklet.\+h$>$}
  4. Inheritance diagram for core\+:\+:Tracklet\+:\begin{figure}[H]
  5. \begin{center}
  6. \leavevmode
  7. \includegraphics[height=2.000000cm]{classcore_1_1Tracklet}
  8. \end{center}
  9. \end{figure}
  10. \subsection*{Public Member Functions}
  11. \begin{DoxyCompactItemize}
  12. \item
  13. \hyperlink{classcore_1_1Tracklet_aedf59b5a9a068a28bb7570f2a031d4e7}{Tracklet} ()
  14. \item
  15. void \hyperlink{classcore_1_1Tracklet_ab0b397f2d0685a927de886dbd36c3bc8}{Add\+Path\+Object} (Object\+Data\+Ptr obj, bool overwrite=false)
  16. \item
  17. size\+\_\+t \hyperlink{classcore_1_1Tracklet_ae2c79325e151e8401a7a925984bbbe69}{Get\+First\+Frame\+Index} () const
  18. \item
  19. size\+\_\+t \hyperlink{classcore_1_1Tracklet_a71487b13697f71abb75949e6fcad9081}{Get\+Last\+Frame\+Index} () const
  20. \item
  21. Object\+Data\+Ptr \hyperlink{classcore_1_1Tracklet_a9758349e8f25c479ffc4b21a90149a81}{Get\+Path\+Object} (size\+\_\+t i)
  22. \item
  23. size\+\_\+t \hyperlink{classcore_1_1Tracklet_a0d27b17706f6c72c093c76e1f65b960f}{Get\+Path\+Object\+Count} () const
  24. \item
  25. void \hyperlink{classcore_1_1Tracklet_a10b56b608b24ef547550540e5a755bce}{Interpolate\+Missing\+Frames} ()
  26. \item
  27. virtual double \hyperlink{classcore_1_1Tracklet_a0357f2fa173941800571432dcbc96dc2}{Compare\+To} (Object\+Data\+Ptr obj) const override
  28. \item
  29. virtual Object\+Data\+Ptr \hyperlink{classcore_1_1Tracklet_a5fb5e6ab9df668c3477e8b52f115b188}{Interpolate} (Object\+Data\+Ptr obj, double fraction) const override
  30. \item
  31. virtual void \hyperlink{classcore_1_1Tracklet_a85f92a4059bf89f24a83f28935675181}{Visualize} (cv\+::\+Mat \&image, cv\+::\+Scalar \&color) const override
  32. \item
  33. void \hyperlink{classcore_1_1Tracklet_aee78c9ec0ee80b1b381083c20e1d3f18}{Visualize} (cv\+::\+Mat \&image, cv\+::\+Scalar \&color, size\+\_\+t frame, size\+\_\+t predecessor\+\_\+count, size\+\_\+t successor\+\_\+count) const
  34. \item
  35. void \hyperlink{classcore_1_1Tracklet_a2bdb2f2c8249145808e7029dde6e7df0}{Flatten} ()
  36. \item
  37. void {\bfseries Combine} (Tracklet\+Ptr other)\hypertarget{classcore_1_1Tracklet_a5bbbf1e2858edaad93c04cc663afeeff}{}\label{classcore_1_1Tracklet_a5bbbf1e2858edaad93c04cc663afeeff}
  38. \item
  39. Object\+Data\+Ptr {\bfseries Get\+Frame\+Object} (size\+\_\+t frame\+\_\+index)\hypertarget{classcore_1_1Tracklet_a5a0e56045f8c1868b46db87700658260}{}\label{classcore_1_1Tracklet_a5a0e56045f8c1868b46db87700658260}
  40. \end{DoxyCompactItemize}
  41. \subsection{Detailed Description}
  42. A class for storing multiple object data objects. The object data objects are handled as a path. All objects are stored sorted ascending by their frame index.
  43. \subsection{Constructor \& Destructor Documentation}
  44. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Tracklet@{Tracklet}}
  45. \index{Tracklet@{Tracklet}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  46. \subsubsection[{\texorpdfstring{Tracklet()}{Tracklet()}}]{\setlength{\rightskip}{0pt plus 5cm}core\+::\+Tracklet\+::\+Tracklet (
  47. \begin{DoxyParamCaption}
  48. {}
  49. \end{DoxyParamCaption}
  50. )}\hypertarget{classcore_1_1Tracklet_aedf59b5a9a068a28bb7570f2a031d4e7}{}\label{classcore_1_1Tracklet_aedf59b5a9a068a28bb7570f2a031d4e7}
  51. Creates a empty tracklet to store path object in. This is N\+OT a virtual object.
  52. \subsection{Member Function Documentation}
  53. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Add\+Path\+Object@{Add\+Path\+Object}}
  54. \index{Add\+Path\+Object@{Add\+Path\+Object}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  55. \subsubsection[{\texorpdfstring{Add\+Path\+Object(\+Object\+Data\+Ptr obj, bool overwrite=false)}{AddPathObject(ObjectDataPtr obj, bool overwrite=false)}}]{\setlength{\rightskip}{0pt plus 5cm}void core\+::\+Tracklet\+::\+Add\+Path\+Object (
  56. \begin{DoxyParamCaption}
  57. \item[{Object\+Data\+Ptr}]{obj, }
  58. \item[{bool}]{overwrite = {\ttfamily false}}
  59. \end{DoxyParamCaption}
  60. )}\hypertarget{classcore_1_1Tracklet_ab0b397f2d0685a927de886dbd36c3bc8}{}\label{classcore_1_1Tracklet_ab0b397f2d0685a927de886dbd36c3bc8}
  61. Adds the path object sorted into the tracklet.
  62. \begin{DoxyParams}{Parameters}
  63. {\em obj} & The path object to add \\
  64. \hline
  65. {\em overwrite} & If true and an object in the same frame as the given object already exists, the old one will be replaced by the new one \\
  66. \hline
  67. \end{DoxyParams}
  68. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Compare\+To@{Compare\+To}}
  69. \index{Compare\+To@{Compare\+To}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  70. \subsubsection[{\texorpdfstring{Compare\+To(\+Object\+Data\+Ptr obj) const override}{CompareTo(ObjectDataPtr obj) const override}}]{\setlength{\rightskip}{0pt plus 5cm}double core\+::\+Tracklet\+::\+Compare\+To (
  71. \begin{DoxyParamCaption}
  72. \item[{Object\+Data\+Ptr}]{obj}
  73. \end{DoxyParamCaption}
  74. ) const\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}}\hypertarget{classcore_1_1Tracklet_a0357f2fa173941800571432dcbc96dc2}{}\label{classcore_1_1Tracklet_a0357f2fa173941800571432dcbc96dc2}
  75. Compares this object with the given object.
  76. \begin{DoxyParams}{Parameters}
  77. {\em obj} & A pointer to the object to compare this object to \\
  78. \hline
  79. \end{DoxyParams}
  80. \begin{DoxyReturn}{Returns}
  81. A double value indicating the comparison result
  82. \end{DoxyReturn}
  83. Reimplemented from \hyperlink{classcore_1_1ObjectData_adcd9fc0dfa93d45668e667237f249553}{core\+::\+Object\+Data}.
  84. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Flatten@{Flatten}}
  85. \index{Flatten@{Flatten}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  86. \subsubsection[{\texorpdfstring{Flatten()}{Flatten()}}]{\setlength{\rightskip}{0pt plus 5cm}void core\+::\+Tracklet\+::\+Flatten (
  87. \begin{DoxyParamCaption}
  88. {}
  89. \end{DoxyParamCaption}
  90. )}\hypertarget{classcore_1_1Tracklet_a2bdb2f2c8249145808e7029dde6e7df0}{}\label{classcore_1_1Tracklet_a2bdb2f2c8249145808e7029dde6e7df0}
  91. Flattens the current tracklet one level. That means, that if this tracklet contains other tracklets as path objects, their path objects are all extracted and used as the new path objects of this tracklet. The old tracklet path objects are removed. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Get\+First\+Frame\+Index@{Get\+First\+Frame\+Index}}
  92. \index{Get\+First\+Frame\+Index@{Get\+First\+Frame\+Index}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  93. \subsubsection[{\texorpdfstring{Get\+First\+Frame\+Index() const }{GetFirstFrameIndex() const }}]{\setlength{\rightskip}{0pt plus 5cm}size\+\_\+t core\+::\+Tracklet\+::\+Get\+First\+Frame\+Index (
  94. \begin{DoxyParamCaption}
  95. {}
  96. \end{DoxyParamCaption}
  97. ) const}\hypertarget{classcore_1_1Tracklet_ae2c79325e151e8401a7a925984bbbe69}{}\label{classcore_1_1Tracklet_ae2c79325e151e8401a7a925984bbbe69}
  98. Gets the lowest frame index of all path objects. \begin{DoxyReturn}{Returns}
  99. The lowest frame index
  100. \end{DoxyReturn}
  101. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Get\+Last\+Frame\+Index@{Get\+Last\+Frame\+Index}}
  102. \index{Get\+Last\+Frame\+Index@{Get\+Last\+Frame\+Index}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  103. \subsubsection[{\texorpdfstring{Get\+Last\+Frame\+Index() const }{GetLastFrameIndex() const }}]{\setlength{\rightskip}{0pt plus 5cm}size\+\_\+t core\+::\+Tracklet\+::\+Get\+Last\+Frame\+Index (
  104. \begin{DoxyParamCaption}
  105. {}
  106. \end{DoxyParamCaption}
  107. ) const}\hypertarget{classcore_1_1Tracklet_a71487b13697f71abb75949e6fcad9081}{}\label{classcore_1_1Tracklet_a71487b13697f71abb75949e6fcad9081}
  108. Gets the highest frame index of all path objects. \begin{DoxyReturn}{Returns}
  109. The highest frame index
  110. \end{DoxyReturn}
  111. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Get\+Path\+Object@{Get\+Path\+Object}}
  112. \index{Get\+Path\+Object@{Get\+Path\+Object}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  113. \subsubsection[{\texorpdfstring{Get\+Path\+Object(size\+\_\+t i)}{GetPathObject(size_t i)}}]{\setlength{\rightskip}{0pt plus 5cm}Object\+Data\+Ptr core\+::\+Tracklet\+::\+Get\+Path\+Object (
  114. \begin{DoxyParamCaption}
  115. \item[{size\+\_\+t}]{i}
  116. \end{DoxyParamCaption}
  117. )}\hypertarget{classcore_1_1Tracklet_a9758349e8f25c479ffc4b21a90149a81}{}\label{classcore_1_1Tracklet_a9758349e8f25c479ffc4b21a90149a81}
  118. Gets the path object at the given index. The index is N\+OT the frame index \begin{DoxyReturn}{Returns}
  119. A pointer to the path object
  120. \end{DoxyReturn}
  121. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Get\+Path\+Object\+Count@{Get\+Path\+Object\+Count}}
  122. \index{Get\+Path\+Object\+Count@{Get\+Path\+Object\+Count}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  123. \subsubsection[{\texorpdfstring{Get\+Path\+Object\+Count() const }{GetPathObjectCount() const }}]{\setlength{\rightskip}{0pt plus 5cm}size\+\_\+t core\+::\+Tracklet\+::\+Get\+Path\+Object\+Count (
  124. \begin{DoxyParamCaption}
  125. {}
  126. \end{DoxyParamCaption}
  127. ) const}\hypertarget{classcore_1_1Tracklet_a0d27b17706f6c72c093c76e1f65b960f}{}\label{classcore_1_1Tracklet_a0d27b17706f6c72c093c76e1f65b960f}
  128. Gets the count of all path objects. \begin{DoxyReturn}{Returns}
  129. The path object count
  130. \end{DoxyReturn}
  131. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Interpolate@{Interpolate}}
  132. \index{Interpolate@{Interpolate}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  133. \subsubsection[{\texorpdfstring{Interpolate(\+Object\+Data\+Ptr obj, double fraction) const override}{Interpolate(ObjectDataPtr obj, double fraction) const override}}]{\setlength{\rightskip}{0pt plus 5cm}Object\+Data\+Ptr core\+::\+Tracklet\+::\+Interpolate (
  134. \begin{DoxyParamCaption}
  135. \item[{Object\+Data\+Ptr}]{obj, }
  136. \item[{double}]{fraction}
  137. \end{DoxyParamCaption}
  138. ) const\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}}\hypertarget{classcore_1_1Tracklet_a5fb5e6ab9df668c3477e8b52f115b188}{}\label{classcore_1_1Tracklet_a5fb5e6ab9df668c3477e8b52f115b188}
  139. Linearly interpolates between this and the given object. Creates a new object to fit between the two objects.
  140. \begin{DoxyParams}{Parameters}
  141. {\em obj} & A pointer to the target object \\
  142. \hline
  143. {\em fraction} & Describes where the interpolation should be done. A fraction of zero is a clone of this object, a fraction of one is a clone of the target object. \\
  144. \hline
  145. \end{DoxyParams}
  146. \begin{DoxyReturn}{Returns}
  147. The interpolated object
  148. \end{DoxyReturn}
  149. Reimplemented from \hyperlink{classcore_1_1ObjectData_a7b8943b13c2c2ce2dfaacb2b98c8f30c}{core\+::\+Object\+Data}.
  150. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Interpolate\+Missing\+Frames@{Interpolate\+Missing\+Frames}}
  151. \index{Interpolate\+Missing\+Frames@{Interpolate\+Missing\+Frames}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  152. \subsubsection[{\texorpdfstring{Interpolate\+Missing\+Frames()}{InterpolateMissingFrames()}}]{\setlength{\rightskip}{0pt plus 5cm}void core\+::\+Tracklet\+::\+Interpolate\+Missing\+Frames (
  153. \begin{DoxyParamCaption}
  154. {}
  155. \end{DoxyParamCaption}
  156. )}\hypertarget{classcore_1_1Tracklet_a10b56b608b24ef547550540e5a755bce}{}\label{classcore_1_1Tracklet_a10b56b608b24ef547550540e5a755bce}
  157. Interpolates between the current path objects until every missing frame has an object. Only frames between the first frame index and the last frame index are interpolated. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Visualize@{Visualize}}
  158. \index{Visualize@{Visualize}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  159. \subsubsection[{\texorpdfstring{Visualize(cv\+::\+Mat \&image, cv\+::\+Scalar \&color) const override}{Visualize(cv::Mat &image, cv::Scalar &color) const override}}]{\setlength{\rightskip}{0pt plus 5cm}void core\+::\+Tracklet\+::\+Visualize (
  160. \begin{DoxyParamCaption}
  161. \item[{cv\+::\+Mat \&}]{image, }
  162. \item[{cv\+::\+Scalar \&}]{color}
  163. \end{DoxyParamCaption}
  164. ) const\hspace{0.3cm}{\ttfamily [override]}, {\ttfamily [virtual]}}\hypertarget{classcore_1_1Tracklet_a85f92a4059bf89f24a83f28935675181}{}\label{classcore_1_1Tracklet_a85f92a4059bf89f24a83f28935675181}
  165. Visualizes the object in the given image with the given color. This method does nothing, it needs to be overwritten to visualize something.
  166. \begin{DoxyParams}{Parameters}
  167. {\em image} & The image to write into \\
  168. \hline
  169. {\em color} & The color to use \\
  170. \hline
  171. \end{DoxyParams}
  172. Reimplemented from \hyperlink{classcore_1_1ObjectData_a505eb948f5d857b86f4f452bb39053b9}{core\+::\+Object\+Data}.
  173. \index{core\+::\+Tracklet@{core\+::\+Tracklet}!Visualize@{Visualize}}
  174. \index{Visualize@{Visualize}!core\+::\+Tracklet@{core\+::\+Tracklet}}
  175. \subsubsection[{\texorpdfstring{Visualize(cv\+::\+Mat \&image, cv\+::\+Scalar \&color, size\+\_\+t frame, size\+\_\+t predecessor\+\_\+count, size\+\_\+t successor\+\_\+count) const }{Visualize(cv::Mat &image, cv::Scalar &color, size_t frame, size_t predecessor_count, size_t successor_count) const }}]{\setlength{\rightskip}{0pt plus 5cm}void core\+::\+Tracklet\+::\+Visualize (
  176. \begin{DoxyParamCaption}
  177. \item[{cv\+::\+Mat \&}]{image, }
  178. \item[{cv\+::\+Scalar \&}]{color, }
  179. \item[{size\+\_\+t}]{frame, }
  180. \item[{size\+\_\+t}]{predecessor\+\_\+count, }
  181. \item[{size\+\_\+t}]{successor\+\_\+count}
  182. \end{DoxyParamCaption}
  183. ) const}\hypertarget{classcore_1_1Tracklet_aee78c9ec0ee80b1b381083c20e1d3f18}{}\label{classcore_1_1Tracklet_aee78c9ec0ee80b1b381083c20e1d3f18}
  184. Visualizes the tracklet by visualizing the path object in the given frame and the number of path objects in the given range before and after the given frame.
  185. \begin{DoxyParams}{Parameters}
  186. {\em image} & The image to write into \\
  187. \hline
  188. {\em color} & The color to use \\
  189. \hline
  190. {\em frame} & The frame index to visualize the path objects from \\
  191. \hline
  192. {\em predecessor\+\_\+count} & The number of path objects to visualize before the given frame \\
  193. \hline
  194. {\em successor\+\_\+count} & The number of path objects to visualize after the given frame \\
  195. \hline
  196. \end{DoxyParams}
  197. The documentation for this class was generated from the following files\+:\begin{DoxyCompactItemize}
  198. \item
  199. core/Tracklet.\+h\item
  200. core/Tracklet.\+cpp\end{DoxyCompactItemize}