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
|
/*=========================================================================
Program: ParaView
Module: vtkPVServerOptionsInternals.h
Copyright (c) Kitware, Inc.
All rights reserved.
See Copyright.txt or http://www.paraview.org/HTML/Copyright.html 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.
=========================================================================*/
#ifndef vtkPVServerOptionsInternals_h
#define vtkPVServerOptionsInternals_h
#include <vector>
#include <string>
class vtkPVServerOptionsInternals
{
public:
// The MachineInformation struct is used
// to store information about each machine.
// These are stored in a vector one for each node in the process.
struct MachineInformation
{
public:
MachineInformation()
{
for(int i =0; i < 3; ++i)
{
this->LowerLeft[i] = 0.0;
this->LowerRight[i] = 0.0;
this->UpperRight[i] = 0.0;
}
this->Geometry[0] = 0;
this->Geometry[1] = 0;
this->Geometry[2] = 0;
this->Geometry[3] = 0;
this->FullScreen = false;
this->ShowBorders = false;
this->CaveBoundsSet = 0;
this->StereoType = -1;
}
std::string Name; // what is the name of the machine
std::string Environment; // what environment variables should be set
int Geometry[4]; // x, y, width, height
bool FullScreen; // Start fullscreen, ignoring Geometry.
bool ShowBorders; // Show window decorations
// if StereoType is specified, it overrides the settings provided on the
// command line. -1 is not defined. 0 is no stereo. Values are in
// vtkRenderWindow.h (VTK_STEREO_*).
int StereoType;
int CaveBoundsSet; // have the cave bounds been set
// store the cave bounds all 0.0 if not set
double LowerLeft[3];
double LowerRight[3];
double UpperRight[3];
};
void PrintSelf(ostream& os, vtkIndent indent)
{
os << indent << "Eye Separation: " << this->EyeSeparation << "\n";
os << indent << "Machine Information :\n";
vtkIndent ind = indent.GetNextIndent();
for(unsigned int i =0; i < this->MachineInformationVector.size(); ++i)
{
MachineInformation& minfo = this->MachineInformationVector[i];
os << ind << "Node: " << i << "\n";
vtkIndent ind2 = ind.GetNextIndent();
os << ind2 << "Name: " << minfo.Name.c_str() << "\n";
os << ind2 << "Environment: " << minfo.Environment.c_str() << "\n";
os << ind2 << "Geometry: ";
for(int j = 0; j < 4; ++j)
{
os << minfo.Geometry[j] << (j < 4 ? " " : "\n");
}
os << ind2 << "FullScreen: " << minfo.FullScreen << "\n";
os << ind2 << "ShowBorders: " << minfo.ShowBorders << "\n";
os << ind2 << "StereoType: " << minfo.StereoType << "\n";
if(minfo.CaveBoundsSet)
{
int j;
os << ind2 << "LowerLeft: ";
for(j=0; j < 3; ++j)
{
os << minfo.LowerLeft[j] << " ";
}
os << "\n" << ind2 << "LowerRight: ";
for(j=0; j < 3; ++j)
{
os << minfo.LowerRight[j] << " ";
}
os << "\n" << ind2 << "UpperRight: ";
for(j=0; j < 3; ++j)
{
os << minfo.UpperRight[j] << " ";
}
os << "\n";
}
else
{
os << ind2 << "No Cave Options\n";
}
}
}
std::vector<MachineInformation> MachineInformationVector; // store the vector of machines
double EyeSeparation; // Store Eye Separation information required for VR module
};
#endif
// VTK-HeaderTest-Exclude: vtkPVServerOptionsInternals.h
|