ellipse.c   ellipse.c 
skipping to change at line 98 skipping to change at line 98
#include "object.h" /* Base Object class */ #include "object.h" /* Base Object class */
#include "pointset.h" /* Sets of points/coordinates */ #include "pointset.h" /* Sets of points/coordinates */
#include "region.h" /* Coordinate regions (parent class) */ #include "region.h" /* Coordinate regions (parent class) */
#include "channel.h" /* I/O channels */ #include "channel.h" /* I/O channels */
#include "box.h" /* Box Regions */ #include "box.h" /* Box Regions */
#include "wcsmap.h" /* Definitons of AST__DPI etc */ #include "wcsmap.h" /* Definitons of AST__DPI etc */
#include "circle.h" /* Interface definition for circle class * / #include "circle.h" /* Interface definition for circle class * /
#include "ellipse.h" /* Interface definition for this class */ #include "ellipse.h" /* Interface definition for this class */
#include "mapping.h" /* Position mappings */ #include "mapping.h" /* Position mappings */
#include "unitmap.h" /* Unit Mapping */ #include "unitmap.h" /* Unit Mapping */
#include "pal.h" /* SLALIB library interface */ #include "skyaxis.h" /* For astDrange */
#include "pal.h" /* Positional astronomy library */
/* Error code definitions. */ /* Error code definitions. */
/* ----------------------- */ /* ----------------------- */
#include "ast_err.h" /* AST error codes */ #include "ast_err.h" /* AST error codes */
/* C header files. */ /* C header files. */
/* --------------- */ /* --------------- */
#include <float.h> #include <float.h>
#include <math.h> #include <math.h>
#include <stdarg.h> #include <stdarg.h>
skipping to change at line 341 skipping to change at line 342
/* Find the higher index neighbouring point, wrapping back to the start /* Find the higher index neighbouring point, wrapping back to the start
of the list when the end is reached. Note the radius and position angle of the list when the end is reached. Note the radius and position angle
at this neighbouring point. */ at this neighbouring point. */
t2 = 0.0; t2 = 0.0;
r3 = AST__BAD; r3 = AST__BAD;
t3 = AST__BAD; t3 = AST__BAD;
a0 = ang[ maxat ]; a0 = ang[ maxat ];
for( ip = maxat + 1; ip < np; ip++ ) { for( ip = maxat + 1; ip < np; ip++ ) {
if( dist[ ip ] != AST__BAD ) { if( dist[ ip ] != AST__BAD ) {
r3 = dist[ ip ]; r3 = dist[ ip ];
t3 = palDrange( ang[ ip ] - a0 ); t3 = astDrange( ang[ ip ] - a0 );
break; break;
} }
} }
if( r3 == AST__BAD ) { if( r3 == AST__BAD ) {
for( ip = 0; ip < maxat; ip++ ) { for( ip = 0; ip < maxat; ip++ ) {
if( dist[ ip ] != AST__BAD ) { if( dist[ ip ] != AST__BAD ) {
r3 = dist[ ip ]; r3 = dist[ ip ];
t3 = palDrange( ang[ ip ] - a0 ); t3 = astDrange( ang[ ip ] - a0 );
break; break;
} }
} }
} }
/* Find the lower index neighbouring point, wrapping back to the end /* Find the lower index neighbouring point, wrapping back to the end
of the list when the start is reached. Note the radius and position angl e of the list when the start is reached. Note the radius and position angl e
at this neighbouring point. */ at this neighbouring point. */
r1 = AST__BAD; r1 = AST__BAD;
t1 = AST__BAD; t1 = AST__BAD;
for( ip = maxat - 1; ip > -1; ip-- ) { for( ip = maxat - 1; ip > -1; ip-- ) {
if( dist[ ip ] != AST__BAD ) { if( dist[ ip ] != AST__BAD ) {
r1 = dist[ ip ]; r1 = dist[ ip ];
t1 = palDrange( ang[ ip ] - a0 ); t1 = astDrange( ang[ ip ] - a0 );
break; break;
} }
} }
if( r1 == AST__BAD ) { if( r1 == AST__BAD ) {
for( ip = np - 1; ip > maxat; ip-- ) { for( ip = np - 1; ip > maxat; ip-- ) {
if( dist[ ip ] != AST__BAD ) { if( dist[ ip ] != AST__BAD ) {
r1 = dist[ ip ]; r1 = dist[ ip ];
t1 = palDrange( ang[ ip ] - a0 ); t1 = astDrange( ang[ ip ] - a0 );
break; break;
} }
} }
} }
/* Fit a quadratic through the three pairs of (radius,angle) values. The /* Fit a quadratic through the three pairs of (radius,angle) values. The
centre point (r2,t2) is the point which is furthest from the centre, centre point (r2,t2) is the point which is furthest from the centre,
and the other two are the neighbouring points found above. */ and the other two are the neighbouring points found above. */
a = r2 - r1; a = r2 - r1;
b = t2 - t1; b = t2 - t1;
 End of changes. 5 change blocks. 
5 lines changed or deleted 6 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/