tsoding / ded

Dramatic EDitor
MIT License
570 stars 76 forks source link

Move bg out of the while (!quit) loop so it's not being recomputed every frame #72

Closed Endode closed 11 months ago

Endode commented 1 year ago

Changes: src/main.c

Move the bg variable to above the while (!quit) loop since it was running hex_to_vec4f() every frame. The bg color doesn't change, so there is no need for it to be in the loop. It can just be computed once, before the loop