28 bool toFile(QFile& out,
short dataVersion)
const override;
cmdLineReadable * params[]
Double version of ccGLMatrixTpl.
Serializable object interface.
QMultiMap< unsigned, unsigned > LoadedIDMap
Map of loaded unique IDs (old ID --> new ID)
Standard parameters for GL displays/viewports.
double zNearCoef
Theoretical perspective 'zNear' relative position.
float defaultLineWidth
Line width.
bool perspectiveView
Perspective view state.
float fov_deg
Camera F.O.V. (field of view) in degrees.
CCVector3d getViewDir() const
Returns the viewing direction.
static int ZNearCoefToIncrement(double coef, int iMax)
float pixelSize
Current pixel size (in 'current unit'/pixel)
CCVector3d cameraCenter
Camera center.
double computeWidthAtFocalDist() const
Computes the object 'width' at the 'focal' distance.
double focalDistance
Focal distance.
bool isSerializable() const override
Returns whether object is serializable of not.
ecvViewportParameters(const ecvViewportParameters ¶ms)
Copy constructor.
double computePixelSize(int glWidth) const
Computes the pixel size at the 'focal' distance.
float cameraAspectRatio
Camera aspect ratio.
double zFar
Actual perspective 'zFar' value.
ecvViewportParameters()
Default constructor.
ccGLMatrixd computeViewMatrix() const
Computes the view matrix.
double getFocalDistance() const
Computes the 'focal' distance.
bool toFile(QFile &out, short dataVersion) const override
Saves data to binary stream.
static double IncrementToZNearCoef(int i, int iMax)
const CCVector3d & getCameraCenter() const
Returns the camera center.
short minimumFileVersion() const override
Returns the minimum file version required to save this instance.
float defaultPointSize
Point size.
void setPivotPoint(const CCVector3d &P, bool autoUpdateFocal=true)
Sets the pivot point (for object-centered view mode)
const CCVector3d & getPivotPoint() const
Returns the pivot point (for object-centered view mode)
double computeDistanceToHalfWidthRatio() const
Computes the ratio 'distance to half width' (based on the current FOV)
ccGLMatrixd viewMat
Visualization matrix (rotation only)
void setCameraCenter(const CCVector3d &C, bool autoUpdateFocal=true)
Sets the camera center.
ccGLMatrixd computeScaleMatrix(const QRect &glViewport) const
Computes the scale matrix.
double computeDistanceToWidthRatio() const
Computes the ratio 'distance to width' (based on the current FOV)
bool fromFile(QFile &in, short dataVersion, int flags, LoadedIDMap &oldToNewIDMap) override
Loads data from binary stream.
CCVector3d pivotPoint
Rotation pivot point (for object-centered view modes)
void setFocalDistance(double distance)
Sets the 'focal' distance.
double zNear
Actual perspective 'zNear' value.
CCVector3d getUpDir() const
Returns the up direction.
const CCVector3d & getRotationCenter() const
Returns the view rotation 'center'.