MCPcopy Create free account
hub / github.com/Moddable-OpenSource/moddable / PiuTextureBind

Function PiuTextureBind

modules/piu/MC/piuTexture.c:74–89  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

72}
73
74void PiuTextureBind(PiuTexture* self, PiuApplication* application, PiuView* view)
75{
76 if ((*self)->usage == 0) {
77 piuTextureSize += PiuTextureComputeSize(self);
78 #ifdef mxInstrument
79 modInstrumentationMax(PiuCommandListUsed, piuTextureSize);
80 #endif
81 if ((*self)->flags & piuTextureAlpha) {
82 PocoBitmapAdd((*view)->poco, &((*self)->mask), PiuViewReceiver, view);
83 }
84 if ((*self)->flags & piuTextureColor) {
85 PocoBitmapAdd((*view)->poco, &((*self)->bits), PiuViewReceiver, view);
86 }
87 }
88 (*self)->usage++;
89}
90
91void PiuTextureUnbind(PiuTexture* self, PiuApplication* application, PiuView* view)
92{

Callers 2

PiuSkinBindFunction · 0.85
PiuFontBindFunction · 0.85

Calls 1

PiuTextureComputeSizeFunction · 0.85

Tested by

no test coverage detected