Java Float Number Clamp clampWithMod(float parFloat, float parMax)

Here you can find the source of clampWithMod(float parFloat, float parMax)

Description

clamp With Mod

License

Apache License

Declaration

public static float clampWithMod(float parFloat, float parMax) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static float clampWithMod(float parFloat, float parMax) {
        return (parFloat + parMax) % parMax;
    }//from  www.j  a  v a 2s.co m
}

Related

  1. clampPercentage(float value)
  2. clampRoundByte(float in)
  3. clampToMinusOneToOne(float value)
  4. clampToPositiveNonZero(float value)
  5. clampTrigo(float value, float min, float max)
  6. clampYaw(float yaw)
  7. clampYaw(float yaw)
  8. clampZero_float(float value, float max)