optimized blenloader for loops #106573

Closed
glitchy-virophage wants to merge 31 commits from (deleted):main into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
1 changed files with 2 additions and 2 deletions
Showing only changes of commit cddb5d41f7 - Show all commits

View File

@ -228,9 +228,9 @@ static BHead *blo_blendhandle_read_preview_rects(FileData *fd,
const PreviewImage *preview_from_file)
{
int change = 0;
for (int preview_index = NUM_ICON_SIZES; --preview_index) {
for (int preview_index = NUM_ICON_SIZES; --preview_index; ) {
//changed it to use decrement instead of increment to use less resources
change = (NUM_ICON_SIZES - preview_index)
change = (NUM_ICON_SIZES - preview_index);
if (preview_from_file->rect[change] && preview_from_file->w[change] &&
preview_from_file->h[change]) {
bhead = blo_bhead_next(fd, bhead);