Class CompositePool

java.lang.Object
com.arbergashi.charts.internal.CompositePool

public final class CompositePool extends Object
Lightweight cache for AlphaComposite instances to avoid allocations in tight render loops. Uses a ConcurrentHashMap to allow thread-safe access from worker threads.
Since:
2026-01-01
Version:
1.0.0
Author:
Arber Gashi
  • Method Details

    • get

      public static Composite get(float alpha)
      Returns an AlphaComposite corresponding to the given alpha in the range [0,1]. For stability and cache hits we quantize alpha to 0..255 integer steps.