MCPcopy Create free account
hub / github.com/MyGUI/mygui / edgeBetweenTexels

Function edgeBetweenTexels

MyGUIEngine/src/msdfgen/core/MSDFErrorCorrection.cpp:171–177  ·  view source on GitHub ↗

Returns a bit mask of which channels contribute to an edge between the two texels a, b.

Source from the content-addressed store, hash-verified

169
170/// Returns a bit mask of which channels contribute to an edge between the two texels a, b.
171static int edgeBetweenTexels(const float *a, const float *b) {
172 return (
173 RED*edgeBetweenTexelsChannel(a, b, 0)+
174 GREEN*edgeBetweenTexelsChannel(a, b, 1)+
175 BLUE*edgeBetweenTexelsChannel(a, b, 2)
176 );
177}
178
179/// Marks texel as protected if one of its non-median channels is present in the channel mask.
180static void protectExtremeChannels(byte *stencil, const float *msd, float m, int mask) {

Callers 1

protectEdgesMethod · 0.85

Calls 1

edgeBetweenTexelsChannelFunction · 0.85

Tested by

no test coverage detected