mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2024-12-25 03:08:54 +01:00
internal/ui: fix comments
This commit is contained in:
parent
7c55065490
commit
3259ef3daf
@ -57,8 +57,8 @@ func Fragment(position vec4, texCoord vec2, color vec4) vec4 {
|
|||||||
|
|
||||||
// rate indicates how much the 4 colors are mixed. rate is in between [0, 1].
|
// rate indicates how much the 4 colors are mixed. rate is in between [0, 1].
|
||||||
//
|
//
|
||||||
// 0 <= p < 1/Scale: The rate is in between [0, 1)
|
// 0 <= p <= 1/Scale: The rate is in between [0, 1]
|
||||||
// 1/Scale <= p: Don't care. Adjacent colors (e.g. c0 vs c1 in an X direction) should be the same.
|
// 1/Scale < p: Don't care. Adjacent colors (e.g. c0 vs c1 in an X direction) should be the same.
|
||||||
rate := clamp(p*Scale, 0, 1)
|
rate := clamp(p*Scale, 0, 1)
|
||||||
|
|
||||||
return mix(mix(c0, c1, rate.x), mix(c2, c3, rate.x), rate.y)
|
return mix(mix(c0, c1, rate.x), mix(c2, c3, rate.x), rate.y)
|
||||||
|
Loading…
Reference in New Issue
Block a user