MCPcopy Create free account
hub / github.com/DISTRHO/DPF / getFixedRange2

Function getFixedRange2

dgl/src/Color.cpp:53–61  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

51}
52
53static uchar getFixedRange2(const float& value)
54{
55 const float value2(getFixedRange(value)*255.0f);
56 if (value2 <= 0.0f)
57 return 0;
58 if (value2 >= 255.0f)
59 return 255;
60 return static_cast<uchar>(value2 + 0.5f);
61}
62
63// -----------------------------------------------------------------------
64

Callers 2

isEqualMethod · 0.85
isNotEqualMethod · 0.85

Calls 1

getFixedRangeFunction · 0.85

Tested by

no test coverage detected