Difference between revisions of "vec4"
m (Added a missing quote) |
(Added description and a link to Shader) |
||
Line 15: | Line 15: | ||
== See Also == | == See Also == | ||
* [[vec2]] | * [[vec2]] | ||
+ | * [[Shader]] | ||
[[Category:GLSL]] | [[Category:GLSL]] | ||
+ | {{#set:Description=Vector made of 4 floats.}} | ||
== Other Languages == | == Other Languages == | ||
{{i18n|vec4}} | {{i18n|vec4}} |
Latest revision as of 03:50, 29 June 2022
A vector with 4 floating-point number components. These can be accessed with .r/g/b/a
, .x/y/z/w
, or [0/1/2/3]
.
vec4 example = vec4(0.333, 0.666, 0.999, 1.0);
float r = example.r;
float g = example.g;
float b = example.b;
float a = example.a;
Read more:
See Also
Other Languages
Dansk –
Deutsch –
English –
Español –
Français –
Indonesia –
Italiano –
Lietuviškai –
Magyar –
Nederlands –
Polski –
Português –
Română –
Slovenský –
Suomi –
Svenska –
Türkçe –
Česky –
Ελληνικά –
Български –
Русский –
Српски –
Українська –
עברית –
ไทย –
日本語 –
正體中文 –
简体中文 –
Tiếng Việt –
한국어
More info