- vg_acquire_thread_sync();
- {
- /* upload mesh */
- mesh_upload( &font->mesh,
- font->mdl.verts.data, font->mdl.verts.count,
- font->mdl.indices.data, font->mdl.indices.count );
-
- /* upload first texture */
- font->texture = vg_tex2d_new();
-
- vg_tex2d_set_error();
- vg_tex2d_qoi( data, tex0->file.pack_size,
- mdl_pstr( &font->mdl, tex0->file.pstr_path ));
- vg_tex2d_nearest();
- vg_tex2d_repeat();
- }
- vg_release_thread_sync();
+ mdl_async_load_glmesh( &font->mdl, &font->mesh );
+ vg_tex2d_load_qoi_async( data, tex0->file.pack_size,
+ VG_TEX2D_NEAREST|VG_TEX2D_REPEAT|VG_TEX2D_NOMIP,
+ &font->texture );