MCPcopy Create free account
hub / github.com/kiibohd/controller / Pixel_pixelTweenStandard

Function Pixel_pixelTweenStandard

Macro/PixelMap/pixel.c:1742–1771  ·  view source on GitHub ↗

Standard Pixel Pixel Function (standard lookup, no additonal processing)

Source from the content-addressed store, hash-verified

1740
1741// Standard Pixel Pixel Function (standard lookup, no additonal processing)
1742void Pixel_pixelTweenStandard( const uint8_t *frame, AnimationStackElement *stack_elem )
1743{
1744 // Iterate over all of the Pixel Modifier elements of the Animation Frame
1745 uint16_t pos = 0;
1746 PixelModElement *mod = (PixelModElement*)&frame[pos];
1747 while ( mod->type != PixelAddressType_End )
1748 {
1749 // Lookup type of pixel, choose fill algorith and query all sub-pixels
1750 uint16_t next = 0;
1751 uint16_t valid = 0;
1752 PixelElement *prev_pixel_elem = 0;
1753 PixelElement *elem = 0;
1754 do {
1755 // Last element
1756 prev_pixel_elem = elem;
1757
1758 // Lookup pixel, and check if there are any more pixels left
1759 next = Pixel_fillPixelLookup( mod, &elem, next, stack_elem, &valid );
1760
1761 // Apply operation to pixel
1762 Pixel_pixelEvaluation( mod, elem );
1763 } while ( next );
1764
1765 // Determine next position
1766 pos += Pixel_pixelTweenNextPos( elem, prev_pixel_elem );
1767
1768 // Lookup next mod element
1769 mod = (PixelModElement*)&frame[pos];
1770 }
1771}
1772
1773// Basic interpolation Pixel Pixel Function
1774// TODO - Only works with Colummn and Row fill currently

Callers 1

Pixel_frameTweenStandardFunction · 0.85

Calls 3

Pixel_fillPixelLookupFunction · 0.85
Pixel_pixelEvaluationFunction · 0.85
Pixel_pixelTweenNextPosFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…