This file is indexed.

/usr/include/paraview/vtkPVImageSliceMapper.h is in paraview-dev 5.0.1+dfsg1-4.

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
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
/*=========================================================================

  Program:   Visualization Toolkit
  Module:    vtkPVImageSliceMapper.h

  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
  All rights reserved.
  See Copyright.txt or http://www.kitware.com/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 notice for more information.

=========================================================================*/
// .NAME vtkPVImageSliceMapper - Mapper for vtkImageData that renders the image
// using a texture applied to a quad.
// .SECTION Description
// vtkPVImageSliceMapper is a mapper for vtkImageData that renders the image by
// loading the image as a texture and then applying it to a quad. For 3D images,
// this mapper only shows a single Z slice which can be choosen using SetZSlice.
// By default, the image data scalars are rendering, however, this mapper
// provides API to select another point or cell data array. Internally, this
// mapper uses painters similar to those employed by vtkPainterPolyDataMapper.
// .SECTION See Also
// vtkPainterPolyDataMapper


#ifndef vtkPVImageSliceMapper_h
#define vtkPVImageSliceMapper_h

#include "vtkPVClientServerCoreRenderingModule.h" //needed for exports
#include "vtkMapper.h"
#include "vtkStructuredData.h" // needed for VTK_*_PLANE

class vtkImageData;
class vtkRenderer;

#ifdef VTKGL2
class vtkOpenGLTexture;
class vtkActor;
#endif
class vtkPainter;

class VTKPVCLIENTSERVERCORERENDERING_EXPORT vtkPVImageSliceMapper : public vtkMapper
{
public:
  static vtkPVImageSliceMapper* New();
  vtkTypeMacro(vtkPVImageSliceMapper, vtkMapper);
  void PrintSelf(ostream& os, vtkIndent indent);

  // Description:
  // This calls RenderPiece (in a for loop is streaming is necessary).
  virtual void Render(vtkRenderer *ren, vtkActor *act);

  virtual void ReleaseGraphicsResources (vtkWindow *);

  // Description:
  // Get/Set the painter that does the actual rendering.
  void SetPainter(vtkPainter*);
  vtkGetObjectMacro(Painter, vtkPainter);

  // Description:
  // Specify the input data to map.
  void SetInputData(vtkImageData *in);
  virtual vtkImageData *GetInput();

  // Description:
  // Set/Get the current X/Y or Z slice number.
  vtkSetMacro(Slice,int);
  vtkGetMacro(Slice,int);

  //BTX
  enum
    {
    XY_PLANE = VTK_XY_PLANE,
    YZ_PLANE = VTK_YZ_PLANE,
    XZ_PLANE = VTK_XZ_PLANE,
    };
  //ETX

  vtkSetClampMacro(SliceMode, int, XY_PLANE, XZ_PLANE);
  vtkGetMacro(SliceMode, int);
  void SetSliceModeToYZPlane()
    { this->SetSliceMode(YZ_PLANE); }
  void SetSliceModeToXZPlane()
    { this->SetSliceMode(XZ_PLANE); }
  void SetSliceModeToXYPlane()
    { this->SetSliceMode(XY_PLANE); }

  // Description:
  // When set, the image slice is always rendered in the XY plane (Z==0)
  // irrespective of the image bounds. Default is Off.
  vtkSetClampMacro(UseXYPlane, int, 0, 1);
  vtkBooleanMacro(UseXYPlane, int);
  vtkGetMacro(UseXYPlane, int);

  // Description:
  // Update that sets the update piece first.
  virtual void Update(int port);
  virtual void Update()
    { this->Superclass::Update(); }

  // Description:
  // If you want only a part of the data, specify by setting the piece.
  vtkSetMacro(Piece, int);
  vtkGetMacro(Piece, int);
  vtkSetMacro(NumberOfPieces, int);
  vtkGetMacro(NumberOfPieces, int);
  vtkSetMacro(NumberOfSubPieces, int);
  vtkGetMacro(NumberOfSubPieces, int);

  // Description:
  // Set the number of ghost cells to return.
  vtkSetMacro(GhostLevel, int);
  vtkGetMacro(GhostLevel, int);

  // Description:
  // Return bounding box (array of six doubles) of data expressed as
  // (xmin,xmax, ymin,ymax, zmin,zmax).
  virtual double *GetBounds();
  virtual void GetBounds(double bounds[6])
    {this->Superclass::GetBounds(bounds);};

  // Description:
  // Make a shallow copy of this mapper.
  virtual void ShallowCopy(vtkAbstractMapper *m);


protected:
  vtkPVImageSliceMapper();
  ~vtkPVImageSliceMapper();

  // Tell the executive that we accept vtkImageData.
  virtual int FillInputPortInformation(int, vtkInformation*);

  // Description:
  // Perform the actual rendering.
  virtual void RenderPiece(vtkRenderer *ren, vtkActor *act);

#ifdef VTKGL2
  vtkOpenGLTexture *Texture;
  int SetupScalars(vtkImageData*);
  void RenderInternal(vtkRenderer *ren, vtkActor *act);
  vtkTimeStamp UpdateTime;
  vtkActor *PolyDataActor;
#else
  // Description:
  // Called when the PainterInformation becomes obsolete. It is called before
  // Render request is propogated to the painter.
  void UpdatePainterInformation();

  vtkInformation* PainterInformation;
  vtkTimeStamp PainterInformationUpdateTime;

  class vtkObserver;
  vtkObserver* Observer;
#endif

  vtkPainter* Painter;

  int Piece;
  int NumberOfSubPieces;
  int NumberOfPieces;
  int GhostLevel;

  int SliceMode;
  int Slice;
  int UseXYPlane;

private:
  vtkPVImageSliceMapper(const vtkPVImageSliceMapper&); // Not implemented
  void operator=(const vtkPVImageSliceMapper&); // Not implemented

};

#endif