This file is indexed.

/usr/include/IGSTK/igstkFrame.h is in libigstk4-dev 4.4.0-6.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
/*=========================================================================

  Program:   Image Guided Surgery Software Toolkit
  Module:    $RCSfile: igstkFrame.h,v $
  Language:  C++
  Date:      $Date: 2011-01-18 21:40:16 $
  Version:   $Revision: 1.3 $

  Copyright (c) ISC  Insight Software Consortium.  All rights reserved.
  See IGSTKCopyright.txt or http://www.igstk.org/copyright.htm for details.

     This software is distributed WITHOUT ANY WARRANTY; without even
     the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
     PURPOSE.  See the above copyright notices for more information.

=========================================================================*/

#ifndef __igstkFrame_h
#define __igstkFrame_h

#include "itkVector.h"
#include "itkVersor.h"

#include "igstkTimeStamp.h"
#include "igstkMacros.h"
#include "itkStdStreamLogOutput.h"

class vtkImageData;

namespace igstk
{

/** \class Frame
 *  \brief Frame from an external input device.
 *
 * It is intended to be used as a
 * communication vehicle between imagers and spatial objects. The class
 * contains a TimeStamp defining the validity period for the information in the
 * frame.
 *
 * All the set methods require an argument that defines the number of
 * milliseconds for which the stored information is considered to be valid.
 * The validity period will be counted from the moment the Set method was
 * invoked.
 *
 * \sa TimeStamp
 *
 * */
class Frame
{
public:

  friend class VideoImager;
  friend class VideoImagerTool;

  igstkLoggerMacro();

  typedef TimeStamp::TimePeriodType   TimePeriodType;

  igstkSetMacro( Width, unsigned int );
  igstkGetMacro( Width, unsigned int );

  igstkSetMacro( Height, unsigned int );
  igstkGetMacro( Height, unsigned int );

  igstkSetMacro( NumberOfChannels, unsigned int );
  igstkGetMacro( NumberOfChannels, unsigned int );

  /** Constructor and destructor */
  Frame();
  Frame(unsigned int width, unsigned int height, unsigned int channels);
  Frame( const Frame & t );
  virtual ~Frame();

  void * GetImagePtr();

  /** Returns the time at which the validity of this information starts.
   * The data in this frame should not be used for scenes to be rendered
   * before that validity time. The time is returned in milliseconds.
   *
   * \sa TimeStamp
   *
   * */
  TimePeriodType GetStartTime() const;


  /** Returns the time at which the validity of this information expires. The
   * data in this frame should not be used for scenes to be rendered
   * after that validity time. The time is returned in milliseconds.
   *
   * \sa TimeStamp
   *
   * */
  TimePeriodType GetExpirationTime() const;

  void SetTimeToExpiration( TimePeriodType millisecondsToExpiration );

  /** Returns the validity status of the frame at the time passed as
   * argument. The frame values should not be used in a scene if the time
   * when the scene is to be rendered returned 'false' when passed to this
   * IsValid() function. The time is passed in milliseconds.
   *
   * \sa TimeStamp
   *
   * */
  bool IsValidAtTime( TimePeriodType timeToTestInMilliseconds ) const;

  /** Returns the validity status of the frame when it is called
   *
   * \sa TimeStamp
   *
   * */
  bool IsValidNow() const;

  /** Method for printing the member variables of this class to an ostream */
  void Print(std::ostream& os, itk::Indent indent) const;

protected:

  void PrintHeader(std::ostream& os, itk::Indent indent) const;

  void PrintTrailer(std::ostream& itkNotUsed(os),
                                          itk::Indent itkNotUsed(indent)) const;

  /** Print the object information in a stream. */
  virtual void PrintSelf( std::ostream& os, itk::Indent indent ) const;

private:

  void SetFrameDimensions( unsigned int, unsigned int, unsigned int);
  void SetImagePtr( void*, TimePeriodType millisecondsToExpiration);

  std::vector< unsigned char >* m_Image;
  TimeStamp                     m_TimeStamp;
  void*                         m_ImagePtr;
  unsigned int                  m_Width;
  unsigned int                  m_Height;
  unsigned int                  m_NumberOfChannels;

};

std::ostream& operator<<(std::ostream& os, const igstk::Frame& o);
}

#endif