Fixes for nov 7 breaking changes to sokol_gfx

This commit is contained in:
2024-11-26 10:50:26 -05:00
parent 109d2b0ff1
commit 36678c1127
11 changed files with 145 additions and 146 deletions

View File

@ -23,7 +23,7 @@ FontID :: struct {
FontDef :: struct {
path_file : string,
default_size : i32,
size_table : [Font_Largest_Px_Size / Font_Size_Interval] ve.FontID,
size_table : [Font_Largest_Px_Size / Font_Size_Interval] ve.Font_ID,
}
FontProviderContext :: struct
@ -114,7 +114,7 @@ font_load :: proc(path_file : string,
Font_Use_Default_Size :: f32(0.0)
font_provider_resolve_draw_id :: proc( id : FontID, size := Font_Use_Default_Size ) -> (ve_id :ve.FontID, resolved_size : i32)
font_provider_resolve_draw_id :: proc( id : FontID, size := Font_Use_Default_Size ) -> (ve_id :ve.Font_ID, resolved_size : i32)
{
provider_data := get_state().font_provider_ctx; using provider_data

View File

@ -87,12 +87,12 @@ font_provider_setup_sokol_gfx_objects :: proc( ctx : ^VE_RenderData, ve_ctx : ve
vs_layout : VertexLayoutState
{
using vs_layout
attrs[ATTR_ve_render_glyph_vs_v_position] = VertexAttributeState {
attrs[ATTR_ve_render_glyph_v_position] = VertexAttributeState {
format = VertexFormat.FLOAT2,
offset = 0,
buffer_index = 0,
}
attrs[ATTR_ve_render_glyph_vs_v_texture] = VertexAttributeState {
attrs[ATTR_ve_render_glyph_v_texture] = VertexAttributeState {
format = VertexFormat.FLOAT2,
offset = size_of(Vec2),
buffer_index = 0,
@ -226,12 +226,12 @@ font_provider_setup_sokol_gfx_objects :: proc( ctx : ^VE_RenderData, ve_ctx : ve
vs_layout : VertexLayoutState
{
using vs_layout
attrs[ATTR_ve_blit_atlas_vs_v_position] = VertexAttributeState {
attrs[ATTR_ve_blit_atlas_v_position] = VertexAttributeState {
format = VertexFormat.FLOAT2,
offset = 0,
buffer_index = 0,
}
attrs[ATTR_ve_blit_atlas_vs_v_texture] = VertexAttributeState {
attrs[ATTR_ve_blit_atlas_v_texture] = VertexAttributeState {
format = VertexFormat.FLOAT2,
offset = size_of(Vec2),
buffer_index = 0,
@ -365,12 +365,12 @@ font_provider_setup_sokol_gfx_objects :: proc( ctx : ^VE_RenderData, ve_ctx : ve
vs_layout : VertexLayoutState
{
using vs_layout
attrs[ATTR_ve_draw_text_vs_v_position] = VertexAttributeState {
attrs[ATTR_ve_draw_text_v_position] = VertexAttributeState {
format = VertexFormat.FLOAT2,
offset = 0,
buffer_index = 0,
}
attrs[ATTR_ve_draw_text_vs_v_texture] = VertexAttributeState {
attrs[ATTR_ve_draw_text_v_texture] = VertexAttributeState {
format = VertexFormat.FLOAT2,
offset = size_of(Vec2),
buffer_index = 0,