forked from len0rd/rockbox
puzzles: improve zoom rendering
This adds colored font rendering, as well as a workaround for font loading while zoomed. Additionally, the frontend has been modified to match the new upstream API. Change-Id: I8c3fe57e6854f176485bf792cf4778cd54a21674
This commit is contained in:
parent
b2c470719a
commit
47ebf623cb
2 changed files with 86 additions and 55 deletions
|
@ -14,12 +14,9 @@
|
|||
int allocs = 0;
|
||||
int frees = 0;
|
||||
|
||||
bool audiobuf_available =
|
||||
#ifndef COMBINED
|
||||
true;
|
||||
#else
|
||||
false;
|
||||
#endif
|
||||
/* We don't load as an overlay anymore, so the audiobuf should always
|
||||
* be available. */
|
||||
bool audiobuf_available = true;
|
||||
|
||||
static bool grab_audiobuf(void)
|
||||
{
|
||||
|
@ -29,10 +26,23 @@ static bool grab_audiobuf(void)
|
|||
if(rb->audio_status())
|
||||
rb->audio_stop();
|
||||
|
||||
size_t sz, junk;
|
||||
size_t sz;
|
||||
|
||||
void *audiobuf = rb->plugin_get_audio_buffer(&sz);
|
||||
extern char *giant_buffer;
|
||||
|
||||
#if 0
|
||||
/* Try aligning if tlsf crashes in add_new_area(). This is
|
||||
* disabled now since things seem to work without it. */
|
||||
void *old = audiobuf;
|
||||
|
||||
/* I'm sorry. */
|
||||
audiobuf = (void*)((int) audiobuf & ~0xff);
|
||||
audiobuf += 0x100;
|
||||
|
||||
sz -= audiobuf - old;
|
||||
#endif
|
||||
|
||||
add_new_area(audiobuf, sz, giant_buffer);
|
||||
audiobuf_available = false;
|
||||
return true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue