VTK
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
dox
Filters
Modeling
vtkSpherePuzzle.h
Go to the documentation of this file.
1
/*=========================================================================
2
3
Program: Visualization Toolkit
4
Module: vtkSpherePuzzle.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
=========================================================================*/
27
#ifndef __vtkSpherePuzzle_h
28
#define __vtkSpherePuzzle_h
29
30
#include "vtkFiltersModelingModule.h"
// For export macro
31
#include "vtkPolyDataAlgorithm.h"
32
33
#define VTK_MAX_SPHERE_RESOLUTION 1024
34
35
class
vtkTransform;
36
37
class
VTKFILTERSMODELING_EXPORT
vtkSpherePuzzle
:
public
vtkPolyDataAlgorithm
38
{
39
public
:
40
vtkTypeMacro(
vtkSpherePuzzle
,vtkPolyDataAlgorithm);
41
void
PrintSelf(ostream& os, vtkIndent indent);
42
43
static
vtkSpherePuzzle
*New();
44
46
void
Reset();
47
49
void
MoveHorizontal(
int
section,
int
percentage,
int
rightFlag);
50
52
void
MoveVertical(
int
section,
int
percentage,
int
rightFlag);
53
59
int
SetPoint(
double
x,
double
y,
double
z);
60
64
void
MovePoint(
int
percentage);
65
67
int
*
GetState
() {
return
this->State;}
68
69
protected
:
70
vtkSpherePuzzle
();
71
~
vtkSpherePuzzle
();
72
73
int
RequestData(vtkInformation *, vtkInformationVector **, vtkInformationVector *);
74
void
MarkVertical(
int
section);
75
void
MarkHorizontal(
int
section);
76
77
int
State[32];
78
79
// Stuff for storing a partial move.
80
int
PieceMask[32];
81
vtkTransform *
Transform
;
82
83
// Colors for faces.
84
unsigned
char
Colors[96];
85
86
// State for potential move.
87
int
Active
;
88
int
VerticalFlag
;
89
int
RightFlag
;
90
int
Section
;
91
92
private
:
93
vtkSpherePuzzle
(
const
vtkSpherePuzzle
&);
// Not implemented
94
void
operator=(
const
vtkSpherePuzzle
&);
// Not implemented
95
};
96
97
#endif
vtkSpherePuzzle::RightFlag
int RightFlag
Definition:
vtkSpherePuzzle.h:89
vtkSpherePuzzle::VerticalFlag
int VerticalFlag
Definition:
vtkSpherePuzzle.h:88
vtkSpherePuzzle::Section
int Section
Definition:
vtkSpherePuzzle.h:90
vtkSpherePuzzle
create a polygonal sphere centered at the origin
Definition:
vtkSpherePuzzle.h:37
vtkSpherePuzzle::GetState
int * GetState()
Definition:
vtkSpherePuzzle.h:67
vtkSpherePuzzle::Transform
vtkTransform * Transform
Definition:
vtkSpherePuzzle.h:81
vtkSpherePuzzle::Active
int Active
Definition:
vtkSpherePuzzle.h:87
Generated on Sat May 10 2014 05:42:49 for VTK by
1.8.6