MCPcopy Create free account
hub / github.com/FastLED/FastLED / clampU8

Function clampU8

src/platforms/esp/32/codec/h264_hw_decoder.hpp:33–37  ·  view source on GitHub ↗

Clamp integer to [0, 255] range.

Source from the content-addressed store, hash-verified

31
32// Clamp integer to [0, 255] range.
33inline fl::u8 clampU8(int v) FL_NOEXCEPT {
34 if (v < 0) return 0;
35 if (v > 255) return 255;
36 return static_cast<fl::u8>(v);
37}
38
39// Split Annex B bytestream into individual NAL units.
40// Finds 0x00 0x00 0x00 0x01 start codes and returns data between them.

Callers 1

decodeMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected