CigiLosSegReqV3_2 Class Reference

#include <CigiLosSegReqV3_2.h>

Inheritance diagram for CigiLosSegReqV3_2:

CigiBaseLosSegReq CigiBasePacket List of all members.

Public Member Functions

 CigiLosSegReqV3_2 ()
virtual ~CigiLosSegReqV3_2 ()
virtual int Pack (CigiBasePacket *Base, Cigi_uint8 *Buff, void *Spec) const
virtual int Unpack (Cigi_uint8 *Buff, bool Swap, void *Spec)
int SetReqType (const ReqTypeGrp ReqTypeIn, bool bndchk=true)
ReqTypeGrp GetReqType (void) const
int SetSrcCoordSys (const CoordSysGrp SrcCoordSysIn, bool bndchk=true)
CoordSysGrp GetSrcCoordSys (void) const
int SetDstCoordSys (const CoordSysGrp DstCoordSysIn, bool bndchk=true)
CoordSysGrp GetDstCoordSys (void) const
int SetResponseCoordSys (const CoordSysGrp ResponseCoordSysIn, bool bndchk=true)
CoordSysGrp GetResponseCoordSys (void) const
int SetDestEntityIDValid (const bool DestEntityIDValidIn, bool bndchk=true)
bool GetDestEntityIDValid (void) const
int SetAlphaThresh (const Cigi_uint8 AlphaThreshIn, bool bndchk=true)
Cigi_uint8 GetAlphaThresh (void) const
int SetEntityID (const Cigi_uint16 EntityIDIn, bool bndchk=true)
Cigi_uint16 GetEntityID (void) const
int SetSrcXoff (const double SrcXoffIn, bool bndchk=true)
double GetSrcXoff (void) const
int SetSrcYoff (const double SrcYoffIn, bool bndchk=true)
double GetSrcYoff (void) const
int SetSrcZoff (const double SrcZoffIn, bool bndchk=true)
double GetSrcZoff (void) const
int SetDstXoff (const double DstXoffIn, bool bndchk=true)
double GetDstXoff (void) const
int SetDstYoff (const double DstYoffIn, bool bndchk=true)
double GetDstYoff (void) const
int SetDstZoff (const double DstZoffIn, bool bndchk=true)
double GetDstZoff (void) const
int SetMask (const Cigi_uint32 MaskIn, bool bndchk=true)
Cigi_uint32 GetMask (void) const
int SetUpdatePeriod (const Cigi_uint8 UpdatePeriodIn, bool bndchk=true)
Cigi_uint8 GetUpdatePeriod (void) const
int SetDestEntityID (const Cigi_uint16 DestEntityIDIn, bool bndchk=true)
Cigi_uint16 GetDestEntityID (void) const

Detailed Description

Definition at line 55 of file CigiLosSegReqV3_2.h.


Constructor & Destructor Documentation

CigiLosSegReqV3_2::CigiLosSegReqV3_2 (  ) 

General Constructor

Definition at line 62 of file CigiLosSegReqV3_2.cpp.

References CigiBaseLosSegReq::AlphaThresh, CigiBaseLosSegReq::Basic, CIGI_LOS_SEG_REQ_PACKET_ID_V3_2, CIGI_LOS_SEG_REQ_PACKET_SIZE_V3_2, CigiBaseLosSegReq::DestEntityID, CigiBaseLosSegReq::DestEntityIDValid, CigiBaseLosSegReq::DstCoordSys, CigiBaseLosSegReq::DstXLat, CigiBaseLosSegReq::DstYLon, CigiBaseLosSegReq::DstZAlt, CigiBaseLosSegReq::EntityID, CigiBaseLosSegReq::Geodetic, CigiBaseLosSegReq::LosID, CigiBaseLosSegReq::Mask, CigiBasePacket::MinorVersion, CigiBasePacket::PacketID, CigiBasePacket::PacketSize, CigiBaseLosSegReq::ReqType, CigiBaseLosSegReq::ResponseCoordSys, CigiBaseLosSegReq::SrcCoordSys, CigiBaseLosSegReq::SrcXLat, CigiBaseLosSegReq::SrcYLon, CigiBaseLosSegReq::SrcZAlt, CigiBaseLosSegReq::UpdatePeriod, CigiBaseLosSegReq::ValidV1or2, and CigiBasePacket::Version.

00063 {
00064 
00065    PacketID = CIGI_LOS_SEG_REQ_PACKET_ID_V3_2;
00066    PacketSize = CIGI_LOS_SEG_REQ_PACKET_SIZE_V3_2;
00067    Version = 3;
00068    MinorVersion = 2;
00069 
00070    LosID = 0;
00071    ReqType = Basic;
00072    SrcCoordSys = Geodetic;
00073    DstCoordSys = Geodetic;
00074    ResponseCoordSys = Geodetic;
00075    AlphaThresh = 0;
00076    EntityID = 0;
00077    SrcXLat = 0.0;
00078    SrcYLon = 0.0;
00079    SrcZAlt = 0.0;
00080    DstXLat = 0.0;
00081    DstYLon = 0.0;
00082    DstZAlt = 0.0;
00083    Mask = 0;
00084    DestEntityIDValid = false;
00085    UpdatePeriod = 0;
00086    DestEntityID = 0;
00087    ValidV1or2 = true;
00088 
00089 }

CigiLosSegReqV3_2::~CigiLosSegReqV3_2 (  )  [virtual]

General Destructor

Definition at line 94 of file CigiLosSegReqV3_2.cpp.

00095 {
00096 
00097 }


Member Function Documentation

Cigi_uint8 CigiLosSegReqV3_2::GetAlphaThresh ( void   )  const [inline]

Gets the AlphaThresh value.

Returns:
the current AlphaThresh.

Definition at line 225 of file CigiLosSegReqV3_2.h.

00225 { return(AlphaThresh); }

Cigi_uint16 CigiLosSegReqV3_2::GetDestEntityID ( void   )  const [inline]

Gets the Mask value.

Returns:
the current Mask.

Definition at line 448 of file CigiLosSegReqV3_2.h.

00448 { return(DestEntityID); }

bool CigiLosSegReqV3_2::GetDestEntityIDValid ( void   )  const [inline]

Gets the DestEntityIDValid value.

Returns:
the current DestEntityIDValid.

Definition at line 203 of file CigiLosSegReqV3_2.h.

00203 { return(DestEntityIDValid); }

CoordSysGrp CigiLosSegReqV3_2::GetDstCoordSys ( void   )  const [inline]

Gets the DstCoordSys value.

Returns:
the current DstCoordSys.

Definition at line 161 of file CigiLosSegReqV3_2.h.

00161 { return(DstCoordSys); }

double CigiLosSegReqV3_2::GetDstXoff ( void   )  const [inline]

Gets the DstXoff value.

Returns:
the current DstXoff.

Definition at line 336 of file CigiLosSegReqV3_2.h.

00336 { return(DstXLat); }

double CigiLosSegReqV3_2::GetDstYoff ( void   )  const [inline]

Gets the DstYoff value.

Returns:
the current DstYoff.

Definition at line 358 of file CigiLosSegReqV3_2.h.

00358 { return(DstYLon); }

double CigiLosSegReqV3_2::GetDstZoff ( void   )  const [inline]

Gets the DstZoff value.

Returns:
the current DstZoff.

Definition at line 380 of file CigiLosSegReqV3_2.h.

00380 { return(DstZAlt); }

Cigi_uint16 CigiLosSegReqV3_2::GetEntityID ( void   )  const [inline]

Gets the EntityID value.

Returns:
the current EntityID.

Definition at line 248 of file CigiLosSegReqV3_2.h.

00248 { return(EntityID); }

Cigi_uint32 CigiLosSegReqV3_2::GetMask ( void   )  const [inline]

Gets the Mask value.

Returns:
the current Mask.

Definition at line 402 of file CigiLosSegReqV3_2.h.

00402 { return(Mask); }

ReqTypeGrp CigiLosSegReqV3_2::GetReqType ( void   )  const [inline]

Gets the ReqType value.

Returns:
the current ReqType.

Definition at line 121 of file CigiLosSegReqV3_2.h.

00121 { return(ReqType); }

CoordSysGrp CigiLosSegReqV3_2::GetResponseCoordSys ( void   )  const [inline]

Gets the ResponseCoordSys value.

Returns:
the current ResponseCoordSys.

Definition at line 181 of file CigiLosSegReqV3_2.h.

00181 { return(ResponseCoordSys); }

CoordSysGrp CigiLosSegReqV3_2::GetSrcCoordSys ( void   )  const [inline]

Gets the SrcCoordSys value.

Returns:
the current SrcCoordSys.

Definition at line 141 of file CigiLosSegReqV3_2.h.

00141 { return(SrcCoordSys); }

double CigiLosSegReqV3_2::GetSrcXoff ( void   )  const [inline]

Gets the SrcXoff value.

Returns:
the current SrcXoff.

Definition at line 270 of file CigiLosSegReqV3_2.h.

00270 { return(SrcXLat); }

double CigiLosSegReqV3_2::GetSrcYoff ( void   )  const [inline]

Gets the SrcYoff value.

Returns:
the current SrcYoff.

Definition at line 292 of file CigiLosSegReqV3_2.h.

00292 { return(SrcYLon); }

double CigiLosSegReqV3_2::GetSrcZoff ( void   )  const [inline]

Gets the SrcZoff value.

Returns:
the current SrcZoff.

Definition at line 314 of file CigiLosSegReqV3_2.h.

00314 { return(SrcZAlt); }

Cigi_uint8 CigiLosSegReqV3_2::GetUpdatePeriod ( void   )  const [inline]

Gets the Update Period value.

Returns:
The number of frames between each hat/hot response from the IG. If zero - the IG should only respond with one hat/hot response.

Definition at line 427 of file CigiLosSegReqV3_2.h.

00427 { return(UpdatePeriod); }

int CigiLosSegReqV3_2::Pack ( CigiBasePacket Base,
Cigi_uint8 Buff,
void *  Spec 
) const [virtual]

The virtual Pack function for CIGI 3

Parameters:
Base - A pointer to the instance of the packet to be packed. (Downcast to CigiBasePacket)
Buff - A pointer to the current pack point.
Spec - A pointer to special data - This is not used in this class.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Implements CigiBaseLosSegReq.

Definition at line 106 of file CigiLosSegReqV3_2.cpp.

References CigiBaseLosSegReq::AlphaThresh, CigiBaseLosSegReq::Basic, PackPointerUnion::c, PackPointerUnion::d, CigiBaseLosSegReq::DestEntityID, CigiBaseLosSegReq::DestEntityIDValid, CigiBaseLosSegReq::DstCoordSys, CigiBaseLosSegReq::DstXLat, CigiBaseLosSegReq::DstYLon, CigiBaseLosSegReq::DstZAlt, CigiBaseLosSegReq::EntityID, CigiBaseLosSegReq::Geodetic, PackPointerUnion::l, CigiBaseLosSegReq::LosID, CigiBaseLosSegReq::Mask, CigiBasePacket::PacketID, CigiBasePacket::PacketSize, CigiBaseLosSegReq::ReqType, CigiBaseLosSegReq::ResponseCoordSys, PackPointerUnion::s, CigiBaseLosSegReq::SrcCoordSys, CigiBaseLosSegReq::SrcXLat, CigiBaseLosSegReq::SrcYLon, CigiBaseLosSegReq::SrcZAlt, and CigiBaseLosSegReq::UpdatePeriod.

00107 {
00108    PackPointer CDta;
00109 
00110    CigiBaseLosSegReq * Data = ( CigiBaseLosSegReq *)Base;
00111 
00112    CDta.c = Buff;
00113 
00114    *CDta.c++ = PacketID;
00115    *CDta.c++ = PacketSize;
00116 
00117    *CDta.s++ = Data->LosID;
00118 
00119    Cigi_uint8 HDta = (Data->ReqType == Basic) ? 0x00 : 0x01;
00120    HDta |= (Data->SrcCoordSys == Geodetic) ? 0x00 : 0x02;
00121    HDta |= (Data->DstCoordSys == Geodetic) ? 0x00 : 0x04;
00122    HDta |= (Data->ResponseCoordSys == Geodetic) ? 0x00 : 0x08;
00123    HDta |= (Data->DestEntityIDValid) ? 0x10 : 0x00;
00124    *CDta.c++ = HDta;
00125 
00126    *CDta.c++ = Data->AlphaThresh;
00127    *CDta.s++ = Data->EntityID;
00128    *CDta.d++ = Data->SrcXLat;
00129    *CDta.d++ = Data->SrcYLon;
00130    *CDta.d++ = Data->SrcZAlt;
00131    *CDta.d++ = Data->DstXLat;
00132    *CDta.d++ = Data->DstYLon;
00133    *CDta.d++ = Data->DstZAlt;
00134    *CDta.l++ = Data->Mask;
00135    *CDta.c++ = Data->UpdatePeriod;
00136    *CDta.c++ = 0;
00137    *CDta.s++ = Data->DestEntityID;
00138 
00139    return(PacketSize);
00140 
00141 }

int CigiLosSegReqV3_2::SetAlphaThresh ( const Cigi_uint8  AlphaThreshIn,
bool  bndchk = true 
) [inline]

Sets the AlphaThresh with bound checking control

Parameters:
AlphaThreshIn - The IG will only register an intersection when the intersected polygon has an alpha of this value or higher.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 216 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00217    {
00218       AlphaThresh = AlphaThreshIn;
00219       return(CIGI_SUCCESS);
00220    }

int CigiLosSegReqV3_2::SetDestEntityID ( const Cigi_uint16  DestEntityIDIn,
bool  bndchk = true 
) [inline]

Sets the DestEntityID with bound checking control

Parameters:
DestEntityIDIn - The destination entity's ID.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 439 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00440    {
00441       DestEntityID = DestEntityIDIn;
00442       return(CIGI_SUCCESS);
00443    }

int CigiLosSegReqV3_2::SetDestEntityIDValid ( const bool  DestEntityIDValidIn,
bool  bndchk = true 
) [inline]

Sets the DestEntityIDValid with bound checking control

Parameters:
DestEntityIDValidIn - Specifies whether the destination entity's ID is a valid value.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 194 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00195    {
00196       DestEntityIDValid = DestEntityIDValidIn;
00197       return(CIGI_SUCCESS);
00198    }

int CigiLosSegReqV3_2::SetDstCoordSys ( const CoordSysGrp  DstCoordSysIn,
bool  bndchk = true 
)

Sets the DstCoordSys with bound checking control

Parameters:
DstCoordSysIn - Specifies in which coordinate system the ending point is specified.
Geodetic=0
Entity=1
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 270 of file CigiLosSegReqV3_2.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, CigiBaseLosSegReq::DstCoordSys, CigiBaseLosSegReq::Geodetic, CigiBaseLosSegReq::SrcCoordSys, and CigiBaseLosSegReq::ValidV1or2.

00271 {
00272 
00273 #ifndef CIGI_NO_BND_CHK
00274    if(bndchk && ((DstCoordSysIn < 0)||(DstCoordSysIn > 1)))
00275    {
00276 #ifndef CIGI_NO_EXCEPT
00277       throw CigiValueOutOfRangeException("DstCoordSys",(CoordSysGrp)DstCoordSysIn,0,1);
00278 #endif
00279       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00280    }
00281 #endif
00282 
00283    DstCoordSys = DstCoordSysIn;
00284 
00285    ValidV1or2 = ((SrcCoordSys == Geodetic)&&
00286                  (DstCoordSys == Geodetic));
00287 
00288    return(CIGI_SUCCESS);
00289 
00290 }

int CigiLosSegReqV3_2::SetDstXoff ( const double  DstXoffIn,
bool  bndchk = true 
) [inline]

Sets the DstXoff with bound checking control

Parameters:
DstXoffIn - The destination point X axis offset in meters from the specified entity's origin.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 327 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00328    {
00329       DstXLat = DstXoffIn;
00330       return(CIGI_SUCCESS);
00331    }

int CigiLosSegReqV3_2::SetDstYoff ( const double  DstYoffIn,
bool  bndchk = true 
) [inline]

Sets the DstYoff with bound checking control

Parameters:
DstYoffIn - The destination point Y axis offset in meters from the specified entity's origin.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 349 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00350    {
00351       DstYLon = DstYoffIn;
00352       return(CIGI_SUCCESS);
00353    }

int CigiLosSegReqV3_2::SetDstZoff ( const double  DstZoffIn,
bool  bndchk = true 
) [inline]

Sets the DstZoff with bound checking control

Parameters:
DstZoffIn - The destination point Z axis offset in meters from the specified entity's origin.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 371 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00372    {
00373       DstZAlt = DstZoffIn;
00374       return(CIGI_SUCCESS);
00375    }

int CigiLosSegReqV3_2::SetEntityID ( const Cigi_uint16  EntityIDIn,
bool  bndchk = true 
) [inline]

Sets the EntityID with bound checking control

Parameters:
EntityIDIn - The Entity ID that the source and/or destination point is measured from when the coordinate system for that point is specified as "Entity"
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 239 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00240    {
00241       EntityID = EntityIDIn;
00242       return(CIGI_SUCCESS);
00243    }

int CigiLosSegReqV3_2::SetMask ( const Cigi_uint32  MaskIn,
bool  bndchk = true 
) [inline]

Sets the Mask with bound checking control

Parameters:
MaskIn - The material mask to turn on or off registration of intersections with polygons having specific material properties.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 393 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00394    {
00395       Mask = MaskIn;
00396       return(CIGI_SUCCESS);
00397    }

int CigiLosSegReqV3_2::SetReqType ( const ReqTypeGrp  ReqTypeIn,
bool  bndchk = true 
)

Sets the ReqType with bound checking control

Parameters:
ReqTypeIn - Request type
This specifies whether the response should be basic or extended.
Basic=0
Extended=1
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 222 of file CigiLosSegReqV3_2.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseLosSegReq::ReqType.

00223 {
00224 
00225 #ifndef CIGI_NO_BND_CHK
00226    if(bndchk && ((ReqTypeIn < 0)||(ReqTypeIn > 1)))
00227    {
00228 #ifndef CIGI_NO_EXCEPT
00229       throw CigiValueOutOfRangeException("ReqType",(ReqTypeGrp)ReqTypeIn,0,1);
00230 #endif
00231       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00232    }
00233 #endif
00234 
00235    ReqType = ReqTypeIn;
00236    return(CIGI_SUCCESS);
00237 
00238 }

int CigiLosSegReqV3_2::SetResponseCoordSys ( const CoordSysGrp  ResponseCoordSysIn,
bool  bndchk = true 
)

Sets the ResponseCoordSys with bound checking control

Parameters:
ResponseCoordSysIn - Specifies in which coordinate system the response intersection point is specified.
Geodetic=0
Entity=1
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 296 of file CigiLosSegReqV3_2.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, and CigiBaseLosSegReq::ResponseCoordSys.

00297 {
00298 
00299 #ifndef CIGI_NO_BND_CHK
00300    if(bndchk && ((ResponseCoordSysIn < 0)||(ResponseCoordSysIn > 1)))
00301    {
00302 #ifndef CIGI_NO_EXCEPT
00303       throw CigiValueOutOfRangeException("ResponseCoordSys",(CoordSysGrp)ResponseCoordSysIn,0,1);
00304 #endif
00305       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00306    }
00307 #endif
00308 
00309    ResponseCoordSys = ResponseCoordSysIn;
00310    return(CIGI_SUCCESS);
00311 
00312 }

int CigiLosSegReqV3_2::SetSrcCoordSys ( const CoordSysGrp  SrcCoordSysIn,
bool  bndchk = true 
)

Sets the SrcCoordSys with bound checking control

Parameters:
SrcCoordSysIn - Specifies in which coordinate system the starting point is specified.
Geodetic=0
Entity=1
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 244 of file CigiLosSegReqV3_2.cpp.

References CIGI_ERROR_VALUE_OUT_OF_RANGE, CIGI_SUCCESS, CigiBaseLosSegReq::DstCoordSys, CigiBaseLosSegReq::Geodetic, CigiBaseLosSegReq::SrcCoordSys, and CigiBaseLosSegReq::ValidV1or2.

00245 {
00246 
00247 #ifndef CIGI_NO_BND_CHK
00248    if(bndchk && ((SrcCoordSysIn < 0)||(SrcCoordSysIn > 1)))
00249    {
00250 #ifndef CIGI_NO_EXCEPT
00251       throw CigiValueOutOfRangeException("SrcCoordSys",(CoordSysGrp)SrcCoordSysIn,0,1);
00252 #endif
00253       return(CIGI_ERROR_VALUE_OUT_OF_RANGE);
00254    }
00255 #endif
00256 
00257    SrcCoordSys = SrcCoordSysIn;
00258 
00259    ValidV1or2 = ((SrcCoordSys == Geodetic)&&
00260                  (DstCoordSys == Geodetic));
00261 
00262    return(CIGI_SUCCESS);
00263 
00264 }

int CigiLosSegReqV3_2::SetSrcXoff ( const double  SrcXoffIn,
bool  bndchk = true 
) [inline]

Sets the SrcXoff with bound checking control

Parameters:
SrcXoffIn - The source point X axis offset in meters from the specified entity's origin.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 261 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00262    {
00263       SrcXLat = SrcXoffIn;
00264       return(CIGI_SUCCESS);
00265    }

int CigiLosSegReqV3_2::SetSrcYoff ( const double  SrcYoffIn,
bool  bndchk = true 
) [inline]

Sets the SrcYoff with bound checking control

Parameters:
SrcYoffIn - The source point Y axis offset in meters from the specified entity's origin.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 283 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00284    {
00285       SrcYLon = SrcYoffIn;
00286       return(CIGI_SUCCESS);
00287    }

int CigiLosSegReqV3_2::SetSrcZoff ( const double  SrcZoffIn,
bool  bndchk = true 
) [inline]

Sets the SrcZoff with bound checking control

Parameters:
SrcZoffIn - The source point Z axis offset in meters from the specified entity's origin.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 305 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00306    {
00307       SrcZAlt = SrcZoffIn;
00308       return(CIGI_SUCCESS);
00309    }

int CigiLosSegReqV3_2::SetUpdatePeriod ( const Cigi_uint8  UpdatePeriodIn,
bool  bndchk = true 
) [inline]

Sets the UpdatePeriod with bound checking control

Parameters:
UpdatePeriodIn - The number of frames between each LOS response from the IG. If zero - the IG should only respond with one hat/hot response.
bndchk - Enables (true) or disables (false) bounds checking.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Definition at line 416 of file CigiLosSegReqV3_2.h.

References CIGI_SUCCESS.

00417    {
00418       UpdatePeriod = UpdatePeriodIn;
00419       return(CIGI_SUCCESS);
00420    }

int CigiLosSegReqV3_2::Unpack ( Cigi_uint8 Buff,
bool  Swap,
void *  Spec 
) [virtual]

The virtual Unpack function for CIGI 3

Parameters:
Buff - A pointer to the current pack point.
Swap - N/A for V1 & V2
Spec - A pointer to special data - This is not used in this class.
Returns:
This returns CIGI_SUCCESS or an error code defined in CigiErrorCodes.h

Implements CigiBaseLosSegReq.

Definition at line 146 of file CigiLosSegReqV3_2.cpp.

References CigiBaseLosSegReq::AlphaThresh, PackPointerUnion::c, CigiSwap2(), CigiSwap4(), CigiSwap8(), PackPointerUnion::d, CigiBaseLosSegReq::DestEntityID, CigiBaseLosSegReq::DestEntityIDValid, CigiBaseLosSegReq::DstCoordSys, CigiBaseLosSegReq::DstXLat, CigiBaseLosSegReq::DstYLon, CigiBaseLosSegReq::DstZAlt, CigiBaseLosSegReq::EntityID, CigiBaseLosSegReq::Geodetic, PackPointerUnion::l, CigiBaseLosSegReq::LosID, CigiBaseLosSegReq::Mask, CigiBasePacket::PacketSize, CigiBaseLosSegReq::ReqType, CigiBaseLosSegReq::ResponseCoordSys, PackPointerUnion::s, CigiBaseLosSegReq::SrcCoordSys, CigiBaseLosSegReq::SrcXLat, CigiBaseLosSegReq::SrcYLon, CigiBaseLosSegReq::SrcZAlt, CigiBaseLosSegReq::UpdatePeriod, and CigiBaseLosSegReq::ValidV1or2.

00147 {
00148    PackPointer CDta;
00149 
00150    CDta.c = Buff;
00151 
00152    CDta.c += 2;  // Step over packet id and size
00153 
00154    if(!Swap)
00155    {
00156       LosID = *CDta.s++;
00157 
00158       Cigi_uint16 HDta = *CDta.c++;
00159       ReqType = (ReqTypeGrp)(HDta & 0x01);
00160       SrcCoordSys = (CoordSysGrp)((HDta >> 1) & 0x01);
00161       DstCoordSys = (CoordSysGrp)((HDta >> 2) & 0x01);
00162       ResponseCoordSys = (CoordSysGrp)((HDta >> 3) & 0x01);
00163       DestEntityIDValid = ((HDta & 0x10) != 0) ? true : false;
00164 
00165       AlphaThresh = *CDta.c++;
00166       EntityID = *CDta.s++;
00167       SrcXLat = *CDta.d++;
00168       SrcYLon = *CDta.d++;
00169       SrcZAlt = *CDta.d++;
00170       DstXLat = *CDta.d++;
00171       DstYLon = *CDta.d++;
00172       DstZAlt = *CDta.d++;
00173       Mask = *CDta.l++;
00174       UpdatePeriod = *CDta.c++;
00175       CDta.c++;
00176       DestEntityID = *CDta.s++;
00177    }
00178    else
00179    {
00180       CigiSwap2(&LosID, CDta.s++);
00181 
00182       Cigi_uint16 HDta = *CDta.c++;
00183       ReqType = (ReqTypeGrp)(HDta & 0x01);
00184       SrcCoordSys = (CoordSysGrp)((HDta >> 1) & 0x01);
00185       DstCoordSys = (CoordSysGrp)((HDta >> 2) & 0x01);
00186       ResponseCoordSys = (CoordSysGrp)((HDta >> 3) & 0x01);
00187       DestEntityIDValid = ((HDta & 0x10) != 0) ? true : false;
00188 
00189       AlphaThresh = *CDta.c++;
00190       CigiSwap2(&EntityID, CDta.s++);
00191       CigiSwap8(&SrcXLat, CDta.d++);
00192       CigiSwap8(&SrcYLon, CDta.d++);
00193       CigiSwap8(&SrcZAlt, CDta.d++);
00194       CigiSwap8(&DstXLat, CDta.d++);
00195       CigiSwap8(&DstYLon, CDta.d++);
00196       CigiSwap8(&DstZAlt, CDta.d++);
00197       CigiSwap4(&Mask, CDta.l++);
00198       UpdatePeriod = *CDta.c++;
00199       CDta.c++;
00200       CigiSwap2(&DestEntityID, CDta.s++);
00201    }
00202 
00203    
00204    ValidV1or2 = ((SrcCoordSys == Geodetic)&&
00205                  (DstCoordSys == Geodetic));
00206 
00207 
00208    return(PacketSize);
00209 
00210 }


The documentation for this class was generated from the following files:
Generated on Wed Apr 29 09:00:09 2009 for CCL by  doxygen 1.4.7