MCPcopy Create free account
hub / github.com/KebsCS/KBotExt / ImFontAtlasBuildMultiplyRectAlpha8

Function ImFontAtlasBuildMultiplyRectAlpha8

KBotExt/imgui/imgui_draw.cpp:2344–2351  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2342}
2343
2344void ImFontAtlasBuildMultiplyRectAlpha8(const unsigned char table[256], unsigned char* pixels, int x, int y, int w, int h, int stride)
2345{
2346 IM_ASSERT_PARANOID(w <= stride);
2347 unsigned char* data = pixels + x + y * stride;
2348 for (int j = h; j > 0; j--, data += stride - w)
2349 for (int i = w; i > 0; i--, data++)
2350 *data = table[*data];
2351}
2352
2353#ifdef IMGUI_ENABLE_STB_TRUETYPE
2354// Temporary data for one source font (multiple source fonts can be merged into one destination ImFont)

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected