Lines Matching defs:scale

98      * @param scale
99 * scale value to use. if 1, use endValue, if 0, use startValue.
106 public static float interpolateLinear(float scale, float startValue, float endValue) {
110 if (scale <= 0f) {
113 if (scale >= 1f) {
116 return ((1f - scale) * startValue) + (scale * endValue);
123 * @param scale
124 * scale value to use. if 1, use endValue, if 0, use startValue.
132 public static Vector3f interpolateLinear(float scale, Vector3f startValue, Vector3f endValue, Vector3f store) {
136 store.x = interpolateLinear(scale, startValue.x, endValue.x);
137 store.y = interpolateLinear(scale, startValue.y, endValue.y);
138 store.z = interpolateLinear(scale, startValue.z, endValue.z);
146 * @param scale
147 * scale value to use. if 1, use endValue, if 0, use startValue.
154 public static Vector3f interpolateLinear(float scale, Vector3f startValue, Vector3f endValue) {
155 return interpolateLinear(scale, startValue, endValue, null);
159 * Linear extrapolation from startValue to endValue by the given scale.
160 * if scale is between 0 and 1 this method returns the same result as interpolateLinear
161 * if the scale is over 1 the value is linearly extrapolated.
162 * Note that the end value is the value for a scale of 1.
163 * @param scale the scale for extrapolation
164 * @param startValue the starting value (scale = 0)
165 * @param endValue the end value (scale = 1)
168 public static float extrapolateLinear(float scale, float startValue, float endValue) {
169 // if (scale <= 0f) {
172 return ((1f - scale) * startValue) + (scale * endValue);
176 * Linear extrapolation from startValue to endValue by the given scale.
177 * if scale is between 0 and 1 this method returns the same result as interpolateLinear
178 * if the scale is over 1 the value is linearly extrapolated.
179 * Note that the end value is the value for a scale of 1.
180 * @param scale the scale for extrapolation
181 * @param startValue the starting value (scale = 0)
182 * @param endValue the end value (scale = 1)
186 public static Vector3f extrapolateLinear(float scale, Vector3f startValue, Vector3f endValue, Vector3f store) {
190 // if (scale <= 1f) {
191 // return interpolateLinear(scale, startValue, endValue, store);
193 store.x = extrapolateLinear(scale, startValue.x, endValue.x);
194 store.y = extrapolateLinear(scale, startValue.y, endValue.y);
195 store.z = extrapolateLinear(scale, startValue.z, endValue.z);
200 * Linear extrapolation from startValue to endValue by the given scale.
201 * if scale is between 0 and 1 this method returns the same result as interpolateLinear
202 * if the scale is over 1 the value is linearly extrapolated.
203 * Note that the end value is the value for a scale of 1.
204 * @param scale the scale for extrapolation
205 * @param startValue the starting value (scale = 0)
206 * @param endValue the end value (scale = 1)
209 public static Vector3f extrapolateLinear(float scale, Vector3f startValue, Vector3f endValue) {
210 return extrapolateLinear(scale, startValue, endValue, null);