docs: @SuppressWarnings("WeakerAccess")
      public Color segmentColor(final int segment, final boolean front) {
          final ByteBuffer bytes = getData();
          if (isColor) {
              final int base = segment * 6;
              final int backHeight = segmentHeight(segment, false);
              if (backHeight == 0) {
                  return Color.BLACK;
              }
              final int maxLevel = front? 255 : 191;
              final int red = Util.unsign(bytes.get(base + 3)) * maxLevel / backHeight;
              final int green = Util.unsign(bytes.get(base + 4)) * maxLevel / backHeight;
              final int blue = Util.unsign(bytes.get(base + 5)) * maxLevel / backHeight;
              return new Color(red, green, blue);
          } else {
              final int intensity = getData().get(segment * 2 + 1) & 0x07;
              return (intensity >= 5) ? INTENSE_COLOR : NORMAL_COLOR;
          }
      }