Commit f0b439a9 authored by Philippe Pebay's avatar Philippe Pebay
Browse files

ENH: removed old-style angle unit conversions, used new generic angle

     conversion functions instead.
parent 8ac334ab
......@@ -22,7 +22,7 @@
#include <math.h>
vtkCxxRevisionMacro(vtkCamera, "1.116");
vtkCxxRevisionMacro(vtkCamera, "1.117");
//----------------------------------------------------------------------------
// Needed when we don't use the vtkStandardNewMacro.
......@@ -687,14 +687,14 @@ void vtkCamera::SetWindowCenter(double x, double y)
//----------------------------------------------------------------------------
void vtkCamera::SetObliqueAngles(double alpha, double beta)
{
alpha *= vtkMath::DoubleDegreesToRadians();
beta *= vtkMath::DoubleDegreesToRadians();
alpha = vtkMath::RadiansFromDegrees( alpha );
beta = vtkMath::RadiansFromDegrees( beta );
double cotbeta = cos(beta) / sin(beta);
double dxdz = cos(alpha) * cotbeta;
double dydz = sin(alpha) * cotbeta;
double cotbeta = cos( beta ) / sin( beta );
double dxdz = cos( alpha ) * cotbeta;
double dydz = sin( alpha ) * cotbeta;
this->SetViewShear(dxdz, dydz, 1.0);
this->SetViewShear( dxdz, dydz, 1.0 );
}
//----------------------------------------------------------------------------
......@@ -735,78 +735,78 @@ void vtkCamera::ComputePerspectiveTransform(double aspect,
this->PerspectiveTransform->Identity();
// apply user defined transform last if there is one
if (this->UserTransform)
if ( this->UserTransform )
{
this->PerspectiveTransform->Concatenate(this->UserTransform->GetMatrix());
this->PerspectiveTransform->Concatenate( this->UserTransform->GetMatrix() );
}
// adjust Z-buffer range
this->PerspectiveTransform->AdjustZBuffer(-1, +1, nearz, farz);
this->PerspectiveTransform->AdjustZBuffer( -1, +1, nearz, farz );
if (this->ParallelProjection)
if ( this->ParallelProjection)
{
// set up a rectangular parallelipiped
double width = this->ParallelScale*aspect;
double width = this->ParallelScale * aspect;
double height = this->ParallelScale;
double xmin = (this->WindowCenter[0]-1.0)*width;
double xmax = (this->WindowCenter[0]+1.0)*width;
double ymin = (this->WindowCenter[1]-1.0)*height;
double ymax = (this->WindowCenter[1]+1.0)*height;
double xmin = ( this->WindowCenter[0] - 1.0 ) * width;
double xmax = ( this->WindowCenter[0] + 1.0 ) * width;
double ymin = ( this->WindowCenter[1] - 1.0 ) * height;
double ymax = ( this->WindowCenter[1] + 1.0 ) * height;
this->PerspectiveTransform->Ortho(xmin,xmax,ymin,ymax,
this->ClippingRange[0],
this->ClippingRange[1]);
this->PerspectiveTransform->Ortho( xmin, xmax, ymin, ymax,
this->ClippingRange[0],
this->ClippingRange[1] );
}
else
{
// set up a perspective frustum
double tmp = tan(this->ViewAngle*vtkMath::DoubleDegreesToRadians()/2);
double tmp = tan( vtkMath::RadiansFromDegrees( this->ViewAngle ) / 2. );
double width;
double height;
if (this->UseHorizontalViewAngle)
if ( this->UseHorizontalViewAngle )
{
width = this->ClippingRange[0]*tmp;
height = this->ClippingRange[0]*tmp/aspect;
width = this->ClippingRange[0] * tmp;
height = this->ClippingRange[0] * tmp / aspect;
}
else
{
width = this->ClippingRange[0]*tmp*aspect;
height = this->ClippingRange[0]*tmp;
width = this->ClippingRange[0] * tmp * aspect;
height = this->ClippingRange[0] * tmp;
}
double xmin = (this->WindowCenter[0]-1.0)*width;
double xmax = (this->WindowCenter[0]+1.0)*width;
double ymin = (this->WindowCenter[1]-1.0)*height;
double ymax = (this->WindowCenter[1]+1.0)*height;
double xmin = ( this->WindowCenter[0] - 1.0 ) * width;
double xmax = ( this->WindowCenter[0] + 1.0 ) * width;
double ymin = ( this->WindowCenter[1] - 1.0 ) * height;
double ymax = ( this->WindowCenter[1] + 1.0 ) * height;
this->PerspectiveTransform->Frustum(xmin, xmax, ymin, ymax,
this->ClippingRange[0],
this->ClippingRange[1]);
this->PerspectiveTransform->Frustum( xmin, xmax, ymin, ymax,
this->ClippingRange[0],
this->ClippingRange[1] );
}
if (this->Stereo)
if ( this->Stereo )
{
// set up a shear for stereo views
if (this->LeftEye)
if ( this->LeftEye )
{
this->PerspectiveTransform->Stereo(-this->EyeAngle/2,
this->Distance);
this->PerspectiveTransform->Stereo( -this->EyeAngle/2,
this->Distance );
}
else
{
this->PerspectiveTransform->Stereo(+this->EyeAngle/2,
this->Distance);
this->PerspectiveTransform->Stereo( +this->EyeAngle/2,
this->Distance );
}
}
if (this->ViewShear[0] != 0.0 || this->ViewShear[1] != 0.0)
if ( this->ViewShear[0] != 0.0 || this->ViewShear[1] != 0.0 )
{
this->PerspectiveTransform->Shear(this->ViewShear[0],
this->ViewShear[1],
this->ViewShear[2]*this->Distance);
this->PerspectiveTransform->Shear( this->ViewShear[0],
this->ViewShear[1],
this->ViewShear[2] * this->Distance );
}
}
......
......@@ -51,7 +51,7 @@ using vtksys_ios::ofstream;
# define SNPRINTF snprintf
#endif
vtkCxxRevisionMacro(vtkDynamic2DLabelMapper, "1.11");
vtkCxxRevisionMacro(vtkDynamic2DLabelMapper, "1.12");
vtkStandardNewMacro(vtkDynamic2DLabelMapper);
//----------------------------------------------------------------------------
......@@ -599,16 +599,16 @@ double vtkDynamic2DLabelMapper::GetCurrentScale(vtkViewport *viewport)
// The current scale is the size on the screen of 1 unit in the xy plane
vtkRenderer* ren = vtkRenderer::SafeDownCast(viewport);
if (!ren)
if ( ! ren )
{
vtkErrorMacro("vtkDynamic2DLabelMapper only works in a vtkRenderer or subclass");
return 1.0;
}
vtkCamera* camera = ren->GetActiveCamera();
if (camera->GetParallelProjection())
if ( camera->GetParallelProjection() )
{
// For parallel projection, the scale depends on the parallel scale
double scale = (ren->GetSize()[1] / 2.0) / camera->GetParallelScale();
double scale = ( ren->GetSize()[1] / 2.0 ) / camera->GetParallelScale();
return scale;
}
else
......@@ -616,7 +616,7 @@ double vtkDynamic2DLabelMapper::GetCurrentScale(vtkViewport *viewport)
// For perspective projection, the scale depends on the view angle
double viewAngle = camera->GetViewAngle();
double distZ = camera->GetPosition()[2] > 0 ? camera->GetPosition()[2] : -camera->GetPosition()[2];
double unitAngle = atan2(1.0, distZ)*vtkMath::RadiansToDegrees();
double unitAngle = vtkMath::DegreesFromRadians( atan2( 1.0, distZ ) );
double scale = ren->GetSize()[1] * unitAngle / viewAngle;
return scale;
}
......
......@@ -39,7 +39,7 @@
#define VTK_FTFC_DEBUG_CD 0
//----------------------------------------------------------------------------
vtkCxxRevisionMacro(vtkFreeTypeUtilities, "1.29");
vtkCxxRevisionMacro(vtkFreeTypeUtilities, "1.30");
vtkInstantiatorNewMacro(vtkFreeTypeUtilities);
//----------------------------------------------------------------------------
......@@ -427,14 +427,14 @@ vtkFreeTypeUtilitiesFaceRequester(FTC_FaceID face_id,
<< ", I: " << tprop->GetItalic()
<< ", O: " << tprop->GetOrientation() << ")" << endl;
#endif
if (tprop->GetOrientation() != 0.0)
if ( tprop->GetOrientation() != 0.0 )
{
// FreeType documentation says that the transform should not be set
// but we cache faces also by transform, so that there is a unique
// (face, orientation) cache entry
FT_Matrix matrix;
float angle = vtkMath::DegreesToRadians() * tprop->GetOrientation();
float angle = vtkMath::RadiansFromDegrees( tprop->GetOrientation() );
matrix.xx = (FT_Fixed)( cos(angle) * 0x10000L);
matrix.xy = (FT_Fixed)(-sin(angle) * 0x10000L);
matrix.yx = (FT_Fixed)( sin(angle) * 0x10000L);
......
......@@ -25,7 +25,7 @@
#include "vtkTransform.h"
#include "vtkMatrix4x4.h"
vtkCxxRevisionMacro(vtkInteractorStyleJoystickActor, "1.34");
vtkCxxRevisionMacro(vtkInteractorStyleJoystickActor, "1.35");
vtkStandardNewMacro(vtkInteractorStyleJoystickActor);
//----------------------------------------------------------------------------
......@@ -265,10 +265,10 @@ void vtkInteractorStyleJoystickActor::Rotate()
}
double newXAngle =
asin(nxf) * vtkMath::RadiansToDegrees() / this->MotionFactor;
vtkMath::DegreesFromRadians( asin( nxf ) ) / this->MotionFactor;
double newYAngle =
asin(nyf) * vtkMath::RadiansToDegrees() / this->MotionFactor;
vtkMath::DegreesFromRadians( asin( nyf ) ) / this->MotionFactor;
double scale[3];
scale[0] = scale[1] = scale[2] = 1.0;
......@@ -358,7 +358,7 @@ void vtkInteractorStyleJoystickActor::Spin()
}
double newAngle =
asin(yf) * vtkMath::RadiansToDegrees() / this->MotionFactor;
vtkMath::DegreesFromRadians( asin( yf ) ) / this->MotionFactor;
double scale[3];
scale[0] = scale[1] = scale[2] = 1.0;
......
......@@ -21,7 +21,7 @@
#include "vtkRenderer.h"
#include "vtkRenderWindowInteractor.h"
vtkCxxRevisionMacro(vtkInteractorStyleJoystickCamera, "1.33");
vtkCxxRevisionMacro(vtkInteractorStyleJoystickCamera, "1.34");
vtkStandardNewMacro(vtkInteractorStyleJoystickCamera);
//----------------------------------------------------------------------------
......@@ -269,21 +269,21 @@ void vtkInteractorStyleJoystickCamera::Spin()
// Spin is based on y value
double yf = (rwi->GetEventPosition()[1] - center[1]) / center[1];
double yf = ( rwi->GetEventPosition()[1] - center[1] ) / center[1];
if (yf > 1)
if ( yf > 1. )
{
yf = 1;
yf = 1.;
}
else if (yf < -1)
else if ( yf < -1. )
{
yf = -1;
yf = -1.;
}
double newAngle = asin(yf) * vtkMath::RadiansToDegrees();
double newAngle = vtkMath::DegreesFromRadians( asin( yf ) );
vtkCamera* camera = this->CurrentRenderer->GetActiveCamera();
camera->Roll(newAngle);
camera->Roll( newAngle );
camera->OrthogonalizeViewUp();
rwi->Render();
......
......@@ -27,7 +27,7 @@
#include "vtkRenderer.h"
#include "vtkSphereSource.h"
vtkCxxRevisionMacro(vtkInteractorStyleTerrain, "1.13");
vtkCxxRevisionMacro(vtkInteractorStyleTerrain, "1.14");
vtkStandardNewMacro(vtkInteractorStyleTerrain);
//----------------------------------------------------------------------------
......@@ -192,17 +192,17 @@ void vtkInteractorStyleTerrain::Rotate()
vtkRenderWindowInteractor *rwi = this->Interactor;
int dx = - (rwi->GetEventPosition()[0] - rwi->GetLastEventPosition()[0]);
int dy = - (rwi->GetEventPosition()[1] - rwi->GetLastEventPosition()[1]);
int dx = - ( rwi->GetEventPosition()[0] - rwi->GetLastEventPosition()[0] );
int dy = - ( rwi->GetEventPosition()[1] - rwi->GetLastEventPosition()[1] );
int *size = this->CurrentRenderer->GetRenderWindow()->GetSize();
double a = dx / static_cast<double>(size[0]) * 180.0;
double e = dy / static_cast<double>(size[1]) * 180.0;
double a = dx / static_cast<double>( size[0]) * 180.0;
double e = dy / static_cast<double>( size[1]) * 180.0;
if (rwi->GetShiftKey())
{
if(abs(dx) >= abs(dy))
if(abs( dx ) >= abs( dy ))
{
e = 0.0;
}
......@@ -216,26 +216,25 @@ void vtkInteractorStyleTerrain::Rotate()
// Make sure that we don't hit the north pole singularity.
vtkCamera *camera = this->CurrentRenderer->GetActiveCamera();
camera->Azimuth(a);
camera->Azimuth( a );
double dop[3], vup[3];
camera->GetDirectionOfProjection(dop);
vtkMath::Normalize(dop);
camera->GetViewUp(vup);
vtkMath::Normalize(vup);
camera->GetDirectionOfProjection( dop );
vtkMath::Normalize( dop );
camera->GetViewUp( vup );
vtkMath::Normalize( vup );
double angle =
acos(vtkMath::Dot(dop, vup)) / vtkMath::DoubleDegreesToRadians();
if ((angle + e) > 179.0 ||
(angle + e) < 1.0)
double angle = vtkMath::DegreesFromRadians( acos(vtkMath::Dot( dop, vup) ) );
if ( ( angle + e ) > 179.0 ||
( angle + e ) < 1.0 )
{
e = 0.0;
}
camera->Elevation(e);
camera->Elevation( e );
if (this->AutoAdjustCameraClippingRange)
if ( this->AutoAdjustCameraClippingRange )
{
this->CurrentRenderer->ResetCameraClippingRange();
}
......@@ -258,8 +257,8 @@ void vtkInteractorStyleTerrain::Pan()
double fp[3], focalPoint[3], pos[3], v[3], p1[4], p2[4];
vtkCamera *camera = this->CurrentRenderer->GetActiveCamera();
camera->GetPosition(pos);
camera->GetFocalPoint(fp);
camera->GetPosition( pos );
camera->GetFocalPoint( fp );
this->ComputeWorldToDisplay(fp[0], fp[1], fp[2],
focalPoint);
......@@ -281,8 +280,8 @@ void vtkInteractorStyleTerrain::Pan()
fp[i] += v[i];
}
camera->SetPosition(pos);
camera->SetFocalPoint(fp);
camera->SetPosition( pos );
camera->SetFocalPoint( fp );
if (rwi->GetLightFollowCamera())
{
......@@ -314,7 +313,7 @@ void vtkInteractorStyleTerrain::Dolly()
}
else
{
camera->Dolly(zoomFactor);
camera->Dolly( zoomFactor );
if (this->AutoAdjustCameraClippingRange)
{
this->CurrentRenderer->ResetCameraClippingRange();
......@@ -347,11 +346,11 @@ void vtkInteractorStyleTerrain::OnChar()
else
{
double bounds[6];
this->CurrentRenderer->ComputeVisiblePropBounds(bounds);
this->CurrentRenderer->ComputeVisiblePropBounds( bounds );
double radius = sqrt((bounds[1]-bounds[0])*(bounds[1]-bounds[0]) +
(bounds[3]-bounds[2])*(bounds[3]-bounds[2]) +
(bounds[5]-bounds[4])*(bounds[5]-bounds[4])) /2.0;
this->LatLongSphere->SetRadius(radius);
this->LatLongSphere->SetRadius( radius );
this->LatLongSphere->SetCenter((bounds[0]+bounds[1])/2.0,
(bounds[2]+bounds[3])/2.0,
(bounds[4]+bounds[5])/2.0);
......@@ -373,8 +372,8 @@ void vtkInteractorStyleTerrain::CreateLatLong()
if (this->LatLongSphere == NULL)
{
this->LatLongSphere = vtkSphereSource::New();
this->LatLongSphere->SetPhiResolution(13);
this->LatLongSphere->SetThetaResolution(25);
this->LatLongSphere->SetPhiResolution( 13 );
this->LatLongSphere->SetThetaResolution( 25 );
this->LatLongSphere->LatLongTessellationOn();
}
......
......@@ -25,7 +25,7 @@
#include "vtkRenderer.h"
#include "vtkTransform.h"
vtkCxxRevisionMacro(vtkInteractorStyleTrackballActor, "1.36");
vtkCxxRevisionMacro(vtkInteractorStyleTrackballActor, "1.37");
vtkStandardNewMacro(vtkInteractorStyleTrackballActor);
//----------------------------------------------------------------------------
......@@ -269,10 +269,10 @@ void vtkInteractorStyleTrackballActor::Rotate()
if (((nxf * nxf + nyf * nyf) <= 1.0) &&
((oxf * oxf + oyf * oyf) <= 1.0))
{
double newXAngle = asin(nxf) * vtkMath::RadiansToDegrees();
double newYAngle = asin(nyf) * vtkMath::RadiansToDegrees();
double oldXAngle = asin(oxf) * vtkMath::RadiansToDegrees();
double oldYAngle = asin(oyf) * vtkMath::RadiansToDegrees();
double newXAngle = vtkMath::DegreesFromRadians( asin( nxf ) );
double newYAngle = vtkMath::DegreesFromRadians( asin( nyf ) );
double oldXAngle = vtkMath::DegreesFromRadians( asin( oxf ) );
double oldYAngle = vtkMath::DegreesFromRadians( asin( oyf ) );
double scale[3];
scale[0] = scale[1] = scale[2] = 1.0;
......@@ -315,7 +315,7 @@ void vtkInteractorStyleTrackballActor::Rotate()
//----------------------------------------------------------------------------
void vtkInteractorStyleTrackballActor::Spin()
{
if (this->CurrentRenderer == NULL || this->InteractionProp == NULL)
if ( this->CurrentRenderer == NULL || this->InteractionProp == NULL )
{
return;
}
......@@ -334,12 +334,12 @@ void vtkInteractorStyleTrackballActor::Spin()
{
// If parallel projection, want to get the view plane normal...
cam->ComputeViewPlaneNormal();
cam->GetViewPlaneNormal(motion_vector);
cam->GetViewPlaneNormal( motion_vector );
}
else
{
// Perspective projection, get vector from eye to center of actor
cam->GetPosition(view_point);
cam->GetPosition( view_point );
motion_vector[0] = view_point[0] - obj_center[0];
motion_vector[1] = view_point[1] - obj_center[1];
motion_vector[2] = view_point[2] - obj_center[2];
......@@ -352,15 +352,12 @@ void vtkInteractorStyleTrackballActor::Spin()
disp_obj_center);
double newAngle =
atan2(rwi->GetEventPosition()[1] - disp_obj_center[1],
rwi->GetEventPosition()[0] - disp_obj_center[0]);
vtkMath::DegreesFromRadians( atan2( rwi->GetEventPosition()[1] - disp_obj_center[1],
rwi->GetEventPosition()[0] - disp_obj_center[0] ) );
double oldAngle =
atan2(rwi->GetLastEventPosition()[1] - disp_obj_center[1],
rwi->GetLastEventPosition()[0] - disp_obj_center[0]);
newAngle *= vtkMath::RadiansToDegrees();
oldAngle *= vtkMath::RadiansToDegrees();
vtkMath::DegreesFromRadians( atan2( rwi->GetLastEventPosition()[1] - disp_obj_center[1],
rwi->GetLastEventPosition()[0] - disp_obj_center[0] ) );
double scale[3];
scale[0] = scale[1] = scale[2] = 1.0;
......@@ -373,16 +370,16 @@ void vtkInteractorStyleTrackballActor::Spin()
rotate[0][2] = motion_vector[1];
rotate[0][3] = motion_vector[2];
this->Prop3DTransform(this->InteractionProp,
obj_center,
1,
rotate,
scale);
this->Prop3DTransform( this->InteractionProp,
obj_center,
1,
rotate,
scale );
delete [] rotate[0];
delete [] rotate;
if (this->AutoAdjustCameraClippingRange)
if ( this->AutoAdjustCameraClippingRange )
{
this->CurrentRenderer->ResetCameraClippingRange();
}
......
......@@ -22,7 +22,7 @@
#include "vtkRenderWindowInteractor.h"
#include "vtkRenderer.h"
vtkCxxRevisionMacro(vtkInteractorStyleTrackballCamera, "1.36");
vtkCxxRevisionMacro(vtkInteractorStyleTrackballCamera, "1.37");
vtkStandardNewMacro(vtkInteractorStyleTrackballCamera);
//----------------------------------------------------------------------------
......@@ -270,7 +270,7 @@ void vtkInteractorStyleTrackballCamera::Rotate()
//----------------------------------------------------------------------------
void vtkInteractorStyleTrackballCamera::Spin()
{
if (this->CurrentRenderer == NULL)
if ( this->CurrentRenderer == NULL )
{
return;
}
......@@ -280,18 +280,15 @@ void vtkInteractorStyleTrackballCamera::Spin()
double *center = this->CurrentRenderer->GetCenter();
double newAngle =
atan2(rwi->GetEventPosition()[1] - center[1],
rwi->GetEventPosition()[0] - center[0]);
vtkMath::DegreesFromRadians( atan2( rwi->GetEventPosition()[1] - center[1],
rwi->GetEventPosition()[0] - center[0] ) );
double oldAngle =
atan2(rwi->GetLastEventPosition()[1] - center[1],
rwi->GetLastEventPosition()[0] - center[0]);
vtkMath::DegreesFromRadians( atan2( rwi->GetLastEventPosition()[1] - center[1],
rwi->GetLastEventPosition()[0] - center[0] ) );
newAngle *= vtkMath::RadiansToDegrees();
oldAngle *= vtkMath::RadiansToDegrees();
vtkCamera *camera = this->CurrentRenderer->GetActiveCamera();
camera->Roll(newAngle - oldAngle);
camera->Roll( newAngle - oldAngle );
camera->OrthogonalizeViewUp();
rwi->Render();
......
......@@ -190,7 +190,7 @@ protected:
double BoundsFactor;
};
vtkCxxRevisionMacro(vtkLabelHierarchyFrustumIterator,"1.11");
vtkCxxRevisionMacro(vtkLabelHierarchyFrustumIterator,"1.12");
vtkStandardNewMacro(vtkLabelHierarchyFrustumIterator);
vtkCxxSetObjectMacro(vtkLabelHierarchyFrustumIterator, Camera, vtkCamera);
vtkLabelHierarchyFrustumIterator::vtkLabelHierarchyFrustumIterator()
......@@ -350,8 +350,8 @@ void vtkLabelHierarchyFrustumIterator::Next()
int lvlMax = 1 << this->Level;
double sz = this->Hierarchy->Implementation->Hierarchy->root()->size() / 2.;
double eye[3];
//double vaMax = atan( vtkMath::Pi()/2. - 0.2 * this->Camera->GetViewAngle() * vtkMath::DoubleDegreesToRadians() );
double vaMin = atan( vtkMath::Pi()/2. - 2.0 * this->Camera->GetViewAngle() * vtkMath::DoubleDegreesToRadians() );
//double vaMax = atan( vtkMath::Pi()/2. - 0.2 * vtkMath::RadiansFromDegrees(t his->Camera->GetViewAngle() ) );
double vaMin = atan( vtkMath::Pi()/2. - 2.0 * vtkMath::RadiansFromDegrees( this->Camera->GetViewAngle() ) );
this->Camera->GetPosition( eye );
while ( ! gotNode )
{
......@@ -678,7 +678,7 @@ protected:
int NodesTraversed;
};
vtkCxxRevisionMacro(vtkLabelHierarchyFullSortIterator,"1.11");
vtkCxxRevisionMacro(vtkLabelHierarchyFullSortIterator,"1.12");
vtkStandardNewMacro(vtkLabelHierarchyFullSortIterator);
vtkCxxSetObjectMacro(vtkLabelHierarchyFullSortIterator, Camera, vtkCamera);
void vtkLabelHierarchyFullSortIterator::Prepare( vtkLabelHierarchy* hier, vtkCamera* cam,
......@@ -913,7 +913,7 @@ vtkLabelHierarchyFullSortIterator::~vtkLabelHierarchyFullSortIterator()
// vtkLabelHierarchy
vtkStandardNewMacro(vtkLabelHierarchy);
vtkCxxRevisionMacro(vtkLabelHierarchy,"1.11");
vtkCxxRevisionMacro(vtkLabelHierarchy,"1.12");
vtkCxxSetObjectMacro(vtkLabelHierarchy,Priorities,vtkDataArray);
vtkLabelHierarchy::vtkLabelHierarchy()
{
......
......@@ -25,7 +25,7 @@
#include "vtkObjectFactory.h"
#include "vtkMath.h"
vtkCxxRevisionMacro(vtkLeaderActor2D, "1.12");
vtkCxxRevisionMacro(vtkLeaderActor2D, "1.13");
vtkStandardNewMacro(vtkLeaderActor2D);
vtkCxxSetObjectMacro(vtkLeaderActor2D,LabelTextProperty,vtkTextProperty);
......@@ -539,7 +539,7 @@ void vtkLeaderActor2D::BuildCurvedLeader(double p1[3], double p2[3], double ray[
}
// Now insert lines. Only those not clipped by the string are added.
this->Angle = (theta1-theta2)*vtkMath::RadiansToDegrees();