add mapf and unmixf
parent
48a6bd5911
commit
926a48bc50
|
@ -1,4 +1,7 @@
|
|||
@echo off
|
||||
call razzle amd64
|
||||
if exist .env.bat (
|
||||
call .env.bat
|
||||
)
|
||||
code .
|
||||
exit
|
|
@ -99,6 +99,8 @@ typedef float mat44[16];
|
|||
float signf (float a) ;
|
||||
float clampf (float v,float a,float b);
|
||||
float mixf (float a,float b,float t);
|
||||
float unmixf (float a,float b,float t);
|
||||
float mapf (float x,float a,float b,float c,float d);
|
||||
float slerpf (float a,float b,float t);
|
||||
float fractf (float a);
|
||||
vec2 ptr2 (const float *a );
|
||||
|
|
|
@ -14956,6 +14956,8 @@ API float pmodf (float a, float b);
|
|||
API float signf (float a) ;
|
||||
API float clampf (float v,float a,float b);
|
||||
API float mixf (float a,float b,float t);
|
||||
API float unmixf (float a,float b,float t);
|
||||
API float mapf (float x,float a,float b,float c,float d);
|
||||
API float slerpf (float a,float b,float t);
|
||||
API float fractf (float a);
|
||||
|
||||
|
@ -377005,6 +377007,8 @@ float pmodf (float a, float b) { return (a < 0.0f ? 1.0f : 0.0f) + (float)f
|
|||
float signf (float a) { return (a < 0) ? -1.f : 1.f; }
|
||||
float clampf(float v,float a,float b){return maxf(minf(b,v),a); }
|
||||
float mixf(float a,float b,float t) { return a*(1-t)+b*t; }
|
||||
float unmixf(float a,float b,float t) { return (t - a) / (b - a); }
|
||||
float mapf(float x,float a,float b,float c,float d) { return (x - a) / (b - a) * (d - c) + c; }
|
||||
float slerpf(float a,float b,float t) {
|
||||
a = fmod(a, 360); if (a < 0) a += 360;
|
||||
b = fmod(b, 360); if (b < 0) b += 360;
|
||||
|
|
|
@ -90,6 +90,8 @@ float pmodf (float a, float b) { return (a < 0.0f ? 1.0f : 0.0f) + (float)f
|
|||
float signf (float a) { return (a < 0) ? -1.f : 1.f; }
|
||||
float clampf(float v,float a,float b){return maxf(minf(b,v),a); }
|
||||
float mixf(float a,float b,float t) { return a*(1-t)+b*t; }
|
||||
float unmixf(float a,float b,float t) { return (t - a) / (b - a); }
|
||||
float mapf(float x,float a,float b,float c,float d) { return (x - a) / (b - a) * (d - c) + c; }
|
||||
float slerpf(float a,float b,float t) {
|
||||
a = fmod(a, 360); if (a < 0) a += 360;
|
||||
b = fmod(b, 360); if (b < 0) b += 360;
|
||||
|
|
|
@ -64,6 +64,8 @@ API float pmodf (float a, float b);
|
|||
API float signf (float a) ;
|
||||
API float clampf (float v,float a,float b);
|
||||
API float mixf (float a,float b,float t);
|
||||
API float unmixf (float a,float b,float t);
|
||||
API float mapf (float x,float a,float b,float c,float d);
|
||||
API float slerpf (float a,float b,float t);
|
||||
API float fractf (float a);
|
||||
|
||||
|
|
|
@ -12188,6 +12188,8 @@ float pmodf (float a, float b) { return (a < 0.0f ? 1.0f : 0.0f) + (float)f
|
|||
float signf (float a) { return (a < 0) ? -1.f : 1.f; }
|
||||
float clampf(float v,float a,float b){return maxf(minf(b,v),a); }
|
||||
float mixf(float a,float b,float t) { return a*(1-t)+b*t; }
|
||||
float unmixf(float a,float b,float t) { return (t - a) / (b - a); }
|
||||
float mapf(float x,float a,float b,float c,float d) { return (x - a) / (b - a) * (d - c) + c; }
|
||||
float slerpf(float a,float b,float t) {
|
||||
a = fmod(a, 360); if (a < 0) a += 360;
|
||||
b = fmod(b, 360); if (b < 0) b += 360;
|
||||
|
|
|
@ -1023,6 +1023,8 @@ API float pmodf (float a, float b);
|
|||
API float signf (float a) ;
|
||||
API float clampf (float v,float a,float b);
|
||||
API float mixf (float a,float b,float t);
|
||||
API float unmixf (float a,float b,float t);
|
||||
API float mapf (float x,float a,float b,float c,float d);
|
||||
API float slerpf (float a,float b,float t);
|
||||
API float fractf (float a);
|
||||
|
||||
|
|
Loading…
Reference in New Issue