cf_draw3d_push_mesh_attributes2¶
Category: draw3d
GitHub: cute_draw3d.h
Pushes a second vec4 of per-submission data, delivered as in_uv_rect.
| Parameters | Description |
|---|---|
attributes |
The value delivered to the shader as in_uv_rect. |
Remarks¶
The in_uv_rect lane carries the atlas sub-rect while a sprite texture is pushed
(cf_draw3d_push_texture); with none pushed it is free, so it doubles as a second
user attributes lane at zero extra bandwidth -- material indices, a second tint, ocean
phase, whatever your shader wants. Defaults to (0, 0, 1, 1) (the full uv rect), so
shaders that sample u_image against the white fallback keep working. Like
cf_draw3d_push_mesh_attributes, differing values never split coalescing. Pushing a
sprite texture overrides this lane for those submissions.
Related Pages¶
cf_draw3d_push_mesh_attributes
cf_draw3d_pop_mesh_attributes2
cf_draw3d_peek_mesh_attributes2
cf_draw3d_push_texture