Interface LightFlicker.FlickerSmoothing

Enclosing class:
LightFlicker
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public static interface LightFlicker.FlickerSmoothing
Defines the API for the function called to smooth the transition between the current and next light intensity values.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    Returns the average of the current value and the next value.
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    apply(int current, int next, float deltaTime)
    Function called to smooth the transition between the current and next light intensity values
  • Field Details

  • Method Details

    • apply

      int apply(int current, int next, float deltaTime)
      Function called to smooth the transition between the current and next light intensity values
      Parameters:
      current - the current intensity value between 0 and 255
      next - the next intensity value between 0 and 255
      deltaTime - the delta time for the frame
      Returns:
      the next, smoothed intensity value