Пример #1
0
 public ColorizeArgs(ColorMap <Vec3> colorMap)
 {
     Keys   = ReadBuffer(colorMap.Keys().ToArray());
     Colors = ReadBuffer(colorMap.Values().Select(v => new Vec4(v, 1f)).ToArray());
     Count  = Value(colorMap.Count);
 }
Пример #2
0
 public static Signal <T, Vec4> Colorize <T> (this Signal <T, float> signal, ColorMap <Vec3> colorMap)
 {
     return(signal.Select(x => new Vec4(colorMap[x], 1f)));
 }
Пример #3
0
 public ColorizeArgs(ColorMap <Vec4> colorMap)
 {
     Keys   = ReadBuffer(colorMap.Keys().ToArray());
     Colors = ReadBuffer(colorMap.Values().ToArray());
     Count  = Value(colorMap.Count);
 }