It is often necessary to refer to the base and current Frames
() within a FrameSet, but it can be
cumbersome having to obtain their indices from the Base and Current
attributes on each occasion. To make this easier, two parameter
constants, AST__BASE and AST__CURRENT, are defined in the AST_PAR
include file and may be used to represent the indices of the base and
current Frames respectively. They may be used whenever a Frame index
is required.
For example, when adding a new Frame to a FrameSet
(), you could use the following to indicate
that the new Frame is related to the existing current Frame, whatever
its index happens to be:
INTEGER FRAME, MAPPING
...
CALL AST_ADDFRAME( FRAMESET, AST__CURRENT, MAPPING, FRAME, STATUS )
Of course, the Frame you added would then become the new current Frame.
AST A Library for Handling World Coordinate Systems in Astronomy