VTK
vtkProgrammableDataObjectSource.h
Go to the documentation of this file.
1 /*=========================================================================
2 
3  Program: Visualization Toolkit
4  Module: vtkProgrammableDataObjectSource.h
5 
6  Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen
7  All rights reserved.
8  See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
9 
10  This software is distributed WITHOUT ANY WARRANTY; without even
11  the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
12  PURPOSE. See the above copyright notice for more information.
13 
14 =========================================================================*/
42 #ifndef vtkProgrammableDataObjectSource_h
43 #define vtkProgrammableDataObjectSource_h
44 
45 #include "vtkFiltersSourcesModule.h" // For export macro
46 #include "vtkDataObjectAlgorithm.h"
47 
48 class VTKFILTERSSOURCES_EXPORT vtkProgrammableDataObjectSource : public vtkDataObjectAlgorithm
49 {
50 public:
53  void PrintSelf(ostream& os, vtkIndent indent) VTK_OVERRIDE;
54 
64  typedef void (*ProgrammableMethodCallbackType)(void *arg);
65 
70  void SetExecuteMethod(void (*f)(void *), void *arg);
71 
75  void SetExecuteMethodArgDelete(void (*f)(void *));
76 
77 protected:
80 
81  int RequestData(vtkInformation *, vtkInformationVector **,
82  vtkInformationVector *) VTK_OVERRIDE;
83 
84  ProgrammableMethodCallbackType ExecuteMethod; //function to invoke
85  ProgrammableMethodCallbackType ExecuteMethodArgDelete;
86  void *ExecuteMethodArg;
87 private:
89  void operator=(const vtkProgrammableDataObjectSource&) VTK_DELETE_FUNCTION;
90 };
91 
92 #endif
vtkProgrammableDataObjectSource
generate source data object via a user-specified function
Definition: vtkProgrammableDataObjectSource.h:49
vtkProgrammableDataObjectSource::vtkProgrammableDataObjectSource
vtkProgrammableDataObjectSource()
vtkInformationVector
Store zero or more vtkInformation instances.
Definition: vtkInformationVector.h:42
vtkDataObjectAlgorithm
Superclass for algorithms that produce only data object as output.
Definition: vtkDataObjectAlgorithm.h:44
vtkProgrammableDataObjectSource::SetExecuteMethod
void SetExecuteMethod(void(*f)(void *), void *arg)
Specify the function to use to generate the output data object.
vtkIndent
a simple class to control print indentation
Definition: vtkIndent.h:40
vtkInformation
Store vtkAlgorithm input/output information.
Definition: vtkInformation.h:87
vtkProgrammableDataObjectSource::~vtkProgrammableDataObjectSource
~vtkProgrammableDataObjectSource() override
vtkProgrammableDataObjectSource::PrintSelf
void PrintSelf(ostream &os, vtkIndent indent) override
Methods invoked by print to print information about the object including superclasses.
vtkProgrammableDataObjectSource::SetExecuteMethodArgDelete
void SetExecuteMethodArgDelete(void(*f)(void *))
Set the arg delete method.
vtkDataObjectAlgorithm.h
vtkProgrammableDataObjectSource::New
static vtkProgrammableDataObjectSource * New()