Open Inventor Release 2024.1.0
 
Loading...
Searching...
No Matches
SoMFColorRGBA.h
Go to the documentation of this file.
1/*=======================================================================
2 *** THE CONTENT OF THIS WORK IS PROPRIETARY TO FEI S.A.S, (FEI S.A.S.), ***
3 *** AND IS DISTRIBUTED UNDER A LICENSE AGREEMENT. ***
4 *** ***
5 *** REPRODUCTION, DISCLOSURE, OR USE, IN WHOLE OR IN PART, OTHER THAN AS ***
6 *** SPECIFIED IN THE LICENSE ARE NOT TO BE UNDERTAKEN EXCEPT WITH PRIOR ***
7 *** WRITTEN AUTHORIZATION OF FEI S.A.S. ***
8 *** ***
9 *** RESTRICTED RIGHTS LEGEND ***
10 *** USE, DUPLICATION, OR DISCLOSURE BY THE GOVERNMENT OF THE CONTENT OF THIS ***
11 *** WORK OR RELATED DOCUMENTATION IS SUBJECT TO RESTRICTIONS AS SET FORTH IN ***
12 *** SUBPARAGRAPH (C)(1) OF THE COMMERCIAL COMPUTER SOFTWARE RESTRICTED RIGHT ***
13 *** CLAUSE AT FAR 52.227-19 OR SUBPARAGRAPH (C)(1)(II) OF THE RIGHTS IN ***
14 *** TECHNICAL DATA AND COMPUTER SOFTWARE CLAUSE AT DFARS 52.227-7013. ***
15 *** ***
16 *** COPYRIGHT (C) 1996-2014 BY FEI S.A.S, ***
17 *** BORDEAUX, FRANCE ***
18 *** ALL RIGHTS RESERVED ***
19**=======================================================================*/
20/*=======================================================================
21** Author : VSG (MMM YYYY)
22**=======================================================================*/
23
24
25#ifndef _SO_MF_COLORRGBA_
26#define _SO_MF_COLORRGBA_
27
31
33//
34// SoMFColorRGBA subclass of SoMField.
35//
37
78class SoMFColorRGBA : public SoMField {
79 // Use standard field stuff
81
83
84 public:
85 //
86 // Additional convenience functions
87 //
88
104 void setValues(int start, int num, const float rgba[][4]);
105
113 void setHSVAValues(int start, int num, const float hsva[][4]);
114
123 void setValue(const SbVec4f &vec);
124
133 void setValue(float r, float g, float b, float a);
134
143 void setValue(const float rgba[4]);
144
153 void setHSVAValue(float h, float s, float v, float a);
154
163 void setHSVAValue(const float hsva[4]);
164
172 void set1Value(int index, const SbVec4f &vec);
173
181 void set1Value(int index, float r, float g, float b, float a);
182
190 void set1Value(int index, const float rgba[4]);
191
199 void set1HSVAValue(int index, float h, float s, float v, float a);
200
208 void set1HSVAValue(int index, const float hsva[4]);
209
210 private:
211 static void initClass();
212 static void exitClass();
213
214 private:
215
216};
217
218#endif /* _SO_MF_COLORRGBA_ */
219
void start()
#define SO_MFIELD_HEADER(className, valueType, valueRef)
Definition SoSubField.h:502
#define SO_MFIELD_SETVALUESPOINTER_HEADER(userType)
ColorRGBA vector class.
Definition SbColorRGBA.h:61
4D vector class.
Definition SbVec.h:2214
Multiple-value field containing any number of RGBA colors stored as four floats.
void setValue(const SbVec4f &vec)
Sets the field to contain one and only one value, the given color (expressed as RGBA floating point v...
void setHSVAValues(int start, int num, const float hsva[][4])
Sets num HSV (hue, saturation and value) plus Alphe color values from an array of arrays of 4 floats...
void setValues(int start, int num, const float rgba[][4])
Sets num RGBA values from an array of arrays of 4 floats.
void setValue(const float rgba[4])
Sets the field to contain one and only one value, the given color (expressed as an array of RGBA floa...
void set1Value(int index, const SbVec4f &vec)
Sets one of N RGBA colors from SbVec4f.
void setHSVAValue(float h, float s, float v, float a)
Sets the field to contain one and only one value, the given color (expressed as HSV plus Alpha floati...
void setValue(float r, float g, float b, float a)
Sets the field to contain one and only one value, the given color (expressed as RGBA floating point v...
void setHSVAValue(const float hsva[4])
Sets the field to contain one and only one value, the given color (expressed as an array of HSV plus ...
void set1Value(int index, const float rgba[4])
Sets one of N RGBA colors from an array of 4 floats.
void set1HSVAValue(int index, float h, float s, float v, float a)
Sets one of N HSV plus Alpha colors from 4 floats.
void set1Value(int index, float r, float g, float b, float a)
Sets one of N RGBA colors from 4 floats.
void set1HSVAValue(int index, const float hsva[4])
Sets one of N HSV plus Alpha colors from an array of 4 floats.
Base class for all multiple-valued fields.
Definition SoMField.h:134