Add some menu effects
This commit is contained in:
parent
b1c2041d84
commit
302bac10e6
1 changed files with 14 additions and 4 deletions
18
renderer.h
18
renderer.h
|
@ -1742,12 +1742,20 @@ void LCR_rendererDrawMenu(const char *tabName,const char **items,
|
||||||
{
|
{
|
||||||
int stripHeight = LCR_EFFECTIVE_RESOLUTION_Y / 4;
|
int stripHeight = LCR_EFFECTIVE_RESOLUTION_Y / 4;
|
||||||
int stripHeight2 = LCR_EFFECTIVE_RESOLUTION_Y / 10;
|
int stripHeight2 = LCR_EFFECTIVE_RESOLUTION_Y / 10;
|
||||||
|
|
||||||
int i = 0;
|
int i = 0;
|
||||||
|
uint16_t effect = LCR_renderer.frame >> 1;
|
||||||
|
|
||||||
while (i < stripHeight * LCR_EFFECTIVE_RESOLUTION_X)
|
while (i < stripHeight * LCR_EFFECTIVE_RESOLUTION_X)
|
||||||
{
|
{
|
||||||
LCR_drawPixel(i,0x8ddc);
|
LCR_drawPixel(i,0x8ddc
|
||||||
|
#if LCR_SETTING_POTATO_GRAPHICS
|
||||||
|
);
|
||||||
|
#else
|
||||||
|
^ (effect & 0x18e3));
|
||||||
|
|
||||||
|
effect += 7;
|
||||||
|
#endif
|
||||||
|
|
||||||
++i;
|
++i;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1766,8 +1774,8 @@ void LCR_rendererDrawMenu(const char *tabName,const char **items,
|
||||||
for (int x = 0; x < LCR_EFFECTIVE_RESOLUTION_X; ++x)
|
for (int x = 0; x < LCR_EFFECTIVE_RESOLUTION_X; ++x)
|
||||||
{
|
{
|
||||||
LCR_drawPixel(i,(x > LCR_EFFECTIVE_RESOLUTION_X / 4 - limit &&
|
LCR_drawPixel(i,(x > LCR_EFFECTIVE_RESOLUTION_X / 4 - limit &&
|
||||||
x < LCR_EFFECTIVE_RESOLUTION_X - LCR_EFFECTIVE_RESOLUTION_X / 4 + limit)
|
(x < LCR_EFFECTIVE_RESOLUTION_X - LCR_EFFECTIVE_RESOLUTION_X / 4 + limit)
|
||||||
? 0x73ae : 0x31a6);
|
? 0x73ae : 0x31a6) + ((x + y) % 8));
|
||||||
i++;
|
i++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1806,6 +1814,8 @@ void LCR_rendererDrawMenu(const char *tabName,const char **items,
|
||||||
LCR_IMAGE_SIZE * (stripHeight / LCR_IMAGE_SIZE)) / 2,0,
|
LCR_IMAGE_SIZE * (stripHeight / LCR_IMAGE_SIZE)) / 2,0,
|
||||||
stripHeight / LCR_IMAGE_SIZE,0xffff);
|
stripHeight / LCR_IMAGE_SIZE,0xffff);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
LCR_renderer.frame++;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: what is this function even doing?
|
// TODO: what is this function even doing?
|
||||||
|
|
Loading…
Reference in a new issue