ReferenceMaterial nodesConstants
Colour with Alpha
A colour and how solid it is, as four numbers.
●Colour with Alpha
Colour
Alpha1R
G
B
Alpha
Inputs
| Pin | Type | Starts at | Notes |
|---|---|---|---|
Colourcolour | vec3 | "#7ce695" | – |
Alphaalpha | float | 1 | – |
Outputs
| Pin | Type |
|---|---|
out | vec4 |
Rr | float |
Gg | float |
Bb | float |
Alphaalpha | float |
The code it becomes
What Studio writes for the graph below: a few lines of the material's shader, worked out for every pixel.
void mainImage(out vec4 fragColor, in vec2 fragCoord){ vec4 n2_out = vec4(vec3(0.48627, 0.90196, 0.58431), 1.0); float n2_r = (vec3(0.48627, 0.90196, 0.58431)).r; float n2_g = (vec3(0.48627, 0.90196, 0.58431)).g; float n2_b = (vec3(0.48627, 0.90196, 0.58431)).b; float n2_alpha = 1.0; fragColor = vec4((n2_out).xyz * clamp(n2_alpha, 0.0, 1.0), 1.0);}In a graph
●Colour with Alpha
Colour
Alpha1R
G
B
Alpha
◎Material OutputEnds here
Colour
Alpha1
Texture coordinates into the node, and the node into the material, as Studio draws them.
Related
Notes from the community
Written by creators and checked by the docs' editors. Not part of Motion's official reference.