Cleanup: rename GPU function to set buffer length
This commit is contained in:
parent
ff10ba8c26
commit
dd3f518626
Notes:
blender-bot
2023-02-14 04:26:23 +01:00
Referenced by issue #61337, Shift +F1 append not working Referenced by issue #61035, Draw manager crash opening file with curves Referenced by issue #61002, Changing Mode Referenced by issue #60848, Unit Broken between scene loaded from 2.79 to 2.8 Referenced by issue #60858, Shape Keys stoped working Referenced by issue #60830, Keyframes don't allow changing Referenced by issue #60733, Subdivision Surface Performance Degrades Markedly With Non-Quad Meshes Referenced by issue #60724, Subdivision Surface modifier doesn't works proper in 2.80 Referenced by issue #60731, CYCLES BAKE STILL CRASHING. RECEIVED EMAIL SAYING IT WAS RESOLVED AND IT IS CLEARLY NOT RESOLVED. Referenced by issue #60716, Image Sequence Feature that in Image Texture Node Not Working Referenced by issue #59514, Switching Between Bones and Model
|
@ -191,7 +191,7 @@ void blf_batch_draw(void)
|
|||
UI_widgetbase_draw_cache_flush();
|
||||
|
||||
GPU_texture_bind(g_batch.tex_bind_state, 0);
|
||||
GPU_vertbuf_vertex_count_set(g_batch.verts, g_batch.glyph_len);
|
||||
GPU_vertbuf_data_len_set(g_batch.verts, g_batch.glyph_len);
|
||||
GPU_vertbuf_use(g_batch.verts); /* send data */
|
||||
|
||||
GPUBuiltinShader shader = (g_batch.simple_shader) ? GPU_SHADER_TEXT_SIMPLE : GPU_SHADER_TEXT;
|
||||
|
|
|
@ -3571,7 +3571,7 @@ static void nodelink_batch_draw(SpaceNode *snode)
|
|||
UI_GetThemeColor4fv(TH_EDGE_SELECT, colors[nodelink_get_color_id(TH_EDGE_SELECT)]);
|
||||
UI_GetThemeColor4fv(TH_REDALERT, colors[nodelink_get_color_id(TH_REDALERT)]);
|
||||
|
||||
GPU_vertbuf_vertex_count_set(g_batch_link.inst_vbo, g_batch_link.count);
|
||||
GPU_vertbuf_data_len_set(g_batch_link.inst_vbo, g_batch_link.count);
|
||||
GPU_vertbuf_use(g_batch_link.inst_vbo); /* force update. */
|
||||
|
||||
GPU_batch_program_set_builtin(g_batch_link.batch, GPU_SHADER_2D_NODELINK_INST);
|
||||
|
|
|
@ -77,7 +77,7 @@ void GPU_vertbuf_init_with_format_ex(GPUVertBuf *, const GPUVertFormat *, GPUUsa
|
|||
uint GPU_vertbuf_size_get(const GPUVertBuf *);
|
||||
void GPU_vertbuf_data_alloc(GPUVertBuf *, uint v_len);
|
||||
void GPU_vertbuf_data_resize(GPUVertBuf *, uint v_len);
|
||||
void GPU_vertbuf_vertex_count_set(GPUVertBuf *, uint v_len);
|
||||
void GPU_vertbuf_data_len_set(GPUVertBuf *, uint v_len);
|
||||
|
||||
/* The most important set_attrib variant is the untyped one. Get it right first. */
|
||||
/* It takes a void* so the app developer is responsible for matching their app data types */
|
||||
|
|
|
@ -152,7 +152,7 @@ void GPU_vertbuf_data_resize(GPUVertBuf *verts, uint v_len)
|
|||
/* Set vertex count but does not change allocation.
|
||||
* Only this many verts will be uploaded to the GPU and rendered.
|
||||
* This is useful for streaming data. */
|
||||
void GPU_vertbuf_vertex_count_set(GPUVertBuf *verts, uint v_len)
|
||||
void GPU_vertbuf_data_len_set(GPUVertBuf *verts, uint v_len)
|
||||
{
|
||||
#if TRUST_NO_ONE
|
||||
assert(verts->data != NULL); /* only for dynamic data */
|
||||
|
|
Loading…
Reference in New Issue