File indexing completed on 2026-09-09 09:15:38
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 Standard_EXPORT Graphic3d_CubeMapOrder();
0034
0035
0036 Standard_EXPORT Graphic3d_CubeMapOrder(unsigned char thePosXLocation,
0037 unsigned char theNegXLocation,
0038 unsigned char thePosYLocation,
0039 unsigned char theNegYLocation,
0040 unsigned char thePosZLocation,
0041 unsigned char theNegZLocation);
0042
0043
0044 Standard_EXPORT Graphic3d_CubeMapOrder(const Graphic3d_ValidatedCubeMapOrder& theOrder);
0045
0046
0047 Standard_EXPORT Graphic3d_CubeMapOrder& Set(const Graphic3d_CubeMapOrder& theOrder);
0048
0049
0050
0051
0052 Standard_EXPORT Graphic3d_ValidatedCubeMapOrder Validated() const;
0053
0054 public:
0055
0056 Standard_EXPORT Graphic3d_CubeMapOrder& Set(Graphic3d_CubeMapSide theCubeMapSide,
0057 unsigned char theValue);
0058
0059
0060 Standard_EXPORT Graphic3d_CubeMapOrder& SetDefault();
0061
0062
0063 Standard_EXPORT Graphic3d_CubeMapOrder& Permute(const Graphic3d_ValidatedCubeMapOrder& anOrder);
0064
0065
0066 Standard_EXPORT Graphic3d_CubeMapOrder
0067 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 Standard_EXPORT static const Graphic3d_ValidatedCubeMapOrder& Default();
0104
0105 private:
0106
0107 unsigned char get(unsigned char theCubeMapSide) const;
0108
0109
0110
0111 void set(unsigned char theCubeMapSide, unsigned char theValue);
0112
0113
0114 void set(Graphic3d_CubeMapSide theCubeMapSide, unsigned char theValue);
0115
0116 private:
0117 unsigned int myConvolution;
0118 bool myHasOverflows;
0119 };
0120
0121
0122
0123
0124
0125
0126 class Graphic3d_ValidatedCubeMapOrder
0127 {
0128
0129 public:
0130 friend class Graphic3d_CubeMapOrder;
0131
0132
0133 const Graphic3d_CubeMapOrder* operator->() const { return &Order; }
0134
0135
0136 Graphic3d_ValidatedCubeMapOrder(const Graphic3d_ValidatedCubeMapOrder& theOther)
0137 : Order(theOther.Order)
0138 {
0139 }
0140
0141 public:
0142 const Graphic3d_CubeMapOrder Order;
0143
0144 private:
0145
0146
0147 Graphic3d_ValidatedCubeMapOrder(const Graphic3d_CubeMapOrder theOrder)
0148 : Order(theOrder)
0149 {
0150 }
0151
0152
0153 Graphic3d_ValidatedCubeMapOrder& operator=(const Graphic3d_ValidatedCubeMapOrder&);
0154 };
0155
0156 #endif