VR-Exchange 2.9 API Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
linearSegmentData.h
Go to the documentation of this file.
1 /****************************************************************************
2  * Copyright (c) 2014 MAK Technologies, Inc.
3  * All rights reserved.
4  ****************************************************************************/
5 
9 
10 #pragma once
11 
12 #include <portal/dllExport.h>
13 #include <portal/addAttribute.h>
14 #include <matrix/vlTaitBryan.h>
15 #include <matrix/vlVector.h>
16 #include <vlutil/vlString.h>
17 #include <vlpi/disEnums.h>
18 #include <iosfwd>
19 #include <vector>
20 #include <list>
21 
24 #define DtDEC_APPEARANCE( P, p, T, N, n, E ) \
25  public : \
26  void set##N( const T& val ) {\
27  set##P##AppearanceAttribute( E, DtAppearAttrVal( val << E##BitShift ) );\
28  }\
29  T n() const { return (T)( p##AppearanceAttribute(E) >> E##BitShift ); }\
30 
31 namespace MAKVrExchange
32 {
33 
39  {
40  public:
41 
44 
46  DtLinearSegmentData( const DtLinearSegmentData& original );
47 
49  virtual ~DtLinearSegmentData();
50 
52  virtual DtLinearSegmentData& operator = ( const DtLinearSegmentData& original );
53 
56 
57  virtual bool operator != ( const DtLinearSegmentData& rightOperand ) const;
58  virtual bool operator == ( const DtLinearSegmentData& rightOperand ) const;
59 
61 
63  virtual std::ostream& printDataToStream( std::ostream& stream ) const;
64 
68 
69  DtDEC_ATTRIBUTE( DtU8, SegmentNumber, segmentNumber );
70  DtDEC_ATTRIBUTE( DtU8, Modifications, modifications );
71  DtDEC_ATTRIBUTE( DtU32, SpecificAppearance, specificAppearance );
72  DtDEC_ATTRIBUTE( DtU16, GeneralAppearance, generalAppearance );
73  DtDEC_ATTRIBUTE( DtVector, Location, location );
74  DtDEC_ATTRIBUTE( DtTaitBryan, Orientation, orientation );
75  DtDEC_ATTRIBUTE( DtU16, Length, length );
76  DtDEC_ATTRIBUTE( DtU16, Width, width );
77  DtDEC_ATTRIBUTE( DtU16, Height, height );
78  DtDEC_ATTRIBUTE( DtU16, Depth, depth );
79 
82 
84  virtual void setGeneralAppearanceAttribute(
85  DtAppearAttribute attr, DtAppearAttrVal val );
87  virtual DtAppearAttrVal generalAppearanceAttribute(
88  DtAppearAttribute attr ) const;
89 
90  DtDEC_APPEARANCE( General, general, DtU8, PercentComplete,
91  percentComplete, DtAppObjectPercentComplete );
92  DtDEC_APPEARANCE( General, general, DtDamageState, DamagedAppearance,
93  damagedAppearance, DtAppObjectDamage );
94  DtDEC_APPEARANCE( General, general, bool, ObjectPreDistributed,
95  objectPreDistributed, DtAppObjectPredistributed );
96  DtDEC_APPEARANCE( General, general, bool, Deactivated,
97  deactivated, DtAppObjectState );
98  DtDEC_APPEARANCE( General, general, bool, Smoking,
99  smoking, DtAppObjectSmoking );
100  DtDEC_APPEARANCE( General, general, bool, Flaming,
101  flaming, DtAppObjectFlaming );
102 
104 
107 
109  virtual void setSpecificAppearanceAttribute(
110  DtAppearAttribute attr, DtAppearAttrVal val );
112  virtual DtU32 specificAppearanceAttribute(
113  DtAppearAttribute attr ) const;
114 
117 
118  DtDEC_APPEARANCE( Specific, specific, DtTankDitchBreachStatus, BreachStatus,
119  breachStatus, DtAppObjectTankDitchBreach );
120  DtDEC_APPEARANCE( Specific, specific, DtU8, BreachLength,
121  breachLength, DtAppObjectTankDitchBreachLength );
122 
126  virtual bool setSegmentBreached( int index, bool state );
127  virtual bool segmentBreached( int index, bool& state ) const;
128 
130 
132 
134 
135  };
136 
137  typedef std::vector<DtLinearSegmentData> DtLinearSegmentParameterList;
138 
139  DT_DLL_LIBPORTAL std::ostream& operator << ( std::ostream& stream,
140  const DtLinearSegmentData& data );
141  DT_DLL_LIBPORTAL std::ostream& operator << ( std::ostream& stream,
142  const DtLinearSegmentParameterList& container );
143 
144 }
#define DT_DLL_LIBPORTAL
Definition: include/portal/dllExport.h:20
Represents Linear Segment Parameter Objects.
Definition: linearSegmentData.h:38
#define DtDEC_ATTRIBUTE(T, N, n)
A Macro to define an attribute; as well as make an accessor and mutator for that attribute.
Definition: addAttribute.h:49
#define DtDEC_APPEARANCE(P, p, T, N, n, E)
This macro defines a setter and getter for a specific attribute within the appearance attribute...
Definition: linearSegmentData.h:24
DT_DLL_LIBPORTAL std::ostream & operator<<(std::ostream &stream, const DtActiveSonarBeamData &data)
std::vector< DtLinearSegmentData > DtLinearSegmentParameterList
Definition: linearSegmentData.h:137
Contains the DtDEC_ATTRIBUTE macros.

Document ID: Generated on Tue Jun 25 16:45:35 EDT 2024 from SVN revision 267383
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)