#include <gl_util.H>
| Public Member Functions | |
| operator GLfloat * () | |
| Define implicit cast from float4 to GLfloat*:. | |
| Constructors | |
| float4 (CCOLOR &c, double alpha=1.0) | |
| float4 (CWpt &p) | |
| float4 (CWvec &v) | |
| Private Attributes | |
| GLfloat | _data [4] | 
Examples:
// Set current color and alpha: COLOR c = Color::orange4; double a = 0.7; // alpha glColor4fv(float4(c, a));
// Pass a position or direction to define light coordinates, // where the homogeneous coordinate h is 1 or 0, respectively: Wpt p; Wvec v; if (positional_light) glLightfv(GL_LIGHT0, GL_POSITION, float4(p)); // h == 1 else glLightfv(GL_LIGHT0, GL_POSITION, float4(v)); // h == 0
Definition at line 40 of file gl_util.H.
| 
 | ||||||||||||
| 
 Definition at line 44 of file gl_util.H. References _data. | 
| 
 | 
| 
 Definition at line 50 of file gl_util.H. References _data. | 
| 
 | 
| 
 Definition at line 56 of file gl_util.H. References _data. | 
| 
 | 
| Define implicit cast from float4 to GLfloat*:. 
 Definition at line 65 of file gl_util.H. References _data. | 
| 
 | 
| 
 Definition at line 68 of file gl_util.H. Referenced by float4(), and operator GLfloat *(). | 
 1.4.4
 1.4.4