Warning, file /include/opencascade/VrmlData_Color.hxx was not indexed
or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016 #ifndef VrmlData_Color_HeaderFile
0017 #define VrmlData_Color_HeaderFile
0018
0019 #include <VrmlData_ArrayVec3d.hxx>
0020 #include <Quantity_Color.hxx>
0021 #include <gp_XYZ.hxx>
0022
0023
0024
0025
0026 class VrmlData_Color : public VrmlData_ArrayVec3d
0027 {
0028 public:
0029
0030
0031
0032
0033
0034 inline VrmlData_Color() = default;
0035
0036
0037
0038
0039 inline VrmlData_Color(const VrmlData_Scene& theScene,
0040 const char* theName,
0041 const size_t nColors = 0,
0042 const gp_XYZ* arrColors = nullptr)
0043 : VrmlData_ArrayVec3d(theScene, theName, nColors, arrColors)
0044 {
0045 }
0046
0047
0048
0049
0050
0051
0052
0053
0054 inline const Quantity_Color Color(const int i) const
0055 {
0056 return Quantity_Color(Value(i).X(), Value(i).Y(), Value(i).Z(), Quantity_TOC_sRGB);
0057 }
0058
0059
0060
0061
0062 inline void SetColors(const size_t nColors, const gp_XYZ* arrColors)
0063 {
0064 myLength = nColors;
0065 myArray = arrColors;
0066 }
0067
0068
0069
0070
0071
0072
0073 Standard_EXPORT occ::handle<VrmlData_Node> Clone(
0074 const occ::handle<VrmlData_Node>& theOther) const override;
0075
0076
0077
0078
0079 Standard_EXPORT VrmlData_ErrorStatus Read(VrmlData_InBuffer& theBuffer) override;
0080
0081
0082
0083
0084 Standard_EXPORT VrmlData_ErrorStatus Write(const char* thePrefix) const override;
0085
0086 public:
0087
0088 DEFINE_STANDARD_RTTI_INLINE(VrmlData_Color, VrmlData_ArrayVec3d)
0089 };
0090
0091
0092 #endif