Lines Matching refs:buffer
150 uint8_t * buffer = NULL; in ttf_get_glyph_bitmap_cb() local
151 lv_lru_get(dsc->bitmap_cache, &cache_key, sizeof(cache_key), (void **)&buffer); in ttf_get_glyph_bitmap_cb()
152 if(buffer) { in ttf_get_glyph_bitmap_cb()
153 return buffer; in ttf_get_glyph_bitmap_cb()
158 buffer = lv_mem_alloc(szb); in ttf_get_glyph_bitmap_cb()
159 if(!buffer) { in ttf_get_glyph_bitmap_cb()
163 lv_memset(buffer, 0, szb); in ttf_get_glyph_bitmap_cb()
164 if(LV_LRU_OK != lv_lru_set(dsc->bitmap_cache, &cache_key, sizeof(cache_key), buffer, szb)) { in ttf_get_glyph_bitmap_cb()
166 lv_mem_free(buffer); in ttf_get_glyph_bitmap_cb()
170 stbtt_MakeGlyphBitmap(info, buffer, w, h, stride, dsc->scale, dsc->scale, g1); in ttf_get_glyph_bitmap_cb()
171 return buffer; in ttf_get_glyph_bitmap_cb()