MCPcopy Create free account
hub / github.com/bfbbdecomp/bfbb / iVolFromX

Function iVolFromX

src/SB/Core/gc/iSnd.cpp:672–687  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

670 if (gSnd.voice[i + 6].sndID == handle)
671 {
672 return (voices[i].flags & 0x4 && (voices[i].flags & 0x8) == 0);
673 }
674 }
675 return false;
676}
677
678U32 iVolFromX(F32 param1)
679{
680 float f = MAX(param1, 1e-20f);
681
682 S32 i = 43.43f * xlog(f);
683 S32 comp = MIN(i, 0);
684
685 if (comp < -0x388)
686 {
687 return -0x388;
688 }
689 else
690 {

Callers

nothing calls this directly

Calls 1

xlogFunction · 0.85

Tested by

no test coverage detected