File indexing completed on 2025-01-18 10:03:47
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015 #ifndef _Graphic3d_CubeMapOrder_HeaderFile
0016 #define _Graphic3d_CubeMapOrder_HeaderFile
0017
0018 #include <Graphic3d_CubeMapSide.hxx>
0019 #include <Standard_Macro.hxx>
0020
0021 class Graphic3d_ValidatedCubeMapOrder;
0022
0023
0024
0025
0026
0027 class Graphic3d_CubeMapOrder
0028 {
0029
0030 public:
0031
0032
0033
0034 Standard_EXPORT Graphic3d_CubeMapOrder();
0035
0036
0037 Standard_EXPORT Graphic3d_CubeMapOrder (unsigned char thePosXLocation,
0038 unsigned char theNegXLocation,
0039 unsigned char thePosYLocation,
0040 unsigned char theNegYLocation,
0041 unsigned char thePosZLocation,
0042 unsigned char theNegZLocation);
0043
0044
0045 Standard_EXPORT Graphic3d_CubeMapOrder (const Graphic3d_ValidatedCubeMapOrder& theOrder);
0046
0047
0048 Standard_EXPORT Graphic3d_CubeMapOrder& Set (const Graphic3d_CubeMapOrder& theOrder);
0049
0050
0051
0052
0053 Standard_EXPORT Graphic3d_ValidatedCubeMapOrder Validated() const;
0054
0055 public:
0056
0057
0058 Standard_EXPORT Graphic3d_CubeMapOrder& Set (Graphic3d_CubeMapSide theCubeMapSide, unsigned char theValue);
0059
0060
0061 Standard_EXPORT Graphic3d_CubeMapOrder& SetDefault();
0062
0063
0064 Standard_EXPORT Graphic3d_CubeMapOrder& Permute (const Graphic3d_ValidatedCubeMapOrder& anOrder);
0065
0066
0067 Standard_EXPORT Graphic3d_CubeMapOrder Permuted (const Graphic3d_ValidatedCubeMapOrder& anOrder) const;
0068
0069
0070 Standard_EXPORT Graphic3d_CubeMapOrder& Swap (Graphic3d_CubeMapSide theFirstSide,
0071 Graphic3d_CubeMapSide theSecondSide);
0072
0073
0074 Standard_EXPORT Graphic3d_CubeMapOrder Swapped (Graphic3d_CubeMapSide theFirstSide,
0075 Graphic3d_CubeMapSide theSecondSide) const;
0076
0077
0078 Standard_EXPORT unsigned char Get (Graphic3d_CubeMapSide theCubeMapSide) const;
0079
0080
0081 Standard_EXPORT unsigned char operator[] (Graphic3d_CubeMapSide theCubeMapSide) const;
0082
0083
0084 Standard_EXPORT Graphic3d_CubeMapOrder& Clear();
0085
0086
0087 Standard_EXPORT bool IsEmpty() const;
0088
0089
0090 Standard_EXPORT bool HasRepetitions() const;
0091
0092
0093 Standard_EXPORT bool HasOverflows() const;
0094
0095
0096
0097
0098 Standard_EXPORT bool IsValid() const;
0099
0100 public:
0101
0102
0103
0104 Standard_EXPORT static const Graphic3d_ValidatedCubeMapOrder& Default();
0105
0106 private:
0107
0108
0109 unsigned char get (unsigned char theCubeMapSide) const;
0110
0111
0112 void set (unsigned char theCubeMapSide, unsigned char theValue);
0113
0114
0115 void set (Graphic3d_CubeMapSide theCubeMapSide, unsigned char theValue);
0116
0117 private:
0118
0119 unsigned int myConvolution;
0120 bool myHasOverflows;
0121 };
0122
0123
0124
0125
0126
0127
0128 class Graphic3d_ValidatedCubeMapOrder
0129 {
0130
0131 public:
0132
0133 friend class Graphic3d_CubeMapOrder;
0134
0135
0136 const Graphic3d_CubeMapOrder* operator->() const
0137 {
0138 return &Order;
0139 }
0140
0141
0142 Graphic3d_ValidatedCubeMapOrder (const Graphic3d_ValidatedCubeMapOrder& theOther)
0143 : Order (theOther.Order) {}
0144
0145 public:
0146
0147 const Graphic3d_CubeMapOrder Order;
0148
0149 private:
0150
0151
0152 Graphic3d_ValidatedCubeMapOrder(const Graphic3d_CubeMapOrder theOrder)
0153 : Order(theOrder) {}
0154
0155
0156 Graphic3d_ValidatedCubeMapOrder& operator= (const Graphic3d_ValidatedCubeMapOrder&);
0157
0158 };
0159
0160 #endif