Skip to content

[rlsw] Remove position attribute from sw_vertex_t#5677

Merged
raysan5 merged 3 commits intoraysan5:masterfrom
Bigfoot71:rlsw-position
Mar 20, 2026
Merged

[rlsw] Remove position attribute from sw_vertex_t#5677
raysan5 merged 3 commits intoraysan5:masterfrom
Bigfoot71:rlsw-position

Conversation

@Bigfoot71
Copy link
Contributor

@Bigfoot71 Bigfoot71 commented Mar 20, 2026

Just replace float coord[4] with float position[4] instead.

Until now the world position was being preserved, but the only real point would be if we ever add lighting as defined in OpenGL 1.1, and therefore also at the rlgl level, but that doesn't seem to be planned.

By the way, positions were interpolated during clipping, so this should produce a marginal gain at this stage.

@Bigfoot71 Bigfoot71 changed the title [rlsw] Review sw_vertex_t [rlsw] Remove position attribute from sw_vertex_t Mar 20, 2026
@Bigfoot71
Copy link
Contributor Author

I also just fixed a bug with swPopMatrix() along the way, I had noticed it with models_rlgl_solar_system

By the way, the push/pop functions could be easily simplified, but hey

@raysan5 raysan5 merged commit 8a68587 into raysan5:master Mar 20, 2026
16 checks passed
@raysan5
Copy link
Owner

raysan5 commented Mar 20, 2026

@Bigfoot71 thanks for the review!

By the way, the push/pop functions could be easily simplified, but hey

I imagine you mean on rlgl side, that system was implemented ~10 years ago and probably it can be improved

@Bigfoot71
Copy link
Contributor Author

I imagine you mean on rlgl side, that system was implemented ~10 years ago and probably it can be improved

No I did mean rlsw, there's some duplication, but it works for now, so I'll avoid over-reviewing it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants