VTK  9.3.20240328
vtkSegYReader.h
Go to the documentation of this file.
1 // SPDX-FileCopyrightText: Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
2 // SPDX-License-Identifier: BSD-3-Clause
3 
4 #ifndef vtkSegYReader_h
5 #define vtkSegYReader_h
6 
7 #include "vtkDataSetAlgorithm.h"
8 
9 #include <vtkIOSegYModule.h> // For export macro
10 
11 // Forward declarations
12 VTK_ABI_NAMESPACE_BEGIN
13 class vtkImageData;
15 
31 class VTKIOSEGY_EXPORT vtkSegYReader : public vtkDataSetAlgorithm
32 {
33 public:
34  static vtkSegYReader* New();
36  void PrintSelf(ostream& os, vtkIndent indent) override;
38  ~vtkSegYReader() override;
39 
42 
44  {
45  VTK_SEGY_SOURCE = 0, // default
46  VTK_SEGY_CDP = 1,
47  VTK_SEGY_CUSTOM = 2
48  };
49 
51 
60  vtkSetClampMacro(XYCoordMode, int, VTK_SEGY_SOURCE, VTK_SEGY_CUSTOM);
61  vtkGetMacro(XYCoordMode, int);
66 
68 
74  vtkSetMacro(XCoordByte, int);
75  vtkGetMacro(XCoordByte, int);
76  vtkSetMacro(YCoordByte, int);
77  vtkGetMacro(YCoordByte, int);
79 
81  {
82  VTK_SEGY_VERTICAL_HEIGHTS = 0, // default
83  VTK_SEGY_VERTICAL_DEPTHS
84  };
85 
87 
97  vtkSetMacro(VerticalCRS, int);
98  vtkGetMacro(VerticalCRS, int);
100 
102 
109  vtkSetMacro(StructuredGrid, int);
110  vtkGetMacro(StructuredGrid, int);
111  vtkBooleanMacro(StructuredGrid, int);
113 
115 
122  vtkSetMacro(Force2D, bool);
123  vtkGetMacro(Force2D, bool);
124  vtkBooleanMacro(Force2D, bool);
126 
127 protected:
128  int RequestData(vtkInformation* request, vtkInformationVector** inputVector,
129  vtkInformationVector* outputVector) override;
130 
132  vtkInformationVector* outputVector) override;
134  vtkInformationVector* outputVector) override;
135 
137  char* FileName;
138  bool Is3D;
139  double DataOrigin[3];
140  double DataSpacing[3][3];
141  int DataSpacingSign[3];
142  int DataExtent[6];
143 
146 
147  // Custom XY coordinate byte positions
150 
152 
153  bool Force2D;
154 
155 private:
156  vtkSegYReader(const vtkSegYReader&) = delete;
157  void operator=(const vtkSegYReader&) = delete;
158 };
159 
160 VTK_ABI_NAMESPACE_END
161 #endif // vtkSegYReader_h
Superclass for algorithms that produce output of the same type as input.
topologically and geometrically regular array of data
Definition: vtkImageData.h:155
a simple class to control print indentation
Definition: vtkIndent.h:108
Store zero or more vtkInformation instances.
Store vtkAlgorithm input/output information.
Reads SegY data files.
Definition: vtkSegYReader.h:32
vtkSegYReaderInternal * Reader
static vtkSegYReader * New()
void SetXYCoordModeToCustom()
Specify whether to use source x/y coordinates or CDP coordinates or custom byte positions for data po...
void SetXYCoordModeToSource()
Specify whether to use source x/y coordinates or CDP coordinates or custom byte positions for data po...
int RequestDataObject(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
This is called within ProcessRequest when a request asks the algorithm to create empty output data ob...
int RequestData(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
This is called within ProcessRequest when a request asks the algorithm to do its work.
int RequestInformation(vtkInformation *request, vtkInformationVector **inputVector, vtkInformationVector *outputVector) override
This is called within ProcessRequest when a request asks for Information.
void SetXYCoordModeToCDP()
Specify whether to use source x/y coordinates or CDP coordinates or custom byte positions for data po...
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
~vtkSegYReader() override
vtkGetFilePathMacro(FileName)
vtkSetFilePathMacro(FileName)