Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save Lucretia/ae5e910f4df229f6b9b207d3f32da352 to your computer and use it in GitHub Desktop.
Save Lucretia/ae5e910f4df229f6b9b207d3f32da352 to your computer and use it in GitHub Desktop.
// From nuklear_sdl_renderer.h
NK_API void
nk_sdl_font_stash_begin(struct nk_font_atlas **atlas)
{
nk_font_atlas_init_default(&sdl.atlas);
nk_font_atlas_begin(&sdl.atlas);
*atlas = &sdl.atlas;
}
-- From the main Nuklear bindings, nk_font_atlas is a record type.
type font_atlas_access is access all nk_font_atlas;
-- The binding to the above.
procedure sdl_font_stash_begin (atlas : access font_atlas_access) -- ./Nuklear/demo/sdl_renderer/nuklear_sdl_renderer.h:16
with Import => True,
Convention => C,
External_Name => "nk_sdl_font_stash_begin";
-- From the demo.adb
Atlas : aliased Nk.font_atlas_access := null;
...
NkR.sdl_font_stash_begin (Atlas'Access);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment